tracing: give easy way to clear trace buffer
authorSteven Rostedt <srostedt@redhat.com>
Wed, 18 Mar 2009 14:40:24 +0000 (10:40 -0400)
committerSteven Rostedt <srostedt@redhat.com>
Wed, 18 Mar 2009 14:52:47 +0000 (10:52 -0400)
commit4acd4d00f716873e27e7b60ae292cbdbfae674dd
tree6728bed8b0cf8cc47ead79261c0fc8d2e9e5c093
parent490362003457f8d387f6f6e73e3a7efbf56c3314
tracing: give easy way to clear trace buffer

There is currently no easy way to clear the trace buffer. Currently
the only way is to change the current tracer.

This patch lets the user clear the trace buffer by simply writing
into the trace files.

 echo > /debug/tracing/trace

or to clear a single cpu (i.e. for CPU 1):

 echo > /debug/tracing/per_cpu/cpu1/trace

Requested-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
kernel/trace/trace.c