Skip to content

Commit

Permalink
sh: Restore bl bit toggling in idle loop.
Browse files Browse the repository at this point in the history
This fixes up some crashes with IRQs racing the need_resched() test under
QEMU.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
  • Loading branch information
Paul Mundt committed Dec 21, 2009
1 parent 2f7bb2d commit 3147093
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/sh/kernel/idle.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ void cpu_idle(void)
check_pgt_cache();
rmb();

set_bl_bit();
local_irq_disable();
/* Don't trace irqs off for idle */
stop_critical_timings();
Expand All @@ -102,6 +103,7 @@ void cpu_idle(void)
*/
WARN_ON(irqs_disabled());
start_critical_timings();
clear_bl_bit();
}

tick_nohz_restart_sched_tick();
Expand Down

0 comments on commit 3147093

Please sign in to comment.