From: Chad Goodman Date: Fri, 21 Dec 2012 04:00:08 +0000 (-0800) Subject: ARM: Fix negative idle stats for offline cpu X-Git-Url: https://ziggy471.com/git/gitweb.cgi?p=ziggy471-sgn2-jb.git;a=commitdiff;h=c187c37dd37926a41b88719269eb015176f05996 ARM: Fix negative idle stats for offline cpu Signed-off-by: Ziggy --- --- a/arch/arm/kernel/process.c +++ b/arch/arm/kernel/process.c @@ -226,11 +226,6 @@ void cpu_idle(void) idle_notifier_call_chain(IDLE_START); tick_nohz_stop_sched_tick(1); while (!need_resched()) { -#ifdef CONFIG_HOTPLUG_CPU - if (cpu_is_offline(smp_processor_id())) - cpu_die(); -#endif - local_irq_disable(); #ifdef CONFIG_PL310_ERRATA_769419 wmb(); @@ -256,6 +251,10 @@ void cpu_idle(void) preempt_enable_no_resched(); schedule(); preempt_disable(); +#ifdef CONFIG_HOTPLUG_CPU + if (cpu_is_offline(smp_processor_id())) + cpu_die(); +#endif } }