aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace_sched_wakeup.c
diff options
context:
space:
mode:
authorFrederic Weisbecker <fweisbec@gmail.com>2009-02-10 20:25:00 -0500
committerIngo Molnar <mingo@elte.hu>2009-02-17 19:40:20 -0500
commit6eaaa5d57e76c454479833fc8594cd7c3b75c789 (patch)
treec8f3c130004199bbbc8d141bbfb0f216539c0724 /kernel/trace/trace_sched_wakeup.c
parentac07bcaa8259841905ead3f8cd60b1923ca6c0e5 (diff)
tracing/core: use appropriate waiting on trace_pipe
Impact: api and pipe waiting change Currently, the waiting used in tracing_read_pipe() is done through a 100 msecs schedule_timeout() loop which periodically check if there are traces on the buffer. This can cause small latencies for programs which are reading the incoming events. This patch makes the reader waiting for the trace_wait waitqueue except for few tracers such as the sched and functions tracers which might be already hold the runqueue lock while waking up the reader. This is performed through a new callback wait_pipe() on struct tracer. If none is implemented on a specific tracer, the default waiting for trace_wait queue is attached. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/trace/trace_sched_wakeup.c')
-rw-r--r--kernel/trace/trace_sched_wakeup.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/trace/trace_sched_wakeup.c b/kernel/trace/trace_sched_wakeup.c
index 276c51aaf314..db55f7aaa640 100644
--- a/kernel/trace/trace_sched_wakeup.c
+++ b/kernel/trace/trace_sched_wakeup.c
@@ -380,6 +380,7 @@ static struct tracer wakeup_rt_tracer __read_mostly =
380 .reset = wakeup_tracer_reset, 380 .reset = wakeup_tracer_reset,
381 .start = wakeup_tracer_start, 381 .start = wakeup_tracer_start,
382 .stop = wakeup_tracer_stop, 382 .stop = wakeup_tracer_stop,
383 .wait_pipe = poll_wait_pipe,
383 .print_max = 1, 384 .print_max = 1,
384#ifdef CONFIG_FTRACE_SELFTEST 385#ifdef CONFIG_FTRACE_SELFTEST
385 .selftest = trace_selftest_startup_wakeup, 386 .selftest = trace_selftest_startup_wakeup,