summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-10-08 12:04:04 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2009-10-08 12:04:04 -0700
commit7c1632ba76d94b4847fde79f67faa91ef8571fe9 (patch)
tree012076beb659ee4609a8101c1fa9e90c759a38f0 /kernel
parenta888f96a154b70804c5b29ee02e4d3bda6d55e56 (diff)
parent9bcbdd9c58617f1301dd4f17c738bb9bc73aca70 (diff)
Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: x86, timers: Check for pending timers after (device) interrupts NOHZ: update idle state also when NOHZ is inactive
Diffstat (limited to 'kernel')
-rw-r--r--kernel/time/tick-sched.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index e0f59a21c06..89aed5933ed 100644
--- a/kernel/time/tick-sched.c
+++ b/kernel/time/tick-sched.c
@@ -231,6 +231,13 @@ void tick_nohz_stop_sched_tick(int inidle)
if (!inidle && !ts->inidle)
goto end;
+ /*
+ * Set ts->inidle unconditionally. Even if the system did not
+ * switch to NOHZ mode the cpu frequency governers rely on the
+ * update of the idle time accounting in tick_nohz_start_idle().
+ */
+ ts->inidle = 1;
+
now = tick_nohz_start_idle(ts);
/*
@@ -248,8 +255,6 @@ void tick_nohz_stop_sched_tick(int inidle)
if (unlikely(ts->nohz_mode == NOHZ_MODE_INACTIVE))
goto end;
- ts->inidle = 1;
-
if (need_resched())
goto end;