[PATCH 3/4] trace: stop all recording to ring buffer on ftrace_dump

From: Steven Rostedt
Date: Wed Jan 14 2009 - 19:04:34 EST


From: Steven Rostedt <srostedt@xxxxxxxxxx>

Impact: clean up to prevent more output in ftrace dump than needed

Currently ftrace_dump only calls ftrace_kill that is a fast way
to prevent the function tracer functions from being called (just sets
a flag and clears the function to call, nothing else). It is better
to also turn off any recording to the ring buffers as well.

Signed-off-by: Steven Rostedt <srostedt@xxxxxxxxxx>
---
kernel/trace/trace.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index 408c03f..dcb757f 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -3110,6 +3110,7 @@ void ftrace_dump(void)
dump_ran = 1;

/* No turning back! */
+ tracing_off();
ftrace_kill();

for_each_tracing_cpu(cpu) {
--
1.5.6.5

--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/