diff options
author | Markus Metzger <markus.t.metzger@intel.com> | 2009-01-19 10:31:01 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-01-20 13:03:48 +0100 |
commit | b1818748b0cf9427e48acf9713295e829a0d715f (patch) | |
tree | 49e8f8dc4328799fa69eae635f4b69ee97228445 /arch/x86/kernel/dumpstack.c | |
parent | x86, ftrace, hw-branch-tracer: support hotplug cpus (diff) | |
download | linux-b1818748b0cf9427e48acf9713295e829a0d715f.tar.xz linux-b1818748b0cf9427e48acf9713295e829a0d715f.zip |
x86, ftrace, hw-branch-tracer: dump trace on oops
Dump the branch trace on an oops (based on ftrace_dump_on_oops).
Signed-off-by: Markus Metzger <markus.t.metzger@intel.com>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/dumpstack.c')
-rw-r--r-- | arch/x86/kernel/dumpstack.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/x86/kernel/dumpstack.c b/arch/x86/kernel/dumpstack.c index 6b1f6f6f8661..077c9ea655fc 100644 --- a/arch/x86/kernel/dumpstack.c +++ b/arch/x86/kernel/dumpstack.c @@ -14,6 +14,7 @@ #include <linux/bug.h> #include <linux/nmi.h> #include <linux/sysfs.h> +#include <linux/ftrace.h> #include <asm/stacktrace.h> @@ -195,6 +196,11 @@ unsigned __kprobes long oops_begin(void) int cpu; unsigned long flags; + /* notify the hw-branch tracer so it may disable tracing and + add the last trace to the trace buffer - + the earlier this happens, the more useful the trace. */ + trace_hw_branch_oops(); + oops_enter(); /* racy, but better than risking deadlock. */ |