tracing: Prevent deleting instances when they are being read

Add a ref count to the trace_array structure and prevent removal
of instances that have open descriptors.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
This commit is contained in:
Steven Rostedt (Red Hat)
2013-03-06 15:27:24 -05:00
committed by Steven Rostedt
parent 121aaee7b0
commit a695cb5816
2 changed files with 24 additions and 0 deletions

View File

@@ -219,6 +219,7 @@ struct trace_array {
struct list_head systems;
struct list_head events;
struct task_struct *waiter;
int ref;
};
enum {