aboutsummaryrefslogtreecommitdiff
path: root/drivers/acpi/processor_idle.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-03-18 07:48:23 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-03-18 07:48:23 -0700
commit74fe030532d779a3774fcc9e1ddce65f3773e156 (patch)
tree668da06acf3fc395e5525ba6fc201bcb7de43c29 /drivers/acpi/processor_idle.c
parentfb00f7629bb94ef9189fc3790b95306a144f58c5 (diff)
parent13d93924f13e1989cf27375cd46451475bc70d1d (diff)
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: ACPI: Set flag DOCK_UNDOCKING when triggered via sysfs Revert "ACPI: video: Ignore devices that aren't present in hardware" asus_acpi: remove misleading mask Revert "ACPI: video: Ignore ACPI video devices that aren't present in hardware" thermal: delete "default y" thermal: re-document thermal units Revert "thermal: fix generic thermal I/F for hwmon" ACPI: fix ATA_ACPI build ACPI: battery: Don't return -EFAIL on broken packages. ACPI: lockdep warning on boot, 2.6.25-rc5
Diffstat (limited to 'drivers/acpi/processor_idle.c')
-rw-r--r--drivers/acpi/processor_idle.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c
index 6f3b217699e..e8e2d886923 100644
--- a/drivers/acpi/processor_idle.c
+++ b/drivers/acpi/processor_idle.c
@@ -216,8 +216,10 @@ static void acpi_safe_halt(void)
* test NEED_RESCHED:
*/
smp_mb();
- if (!need_resched())
+ if (!need_resched()) {
safe_halt();
+ local_irq_disable();
+ }
current_thread_info()->status |= TS_POLLING;
}
@@ -421,7 +423,9 @@ static void acpi_processor_idle(void)
else
acpi_safe_halt();
- local_irq_enable();
+ if (irqs_disabled())
+ local_irq_enable();
+
return;
}
@@ -530,7 +534,9 @@ static void acpi_processor_idle(void)
* skew otherwise.
*/
sleep_ticks = 0xFFFFFFFF;
- local_irq_enable();
+ if (irqs_disabled())
+ local_irq_enable();
+
break;
case ACPI_STATE_C2: