lkml.org 
[lkml]   [2020]   [Mar]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 2/2] KVM: x86: VMX: untangle VMXON revision_id setting when using eVMCS
Date
Sean Christopherson <sean.j.christopherson@intel.com> writes:

> On Thu, Mar 05, 2020 at 11:01:23AM +0100, Vitaly Kuznetsov wrote:
>> As stated in alloc_vmxon_regions(), VMXON region needs to be tagged with
>> revision id from MSR_IA32_VMX_BASIC even in case of eVMCS. The logic to
>> do so is not very straightforward: first, we set
>> hdr.revision_id = KVM_EVMCS_VERSION in alloc_vmcs_cpu() just to reset it
>> back to vmcs_config.revision_id in alloc_vmxon_regions(). Simplify this by
>> introducing 'enum vmx_area_type' parameter to what is now known as
>> alloc_vmx_area_cpu().
>
> I'd strongly prefer to keep the alloc_vmcs_cpu() name and call the new enum
> "vmcs_type". The discrepancy could be resolved by a comment above the
> VMXON_REGION usage, e.g.
>
> /* The VMXON region is really just a special type of VMCS. */
> vmcs = alloc_vmcs_cpu(VMXON_REGION, cpu, GFP_KERNEL);

I have no strong opinion (but honestly I don't really know what VMXON
region is being used for), Paolo already said 'queued' but I think I'll
send v2 with the suggested changes (including patch prefixes :-)

--
Vitaly

\
 
 \ /
  Last update: 2020-03-05 17:34    [W:0.077 / U:22.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site