Commit 6f4ba5ef authored by Wyes Karny's avatar Wyes Karny Committed by Xie Haocheng
Browse files

x86: Handle idle=nomwait cmdline properly for x86_idle

mainline inclusion
from mainline-v6.0-rc1
commit 8bcedb4c
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I5YN5Z


CVE: NA

--------------------------------

When kernel is booted with idle=nomwait do not use MWAIT as the
default idle state.

If the user boots the kernel with idle=nomwait, it is a clear
direction to not use mwait as the default idle state.
However, the current code does not take this into consideration
while selecting the default idle state on x86.

Fix it by checking for the idle=nomwait boot option in
prefer_mwait_c1_over_halt().

Also update the documentation around idle=nomwait appropriately.

[ dhansen: tweak commit message ]

Signed-off-by: default avatarWyes Karny <wyes.karny@amd.com>
Signed-off-by: default avatarDave Hansen <dave.hansen@linux.intel.com>
Tested-by: default avatarZhang Rui <rui.zhang@intel.com>
Link: https://lkml.kernel.org/r/fdc2dc2d0a1bc21c2f53d989ea2d2ee3ccbc0dbe.1654538381.git-series.wyes.karny@amd.com


Signed-off-by: default avatarXie Haocheng <haocheng.xie@amd.com>
parent f7990942
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment