target/i386: drop AMD machine check bits from Intel CPUID
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 26 Jun 2024 23:13:08 +0000 (01:13 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 3 Jul 2024 16:41:26 +0000 (18:41 +0200)
commit0b2757412cb1d1947d7e2c1fe14985f1e72bba32
tree3f9579ad28987a95939ead67927271b71da001c2
parent8dee38483274bd0fcf3f74dea024d719b958200d
target/i386: drop AMD machine check bits from Intel CPUID

The recent addition of the SUCCOR bit to kvm_arch_get_supported_cpuid()
causes the bit to be visible when "-cpu host" VMs are started on Intel
processors.

While this should in principle be harmless, it's not tidy and we don't
even know for sure that it doesn't cause any guest OS to take unexpected
paths.  Since x86_cpu_get_supported_feature_word() can return different
different values depending on the guest, adjust it to hide the SUCCOR
bit if the guest has non-AMD vendor.

Suggested-by: Xiaoyao Li <xiaoyao.li@intel.com>
Cc: John Allen <john.allen@amd.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
target/i386/cpu.c