[SPARC64]: Add tick_nohz_{stop,restart}_sched_tick() calls to cpu_idle().

Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
David S. Miller 2007-02-22 06:24:45 -08:00
parent 777a447529
commit 038cb01ea6

View file

@ -28,6 +28,7 @@
#include <linux/reboot.h> #include <linux/reboot.h>
#include <linux/delay.h> #include <linux/delay.h>
#include <linux/compat.h> #include <linux/compat.h>
#include <linux/tick.h>
#include <linux/init.h> #include <linux/init.h>
#include <asm/oplib.h> #include <asm/oplib.h>
@ -88,13 +89,15 @@ void cpu_idle(void)
set_thread_flag(TIF_POLLING_NRFLAG); set_thread_flag(TIF_POLLING_NRFLAG);
while(1) { while(1) {
if (need_resched()) { tick_nohz_stop_sched_tick();
while (!need_resched())
sparc64_yield();
tick_nohz_restart_sched_tick();
preempt_enable_no_resched(); preempt_enable_no_resched();
schedule(); schedule();
preempt_disable(); preempt_disable();
} }
sparc64_yield();
}
} }
extern char reboot_command []; extern char reboot_command [];