diff options
-rw-r--r-- | arch/x86/kernel/process.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c index 1d92a5ab6e8b..ad57d832d96f 100644 --- a/arch/x86/kernel/process.c +++ b/arch/x86/kernel/process.c | |||
@@ -594,9 +594,17 @@ int mwait_usable(const struct cpuinfo_x86 *c) | |||
594 | { | 594 | { |
595 | u32 eax, ebx, ecx, edx; | 595 | u32 eax, ebx, ecx, edx; |
596 | 596 | ||
597 | /* Use mwait if idle=mwait boot option is given */ | ||
597 | if (boot_option_idle_override == IDLE_FORCE_MWAIT) | 598 | if (boot_option_idle_override == IDLE_FORCE_MWAIT) |
598 | return 1; | 599 | return 1; |
599 | 600 | ||
601 | /* | ||
602 | * Any idle= boot option other than idle=mwait means that we must not | ||
603 | * use mwait. Eg: idle=halt or idle=poll or idle=nomwait | ||
604 | */ | ||
605 | if (boot_option_idle_override != IDLE_NO_OVERRIDE) | ||
606 | return 0; | ||
607 | |||
600 | if (c->cpuid_level < MWAIT_INFO) | 608 | if (c->cpuid_level < MWAIT_INFO) |
601 | return 0; | 609 | return 0; |
602 | 610 | ||