Skip to content

Commit

Permalink
ACPI: fix 2.6.20 SMP boot regression
Browse files Browse the repository at this point in the history
Always disable/enable interrupts in the acpi idle routine,
even in the error path.

This is required as the 2.6.20 change in git commit d331e73...
"Fix interrupt race in idle callback" expects the idle handler
to enable interrupt before returning.

There was a case in acpi idle routine, in which interrupt was not being
enabled before return, which caused the system to hang at bootup, while
enabling C-states on an SMP system.

The signature of the hang was that "processor.nocst"
was required to enable boot.

Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
  • Loading branch information
Venkatesh Pallipadi authored and Len Brown committed Jun 23, 2007
1 parent 83dd450 commit d5a3d32
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions drivers/acpi/processor_idle.c
Original file line number Diff line number Diff line change
Expand Up @@ -332,16 +332,18 @@ static void acpi_processor_idle(void)
int sleep_ticks = 0;
u32 t1, t2 = 0;

pr = processors[smp_processor_id()];
if (!pr)
return;

/*
* Interrupts must be disabled during bus mastering calculations and
* for C2/C3 transitions.
*/
local_irq_disable();

pr = processors[smp_processor_id()];
if (!pr) {
local_irq_enable();
return;
}

/*
* Check whether we truly need to go idle, or should
* reschedule:
Expand Down

0 comments on commit d5a3d32

Please sign in to comment.