]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
ACPI: don't cond_resched() when irqs_disabled()
authorWu Fengguang <fengguang.wu@intel.com>
Wed, 26 Nov 2008 06:35:22 +0000 (14:35 +0800)
committerLen Brown <len.brown@intel.com>
Fri, 19 Dec 2008 09:38:33 +0000 (04:38 -0500)
The ACPI interpreter usually runs with irqs enabled.
However, during suspend/resume it runs with
irqs disabled to evaluate _GTS/_BFS, as well as
by irqrouter_resume() which evaluates _CRS, _PRS, _SRS.

http://bugzilla.kernel.org/show_bug.cgi?id=12252

Signed-off-by: Wu Fengguang <wfg@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
include/acpi/platform/aclinux.h

index 029c8c06c151ab4f7153d4aeb143bb51ed4d258c..0515e754449d13bd8d10fddb3f6b92ad6f6e5fd0 100644 (file)
@@ -141,6 +141,10 @@ static inline void *acpi_os_acquire_object(acpi_cache_t * cache)
 /*
  * We need to show where it is safe to preempt execution of ACPICA
  */
-#define ACPI_PREEMPTION_POINT()        cond_resched()
+#define ACPI_PREEMPTION_POINT()                \
+       do {                            \
+               if (!irqs_disabled())   \
+                       cond_resched(); \
+       } while (0)
 
 #endif                         /* __ACLINUX_H__ */