diff options
author | Otavio Salvador <otavio@debian.org> | 2006-01-06 08:11:26 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-06 16:33:30 (GMT) |
commit | e13ac219816c58579f40b48220b2fa5d94c30e84 (patch) | |
tree | d4c2e5ff885a8e4268975974ceb7689690743e16 | |
parent | fa57f9c2b841872ffad9d8f7b3de23d6ba33c30d (diff) | |
download | linux-e13ac219816c58579f40b48220b2fa5d94c30e84.tar.xz |
[PATCH] arch/ppc/kernel/idle.c: don't declare cpu variable in non-SMP kernels
Disable declaration of cpu variable in default_idle function when
building non-SMP kernels.
Signed-off-by: Otavio Salvador <otavio@debian.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | arch/ppc/kernel/idle.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/ppc/kernel/idle.c b/arch/ppc/kernel/idle.c index 821a75e..1be3ca5 100644 --- a/arch/ppc/kernel/idle.c +++ b/arch/ppc/kernel/idle.c @@ -37,7 +37,6 @@ void default_idle(void) { void (*powersave)(void); - int cpu = smp_processor_id(); powersave = ppc_md.power_save; @@ -47,7 +46,8 @@ void default_idle(void) #ifdef CONFIG_SMP else { set_thread_flag(TIF_POLLING_NRFLAG); - while (!need_resched() && !cpu_is_offline(cpu)) + while (!need_resched() && + !cpu_is_offline(smp_processor_id())) barrier(); clear_thread_flag(TIF_POLLING_NRFLAG); } |