diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2010-11-26 13:49:04 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-11-26 15:00:59 +0100 |
commit | ee6dcfa40a50fe12a3ae0fb4d2653c66c3ed6556 (patch) | |
tree | e77ac01a6bf2106f7a2c22f00e43cb2960d72ba5 /kernel | |
parent | cc2067a51424dd25c10c1b1230b4222d8baec94d (diff) | |
download | linux-ee6dcfa40a50fe12a3ae0fb4d2653c66c3ed6556.tar.gz linux-ee6dcfa40a50fe12a3ae0fb4d2653c66c3ed6556.tar.bz2 linux-ee6dcfa40a50fe12a3ae0fb4d2653c66c3ed6556.zip |
perf: Fix the software context switch counter
Stephane noticed that because the perf_sw_event() call is inside the
perf_event_task_sched_out() call it won't get called unless we
have a per-task counter.
Reported-by: Stephane Eranian <eranian@google.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/perf_event.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/kernel/perf_event.c b/kernel/perf_event.c index f365dd8ef8b0..eac7e3364335 100644 --- a/kernel/perf_event.c +++ b/kernel/perf_event.c @@ -1287,8 +1287,6 @@ void __perf_event_task_sched_out(struct task_struct *task, { int ctxn; - perf_sw_event(PERF_COUNT_SW_CONTEXT_SWITCHES, 1, 1, NULL, 0); - for_each_task_context_nr(ctxn) perf_event_context_sched_out(task, ctxn, next); } |