diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-i386/idle.h | 14 | ||||
-rw-r--r-- | include/asm-i386/processor.h | 8 |
2 files changed, 22 insertions, 0 deletions
diff --git a/include/asm-i386/idle.h b/include/asm-i386/idle.h new file mode 100644 index 000000000000..87ab93911199 --- /dev/null +++ b/include/asm-i386/idle.h | |||
@@ -0,0 +1,14 @@ | |||
1 | #ifndef _ASM_I386_IDLE_H | ||
2 | #define _ASM_I386_IDLE_H 1 | ||
3 | |||
4 | #define IDLE_START 1 | ||
5 | #define IDLE_END 2 | ||
6 | |||
7 | struct notifier_block; | ||
8 | void idle_notifier_register(struct notifier_block *n); | ||
9 | void idle_notifier_unregister(struct notifier_block *n); | ||
10 | |||
11 | void exit_idle(void); | ||
12 | void enter_idle(void); | ||
13 | |||
14 | #endif | ||
diff --git a/include/asm-i386/processor.h b/include/asm-i386/processor.h index 11bf899de8aa..edfbe46a5e13 100644 --- a/include/asm-i386/processor.h +++ b/include/asm-i386/processor.h | |||
@@ -257,6 +257,14 @@ static inline void __mwait(unsigned long eax, unsigned long ecx) | |||
257 | : :"a" (eax), "c" (ecx)); | 257 | : :"a" (eax), "c" (ecx)); |
258 | } | 258 | } |
259 | 259 | ||
260 | static inline void __sti_mwait(unsigned long eax, unsigned long ecx) | ||
261 | { | ||
262 | /* "mwait %eax,%ecx;" */ | ||
263 | asm volatile( | ||
264 | "sti; .byte 0x0f,0x01,0xc9;" | ||
265 | : :"a" (eax), "c" (ecx)); | ||
266 | } | ||
267 | |||
260 | extern void mwait_idle_with_hints(unsigned long eax, unsigned long ecx); | 268 | extern void mwait_idle_with_hints(unsigned long eax, unsigned long ecx); |
261 | 269 | ||
262 | /* from system description table in BIOS. Mostly for MCA use, but | 270 | /* from system description table in BIOS. Mostly for MCA use, but |