Skip to content

Commit

Permalink
Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm…
Browse files Browse the repository at this point in the history
…/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:
  NOHZ: Properly feed cpufreq ondemand governor
  • Loading branch information
Linus Torvalds committed Jun 20, 2009
2 parents c4c5ab3 + f2e21c9 commit 38df92b
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions kernel/time/tick-sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,15 @@ void tick_nohz_stop_sched_tick(int inidle)

cpu = smp_processor_id();
ts = &per_cpu(tick_cpu_sched, cpu);

/*
* Call to tick_nohz_start_idle stops the last_update_time from being
* updated. Thus, it must not be called in the event we are called from
* irq_exit() with the prior state different than idle.
*/
if (!inidle && !ts->inidle)
goto end;

now = tick_nohz_start_idle(ts);

/*
Expand All @@ -239,9 +248,6 @@ void tick_nohz_stop_sched_tick(int inidle)
if (unlikely(ts->nohz_mode == NOHZ_MODE_INACTIVE))
goto end;

if (!inidle && !ts->inidle)
goto end;

ts->inidle = 1;

if (need_resched())
Expand Down

0 comments on commit 38df92b

Please sign in to comment.