]> xenbits.xensource.com Git - qemu-xen.git/commit
i386: expand Hyper-V features during CPU feature expansion time
authorVitaly Kuznetsov <vkuznets@redhat.com>
Tue, 8 Jun 2021 12:08:13 +0000 (14:08 +0200)
committerEduardo Habkost <ehabkost@redhat.com>
Tue, 13 Jul 2021 13:13:29 +0000 (09:13 -0400)
commit071ce4b03becf9e2df6b758fde9609be8ddf56f1
tree25d8806960b1497e2e709682c9725364e95cab62
parentd7652b772f302346c8f1043aa850a28c445e80d7
i386: expand Hyper-V features during CPU feature expansion time

To make Hyper-V features appear in e.g. QMP query-cpu-model-expansion we
need to expand and set the corresponding CPUID leaves early. Modify
x86_cpu_get_supported_feature_word() to call newly intoduced Hyper-V
specific kvm_hv_get_supported_cpuid() instead of
kvm_arch_get_supported_cpuid(). We can't use kvm_arch_get_supported_cpuid()
as Hyper-V specific CPUID leaves intersect with KVM's.

Note, early expansion will only happen when KVM supports system wide
KVM_GET_SUPPORTED_HV_CPUID ioctl (KVM_CAP_SYS_HYPERV_CPUID).

Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Message-Id: <20210608120817.1325125-6-vkuznets@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
target/i386/cpu.c
target/i386/kvm/kvm-stub.c
target/i386/kvm/kvm.c
target/i386/kvm/kvm_i386.h