From mboxrd@z Thu Jan 1 00:00:00 1970 From: Brijesh Singh Subject: Re: [PATCH v6 5/5] x86/kvm: Avoid dynamic allocation of pvclock data when SEV is active Date: Mon, 10 Sep 2018 10:30:39 -0500 Message-ID: <11618b8b-4d1f-9307-35f0-3c0f0fc856ca@amd.com> References: <1536343050-18532-1-git-send-email-brijesh.singh@amd.com> <1536343050-18532-6-git-send-email-brijesh.singh@amd.com> <20180910122727.GE21815@zn.tnic> <026d5ca5-7b77-de6c-477e-ff39f0291ac0@amd.com> <1536586152.11460.40.camel@intel.com> <097eb5f5-2cd9-8b08-32c5-d90c8e0cbb6d@amd.com> <1536593297.11460.72.camel@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Cc: brijesh.singh@amd.com, x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, Tom Lendacky , Thomas Gleixner , "H. Peter Anvin" , Paolo Bonzini , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= To: Sean Christopherson , Borislav Petkov Return-path: In-Reply-To: <1536593297.11460.72.camel@intel.com> Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 09/10/2018 10:28 AM, Sean Christopherson wrote: ... >> >> IIRC, during guest creation time qemu will check the host supported >> VCPUS count. If count is greater than KVM_MAX_VCPUS then it will >> fail to launch guest (or fail to hot plug vcpus). In other words, the >> number of vcpus in a KVM guest will never to > KVM_MAX_VCPUS. >> >> Am I missing something ? > > KVM_MAX_VCPUS is a definition for use in the *host*, it's even defined > in kvm_host.h.  The guest's pvclock code won't get magically recompiled > if KVM_MAX_VCPUS is changed in the host.  KVM_MAX_VCPUS is an arbitrary > value in the sense that there isn't a fundamental hard limit, i.e. the > value can be changed, either for a custom KVM build or in mainline, > e.g. it was bumped in 2016: > Ah I see your point. thanks for clarifying it.