[<prev] [next>] [day] [month] [year] [list]
Message-ID: <9201e8ac-68d2-2bb3-1ef3-efd698391955@yandex.ru>
Date: Mon, 7 Dec 2020 17:03:55 +0300
From: stsp <stsp2@...dex.ru>
To: Paolo Bonzini <pbonzini@...hat.com>
Cc: Sean Christopherson <sean.j.christopherson@...el.com>,
Vitaly Kuznetsov <vkuznets@...hat.com>,
Wanpeng Li <wanpengli@...cent.com>,
Jim Mattson <jmattson@...gle.com>,
Joerg Roedel <joro@...tes.org>, kvm@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: KVM_SET_CPUID doesn't check supported bits (was Re: [PATCH 0/6]
KVM: x86: KVM_SET_SREGS.CR4 bug fixes and cleanup)
07.12.2020 16:35, Paolo Bonzini пишет:
>
>
> Il lun 7 dic 2020, 12:47 stsp <stsp2@...dex.ru
> <mailto:stsp2@...dex.ru>> ha scritto:
>
> So am I right that KVM_SET_CPUID only "lowers"
> the supported bits? In which case I don't need to
> call it at all, but instead just call KVM_GET_SUPPORTED_CPUID
> and see if the needed bits are supported, and
> exit otherwise, right?
>
>
> You always have to call KVM_SET_CPUID2, but you can just pass in
> whatever you got from KVM_GET_SUPPORTED_CPUID.
OK, done that, thanks.
(after checking that KVM_GET_SUPPORTED_CPUID
actually has the needed features itself, otherwise exit).
Perhaps it would be good if guest cpuid to
have a default values of KVM_GET_SUPPORTED_CPUID,
so that the user doesn't have to do the needless
calls to just copy host features to guest cpuid.
Powered by blists - more mailing lists