When running guest kernel 6.9 and later on AMD processors, dmesg reports: [ 0.001987] [Firmware Bug]: CPU 1: APIC ID mismatch. CPUID: 0x0000 APIC: 0x0001 This is because kvmtool does not support topoext but does not tell the guest, causing the guest kernel to read the wrong Extended APIC ID. Signed-off-by: Dongli Si <sidongli1997@xxxxxxxxx> --- x86/cpuid.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/x86/cpuid.c b/x86/cpuid.c index f4347a8..fd23429 100644 --- a/x86/cpuid.c +++ b/x86/cpuid.c @@ -56,6 +56,9 @@ static void filter_cpuid(struct kvm_cpuid2 *kvm_cpuid, int cpu_id) } break; } + case 0x80000001: + entry->ecx &= ~(1 << 22); + break; default: /* Keep the CPUID function as -is */ break; -- 2.44.0