730319aef0
QEMU incorrectly validates FEAT_SVM feature flags against GET_SUPPORTED_CPUID even if SVM features are being masked out by cpu_x86_cpuid(). This can make QEMU print warnings on most AMD CPU models, even when SVM nesting is disabled (which is the default). This bug was never detected before because of a Linux KVM bug: until Linux v5.6, KVM was not filtering out SVM features in GET_SUPPORTED_CPUID when nested was disabled. This KVM bug was fixed in Linux v5.7-rc1, on Linux commit a50718cc3f43 ("KVM: nSVM: Expose SVM features to L1 iff nested is enabled"). Fix the problem by adding a CPUID_EXT3_SVM dependency to all FEAT_SVM feature flags in the feature_dependencies table. Reported-by: Yanan Fu <yfu@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Message-Id: <20200623230116.277409-1-ehabkost@redhat.com> [Fix testcase. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> |
||
---|---|---|
.. | ||
hvf | ||
arch_dump.c | ||
arch_memory_mapping.c | ||
bpt_helper.c | ||
cc_helper_template.h | ||
cc_helper.c | ||
cpu-param.h | ||
cpu-qom.h | ||
cpu.c | ||
cpu.h | ||
excp_helper.c | ||
fpu_helper.c | ||
gdbstub.c | ||
hax-all.c | ||
hax-i386.h | ||
hax-interface.h | ||
hax-mem.c | ||
hax-posix.c | ||
hax-posix.h | ||
hax-windows.c | ||
hax-windows.h | ||
helper.c | ||
helper.h | ||
hyperv-proto.h | ||
hyperv-stub.c | ||
hyperv.c | ||
hyperv.h | ||
int_helper.c | ||
kvm_i386.h | ||
kvm-stub.c | ||
kvm.c | ||
machine.c | ||
Makefile.objs | ||
mem_helper.c | ||
misc_helper.c | ||
monitor.c | ||
mpx_helper.c | ||
ops_sse_header.h | ||
ops_sse.h | ||
seg_helper.c | ||
sev_i386.h | ||
sev-stub.c | ||
sev.c | ||
shift_helper_template.h | ||
smm_helper.c | ||
svm_helper.c | ||
svm.h | ||
trace-events | ||
translate.c | ||
whp-dispatch.h | ||
whpx-all.c | ||
xsave_helper.c |