aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVitaly Kuznetsov <vkuznets@redhat.com>2021-04-22 18:11:23 +0200
committerEduardo Habkost <ehabkost@redhat.com>2021-05-31 15:53:03 -0400
commit05c900ce7392ef2f0bc7647863c8680641e137df (patch)
tree1ad3b845971a48053dc6422e8cb37b920dcecef9
parentf4a62495be47b0211359f3609aeaf04a4fd44368 (diff)
downloadqemu-05c900ce7392ef2f0bc7647863c8680641e137df.zip
qemu-05c900ce7392ef2f0bc7647863c8680641e137df.tar.gz
qemu-05c900ce7392ef2f0bc7647863c8680641e137df.tar.bz2
i386: adjust the expected KVM_GET_SUPPORTED_HV_CPUID array size
SYNDBG leaves were recently (Linux-5.8) added to KVM but we haven't updated the expected size of KVM_GET_SUPPORTED_HV_CPUID output in KVM so we now make serveral tries before succeeding. Update the default. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Message-Id: <20210422161130.652779-13-vkuznets@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
-rw-r--r--target/i386/kvm/kvm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index 413f57d..9005a42 100644
--- a/target/i386/kvm/kvm.c
+++ b/target/i386/kvm/kvm.c
@@ -962,7 +962,8 @@ static struct kvm_cpuid2 *try_get_hv_cpuid(CPUState *cs, int max)
static struct kvm_cpuid2 *get_supported_hv_cpuid(CPUState *cs)
{
struct kvm_cpuid2 *cpuid;
- int max = 7; /* 0x40000000..0x40000005, 0x4000000A */
+ /* 0x40000000..0x40000005, 0x4000000A, 0x40000080..0x40000080 leaves */
+ int max = 10;
int i;
/*