summaryrefslogtreecommitdiffstats
path: root/include/linux/perf_counter.h
diff options
context:
space:
mode:
authorPeter Zijlstra2009-03-23 18:22:07 +0100
committerIngo Molnar2009-04-06 09:30:25 +0200
commit96f6d4444302bb2ea2cf409529eef816462f6ce0 (patch)
tree34ae6944b4a8e6db89c50dba5a3a8b9da3315122 /include/linux/perf_counter.h
parentperf_counter: remove the event config bitfields (diff)
downloadkernel-qcow2-linux-96f6d4444302bb2ea2cf409529eef816462f6ce0.tar.gz
kernel-qcow2-linux-96f6d4444302bb2ea2cf409529eef816462f6ce0.tar.xz
kernel-qcow2-linux-96f6d4444302bb2ea2cf409529eef816462f6ce0.zip
perf_counter: avoid recursion
Tracepoint events like lock_acquire and software counters like pagefaults can recurse into the perf counter code again, avoid that. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Mackerras <paulus@samba.org> Orig-LKML-Reference: <20090323172417.152096433@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/perf_counter.h')
-rw-r--r--include/linux/perf_counter.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/perf_counter.h b/include/linux/perf_counter.h
index 56099e52970d..18dc17d0a61c 100644
--- a/include/linux/perf_counter.h
+++ b/include/linux/perf_counter.h
@@ -328,6 +328,13 @@ struct perf_cpu_context {
int active_oncpu;
int max_pertask;
int exclusive;
+
+ /*
+ * Recursion avoidance:
+ *
+ * task, softirq, irq, nmi context
+ */
+ int recursion[4];
};
/*