diff options
author | Ingo Molnar <mingo@elte.hu> | 2009-09-10 14:52:09 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-09-10 14:52:54 -0400 |
commit | e1f8450854d69f0291882804406ea1bab3ca44b4 (patch) | |
tree | 606e2176f7654269de904b15aad9491912db4093 /kernel/sched_fair.c | |
parent | 3f2aa307c4d26b4ed6509d0a79e8254c9e07e921 (diff) |
sched: Fix sched::sched_stat_wait tracepoint field
This weird perf trace output:
cc1-9943 [001] 2802.059479616: sched_stat_wait: task: as:9944 wait: 2801938766276 [ns]
Is caused by setting one component field of the delta to zero
a bit too early. Move it to later.
( Note, this does not affect the NEW_FAIR_SLEEPERS interactivity bug,
it's just a reporting bug in essence. )
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Nikos Chantziaras <realnc@arcor.de>
Cc: Jens Axboe <jens.axboe@oracle.com>
Cc: Mike Galbraith <efault@gmx.de>
LKML-Reference: <4AA93D34.8040500@arcor.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/sched_fair.c')
-rw-r--r-- | kernel/sched_fair.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index 26fadb44250c..aa7f84121016 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c | |||
@@ -545,14 +545,13 @@ update_stats_wait_end(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
545 | schedstat_set(se->wait_count, se->wait_count + 1); | 545 | schedstat_set(se->wait_count, se->wait_count + 1); |
546 | schedstat_set(se->wait_sum, se->wait_sum + | 546 | schedstat_set(se->wait_sum, se->wait_sum + |
547 | rq_of(cfs_rq)->clock - se->wait_start); | 547 | rq_of(cfs_rq)->clock - se->wait_start); |
548 | schedstat_set(se->wait_start, 0); | ||
549 | |||
550 | #ifdef CONFIG_SCHEDSTATS | 548 | #ifdef CONFIG_SCHEDSTATS |
551 | if (entity_is_task(se)) { | 549 | if (entity_is_task(se)) { |
552 | trace_sched_stat_wait(task_of(se), | 550 | trace_sched_stat_wait(task_of(se), |
553 | rq_of(cfs_rq)->clock - se->wait_start); | 551 | rq_of(cfs_rq)->clock - se->wait_start); |
554 | } | 552 | } |
555 | #endif | 553 | #endif |
554 | schedstat_set(se->wait_start, 0); | ||
556 | } | 555 | } |
557 | 556 | ||
558 | static inline void | 557 | static inline void |