tracing: Add ref count to tracer for when they are being read by pipe
authorSteven Rostedt (Red Hat) <rostedt@goodmis.org>
Tue, 16 Dec 2014 01:13:31 +0000 (20:13 -0500)
committerSteven Rostedt <rostedt@goodmis.org>
Mon, 22 Dec 2014 20:39:40 +0000 (15:39 -0500)
When one of the trace pipe files are being read (by either the trace_pipe
or trace_pipe_raw), do not allow the current_trace to change. By adding
a ref count that is incremented when the pipe files are opened, will
prevent the current_trace from being changed.

This will allow for the removal of the global trace_types_lock from
reading the pipe buffers (which is currently a bottle neck).

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
kernel/trace/trace.c
kernel/trace/trace.h

Simple merge
Simple merge