Skip to content

Commit d809488

Browse files
committed
chore: Update fingerprint for CPUID.0x80000021:ECX on AMD / 5.10 kernel
KVM added support for CPUID leaf 0x80000021 [1] and synthesized TSA_{SQ,L1}_NO bits on ECX [2]. However, the second patch has a bug where TSA_{SQ,L1}_NO bits are 1st and 2nd bits [3] but exposed as 11th and 12th bits. This bug happened because it used to be software-defined word (not hardware-defined). Recently, the kernel added another bit (X86_FWEATURE_IBPB_EXIT_TO_USER) for VMScape that is not a hardware- defined bit but a software-defined bit. We update the fingerprints for now to make the fingerprint test pass, but will fix the bug. So we'll need to update again once the fix arrives. [1]: amazonlinux/linux@6457a8c [2]: amazonlinux/linux@6fea1a4 [3]: https://www.amd.com/content/dam/amd/en/documents/resources/bulletin/technical-guidance-for-mitigating-transient-scheduler-attacks.pdf [4]: amazonlinux/linux@ac60717 Signed-off-by: Takahiro Itazuri <[email protected]>
1 parent f101b1a commit d809488

File tree

3 files changed

+12
-17
lines changed

3 files changed

+12
-17
lines changed

tests/data/cpu_template_helper/fingerprint_AMD_GENOA_5.10host.json

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
2-
"firecracker_version": "1.13.0-dev",
3-
"kernel_version": "5.10.238-234.956.amzn2.x86_64",
4-
"microcode_version": "0xa101154",
2+
"firecracker_version": "1.14.0-dev",
3+
"kernel_version": "5.10.244-240.965.amzn2.x86_64",
4+
"microcode_version": "0xa101156",
55
"bios_version": "1.0",
6-
"bios_revision": "2.21",
6+
"bios_revision": "2.23",
77
"guest_cpu_config": {
88
"kvm_capabilities": [],
99
"cpuid_modifiers": [
@@ -1494,15 +1494,14 @@
14941494
},
14951495
{
14961496
"register": "ecx",
1497-
"bitmap": "0b00000000000000000010000000000000"
1497+
"bitmap": "0b00000000000000000110000000000000"
14981498
},
14991499
{
15001500
"register": "edx",
15011501
"bitmap": "0b00000000000000000000000000000000"
15021502
}
15031503
]
15041504
}
1505-
15061505
],
15071506
"msr_modifiers": [
15081507
{
@@ -1635,4 +1634,4 @@
16351634
}
16361635
]
16371636
}
1638-
}
1637+
}

tests/data/cpu_template_helper/fingerprint_AMD_MILAN_5.10host.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
2-
"firecracker_version": "1.13.0-dev",
3-
"kernel_version": "5.10.238-234.956.amzn2.x86_64",
4-
"microcode_version": "0xa0011db",
2+
"firecracker_version": "1.14.0-dev",
3+
"kernel_version": "5.10.244-240.965.amzn2.x86_64",
4+
"microcode_version": "0xa0011de",
55
"bios_version": "1.0",
6-
"bios_revision": "0.94",
6+
"bios_revision": "0.98",
77
"guest_cpu_config": {
88
"kvm_capabilities": [],
99
"cpuid_modifiers": [
@@ -1402,7 +1402,7 @@
14021402
},
14031403
{
14041404
"register": "ecx",
1405-
"bitmap": "0b00000000000000000010000000000000"
1405+
"bitmap": "0b00000000000000000110000000000000"
14061406
},
14071407
{
14081408
"register": "edx",
@@ -1542,4 +1542,4 @@
15421542
}
15431543
]
15441544
}
1545-
}
1545+
}

tests/integration_tests/security/test_vulnerabilities.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,11 @@
1111

1212
import pytest
1313
import requests
14-
from packaging import version
1514

1615
from framework import utils
1716
from framework.ab_test import git_clone
1817
from framework.microvm import MicroVMFactory
1918
from framework.properties import global_props
20-
from framework.utils_cpuid import CpuVendor, get_cpu_vendor
2119

2220
CHECKER_URL = "https://raw.githubusercontent.com/speed47/spectre-meltdown-checker/master/spectre-meltdown-checker.sh"
2321
CHECKER_FILENAME = "spectre-meltdown-checker.sh"
@@ -134,8 +132,6 @@ def get_vuln_files_exception_dict(template):
134132
"""
135133
Returns a dictionary of expected values for vulnerability files requiring special treatment.
136134
"""
137-
host_kernel_version = version.parse(utils.get_kernel_version())
138-
cpu_vendor = get_cpu_vendor()
139135
exception_dict = {}
140136

141137
# Exception for mmio_stale_data

0 commit comments

Comments
 (0)