Re: [PATCH 03/22] KVM: nVMX: Fail VMPTRLD when vmcs12 is shadow VMCS and nested CPU do not support VMCS shadowing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2018-06-23 02:35+0300, Liran Alon:
> Signed-off-by: Liran Alon <liran.alon@xxxxxxxxxx>
> Signed-off-by: Jim Mattson <jmattson@xxxxxxxxxx>
> ---
>  arch/x86/kvm/vmx.c | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
> index 651ce405995c..4861fea7a397 100644
> --- a/arch/x86/kvm/vmx.c
> +++ b/arch/x86/kvm/vmx.c
> @@ -1710,6 +1710,12 @@ static inline bool nested_cpu_has_vmwrite_any_field(struct kvm_vcpu *vcpu)
>  		MSR_IA32_VMX_MISC_VMWRITE_SHADOW_RO_FIELDS;
>  }
>  
> +static inline bool nested_cpu_has_vmx_shadow_vmcs(struct kvm_vcpu *vcpu)
> +{
> +	return to_vmx(vcpu)->nested.msrs.secondary_ctls_high &
> +		SECONDARY_EXEC_SHADOW_VMCS;

Please change the name to nested_cpu_supports_vmx_shadow_vmcs().

"nested_cpu_has" prefix is reserved for features that are enabled in VM
controls,

thanks.



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux