diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2008-04-26 11:30:34 -0700 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-05-05 23:56:17 +0200 |
commit | d478c2cfaa2476f8b6876f9eb4d8fddcfa986479 (patch) | |
tree | 59cb264c539147cb481e13335ff3c69750e16c67 /kernel | |
parent | 733a0771df46af942b8355cd8bb15780106b4353 (diff) | |
download | linux-d478c2cfaa2476f8b6876f9eb4d8fddcfa986479.tar.gz linux-d478c2cfaa2476f8b6876f9eb4d8fddcfa986479.tar.bz2 linux-d478c2cfaa2476f8b6876f9eb4d8fddcfa986479.zip |
sched: add debug checks to idle functions
Cc: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Cc: "Justin Mattock" <justinmattock@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 00c1ba706a5a..ed3caf26990d 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -1124,6 +1124,7 @@ void sched_clock_idle_sleep_event(void) { struct rq *rq = cpu_rq(smp_processor_id()); + WARN_ON(!irqs_disabled()); spin_lock(&rq->lock); __update_rq_clock(rq); spin_unlock(&rq->lock); @@ -1139,6 +1140,7 @@ void sched_clock_idle_wakeup_event(u64 delta_ns) struct rq *rq = cpu_rq(smp_processor_id()); u64 now = sched_clock(); + WARN_ON(!irqs_disabled()); rq->idle_clock += delta_ns; /* * Override the previous timestamp and ignore all |