]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/acpi/platform/aclinux.h
ACPI: don't cond_resched() when irqs_disabled()
[linux-2.6-omap-h63xx.git] / include / acpi / platform / aclinux.h
index 9af4645986829bbf00ea5b77d3aeae2f818763ed..0515e754449d13bd8d10fddb3f6b92ad6f6e5fd0 100644 (file)
@@ -53,6 +53,7 @@
 #include <linux/kernel.h>
 #include <linux/module.h>
 #include <linux/ctype.h>
+#include <linux/sched.h>
 #include <asm/system.h>
 #include <asm/atomic.h>
 #include <asm/div64.h>
@@ -137,4 +138,13 @@ static inline void *acpi_os_acquire_object(acpi_cache_t * cache)
 #define ACPI_ALLOCATE_ZEROED(a)        acpi_os_allocate_zeroed(a)
 #define ACPI_FREE(a)           kfree(a)
 
+/*
+ * We need to show where it is safe to preempt execution of ACPICA
+ */
+#define ACPI_PREEMPTION_POINT()                \
+       do {                            \
+               if (!irqs_disabled())   \
+                       cond_resched(); \
+       } while (0)
+
 #endif                         /* __ACLINUX_H__ */