Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 158485
b: refs/heads/master
c: b8de7bd
h: refs/heads/master
i:
  158483: 40c63cf
v: v3
  • Loading branch information
Steven Rostedt authored and Steven Rostedt committed Sep 4, 2009
1 parent 196ab5f commit 3f4bb83
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8248ac052dfd1eb41819fbc0ca5c7a1667e7e70c
refs/heads/master: b8de7bd168fa54d059b16d3057b2f8a32cc5bdc3
12 changes: 9 additions & 3 deletions trunk/kernel/trace/trace.c
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,9 @@ unsigned long trace_flags = TRACE_ITER_PRINT_PARENT | TRACE_ITER_PRINTK |
TRACE_ITER_ANNOTATE | TRACE_ITER_CONTEXT_INFO | TRACE_ITER_SLEEP_TIME |
TRACE_ITER_GRAPH_TIME;

static int trace_stop_count;
static DEFINE_SPINLOCK(tracing_start_lock);

/**
* trace_wake_up - wake up tasks waiting for trace input
*
Expand Down Expand Up @@ -442,6 +445,9 @@ update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu)
{
struct ring_buffer *buf = tr->buffer;

if (trace_stop_count)
return;

WARN_ON_ONCE(!irqs_disabled());
__raw_spin_lock(&ftrace_max_lock);

Expand Down Expand Up @@ -469,6 +475,9 @@ update_max_tr_single(struct trace_array *tr, struct task_struct *tsk, int cpu)
{
int ret;

if (trace_stop_count)
return;

WARN_ON_ONCE(!irqs_disabled());
__raw_spin_lock(&ftrace_max_lock);

Expand Down Expand Up @@ -685,9 +694,6 @@ static void trace_init_cmdlines(void)
cmdline_idx = 0;
}

static int trace_stop_count;
static DEFINE_SPINLOCK(tracing_start_lock);

/**
* ftrace_off_permanent - disable all ftrace code permanently
*
Expand Down

0 comments on commit 3f4bb83

Please sign in to comment.