diff options
author | Steven Rostedt <srostedt@redhat.com> | 2012-11-02 04:54:21 +0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2012-11-02 18:21:52 +0400 |
commit | 0d5c6e1c19bab82fad4837108c2902f557d62a04 (patch) | |
tree | ed075db499735ea4d72b9d9d7f992fe7d9a1a328 /kernel/trace/trace_selftest.c | |
parent | 02404baf1b47123f1c88c9f9f1f3b00e1e2b10db (diff) | |
download | linux-0d5c6e1c19bab82fad4837108c2902f557d62a04.tar.xz |
tracing: Use irq_work for wake ups and remove *_nowake_*() functions
Have the ring buffer commit function use the irq_work infrastructure to
wake up any waiters waiting on the ring buffer for new data. The irq_work
was created for such a purpose, where doing the actual wake up at the
time of adding data is too dangerous, as an event or function trace may
be in the midst of the work queue locks and cause deadlocks. The irq_work
will either delay the action to the next timer interrupt, or trigger an IPI
to itself forcing an interrupt to do the work (in a safe location).
With irq_work, all ring buffer commits can safely do wakeups, removing
the need for the ring buffer commit "nowake" variants, which were used
by events and function tracing. All commits can now safely use the
normal commit, and the "nowake" variants can be removed.
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/trace_selftest.c')
-rw-r--r-- | kernel/trace/trace_selftest.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/trace/trace_selftest.c b/kernel/trace/trace_selftest.c index 091b815f7b0a..47623169a815 100644 --- a/kernel/trace/trace_selftest.c +++ b/kernel/trace/trace_selftest.c @@ -1094,6 +1094,7 @@ trace_selftest_startup_wakeup(struct tracer *trace, struct trace_array *tr) tracing_stop(); /* check both trace buffers */ ret = trace_test_buffer(tr, NULL); + printk("ret = %d\n", ret); if (!ret) ret = trace_test_buffer(&max_tr, &count); |