Skip to content

Commit

Permalink
fix(test): Remove flush_l1d from host-guest feature diff on ubuntu
Browse files Browse the repository at this point in the history
Linux kernel v6.4+ passes through the "l1d_flush" CPUID bit to guests.
While our ubuntu host kernel is 6.8 that has the change, the latest
Amazon Linux 2 and Amazon Linux 2023 haven't.

Fixes: 4e014a1 ("test(x86_64): add host vs guest cpu feature test")
Signed-off-by: Takahiro Itazuri <[email protected]>
  • Loading branch information
zulinx86 committed Nov 7, 2024
1 parent be7f0aa commit f05347d
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ def test_host_vs_guest_cpu_features_x86_64(uvm_nano):
"umip",
}
case CpuModel.INTEL_CASCADELAKE:
assert host_feats - guest_feats == {
expected = {
"acpi",
"aperfmperf",
"arch_perfmon",
Expand Down Expand Up @@ -392,6 +392,13 @@ def test_host_vs_guest_cpu_features_x86_64(uvm_nano):
"vpid",
"xtpr",
}
# TODO: Remove the below ubuntu exception and "flush_l1d" from the above expected list
# once Amazon Linux 2 and Amazon Linux 2023 starts to pass through the "flush_l1d" CPUID
# bit to guests. See https://github.com/firecracker-microvm/firecracker/issues/4899
if "Ubuntu" in global_props.os:
expected -= "flush_l1d"
assert host_feats - guest_feats == expected

assert guest_feats - host_feats == {
"hypervisor",
"tsc_known_freq",
Expand Down

0 comments on commit f05347d

Please sign in to comment.