summaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace_sched_wakeup.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-03-05 10:21:49 +0100
committerIngo Molnar <mingo@elte.hu>2009-03-05 10:21:49 +0100
commit53664738c122bfe8b0e489fddaf2ab265c9133c8 (patch)
tree8121a9fc4021e86499c404e0b1012a36e8d0b00e /kernel/trace/trace_sched_wakeup.c
parentc4ef144a9d0803eb0a2d4110ae87e7f34e667ded (diff)
parente9d25fe6eaa2c720bb3ea661b660e58d54fa38bf (diff)
downloadblackbird-op-linux-53664738c122bfe8b0e489fddaf2ab265c9133c8.tar.gz
blackbird-op-linux-53664738c122bfe8b0e489fddaf2ab265c9133c8.zip
Merge branch 'tip/tracing/ftrace' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace into tracing/ftrace
Diffstat (limited to 'kernel/trace/trace_sched_wakeup.c')
-rw-r--r--kernel/trace/trace_sched_wakeup.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/kernel/trace/trace_sched_wakeup.c b/kernel/trace/trace_sched_wakeup.c
index db55f7aaa640..3c5ad6b2ec84 100644
--- a/kernel/trace/trace_sched_wakeup.c
+++ b/kernel/trace/trace_sched_wakeup.c
@@ -32,6 +32,8 @@ static raw_spinlock_t wakeup_lock =
static void __wakeup_reset(struct trace_array *tr);
+static int save_lat_flag;
+
#ifdef CONFIG_FUNCTION_TRACER
/*
* irqsoff uses its own tracer function to keep the overhead down:
@@ -324,6 +326,9 @@ static void stop_wakeup_tracer(struct trace_array *tr)
static int __wakeup_tracer_init(struct trace_array *tr)
{
+ save_lat_flag = trace_flags & TRACE_ITER_LATENCY_FMT;
+ trace_flags |= TRACE_ITER_LATENCY_FMT;
+
tracing_max_latency = 0;
wakeup_trace = tr;
start_wakeup_tracer(tr);
@@ -347,6 +352,9 @@ static void wakeup_tracer_reset(struct trace_array *tr)
stop_wakeup_tracer(tr);
/* make sure we put back any tasks we are tracing */
wakeup_reset(tr);
+
+ if (!save_lat_flag)
+ trace_flags &= ~TRACE_ITER_LATENCY_FMT;
}
static void wakeup_tracer_start(struct trace_array *tr)
OpenPOWER on IntegriCloud