Skip to content

Commit 8221464

Browse files
committed
chore: Add ibpb_exit_to_user as host only feature
New Amazon Linux host kernels enable mitigation against VMScape that is IBPB before exit to userspace. However, our guest kernels still haven't had the patches yet. Note that Intel Ice Lake is not affected by VMScape as long as BHB clearing sequence is used to mitigate BHI. Signed-off-by: Takahiro Itazuri <[email protected]>
1 parent 22e84fe commit 8221464

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

tests/integration_tests/functional/test_cpu_features_host_vs_guest.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949
"hwp_act_window",
5050
"hwp_epp",
5151
"hwp_pkg_req",
52+
"ibpb_exit_to_user",
5253
"ida",
5354
"intel_ppin",
5455
"intel_pt",
@@ -93,6 +94,7 @@
9394
"extapic",
9495
"flushbyasid",
9596
"hw_pstate",
97+
"ibpb_exit_to_user",
9698
"ibs",
9799
"irperf",
98100
"lbrv",
@@ -206,7 +208,14 @@ def test_host_vs_guest_cpu_features(uvm_plain_any):
206208
assert guest_feats - host_feats == expected_guest_minus_host
207209

208210
case CpuModel.INTEL_ICELAKE:
209-
host_guest_diff_5_10 = INTEL_HOST_ONLY_FEATS - {"cdp_l3"} | {
211+
expected_host_minus_guest = INTEL_HOST_ONLY_FEATS
212+
213+
# As long as BHB clearing software mitigation is enabled, Intel Ice Lake is not
214+
# vulnerable to VMScape and "IBPB before exit to userspace" is not needed.
215+
# https://docs.kernel.org/admin-guide/hw-vuln/vmscape.html#affected-processors
216+
expected_host_minus_guest -= {"ibpb_exit_to_user"}
217+
218+
host_guest_diff_5_10 = expected_host_minus_guest - {"cdp_l3"} | {
210219
"pconfig",
211220
"tme",
212221
"split_lock_detect",

0 commit comments

Comments
 (0)