lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 14 Oct 2015 06:47:08 +0800
From:	Wanpeng Li <wanpeng.li@...mail.com>
To:	Paolo Bonzini <pbonzini@...hat.com>
CC:	Jan Kiszka <jan.kiszka@...mens.com>, Bandan Das <bsd@...hat.com>,
	Wincy Van <fanwenyi0529@...il.com>, kvm@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 5/5] KVM: nVMX: expose VPID capability to L1

On 10/13/15 10:44 PM, Paolo Bonzini wrote:
>
> On 08/10/2015 07:57, Wanpeng Li wrote:
>> Expose VPID capability to L1. For nested guests, we don't do anything
>> specific for single context invalidation. Hence, only advertise support
>> for global context invalidation. The major benefit of nested VPID comes
>> from having separate vpids when switching between L1 and L2, and also
>> when L2's vCPUs not sched in/out on L1.
>>
>> Reviewed-by: Wincy Van <fanwenyi0529@...il.com>
>> Signed-off-by: Wanpeng Li <wanpeng.li@...mail.com>
>> ---
>>   arch/x86/kvm/vmx.c | 36 ++++++++++++++++++++++++------------
>>   1 file changed, 24 insertions(+), 12 deletions(-)
>>
>> diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
>> index 31d272e..22b4dc7 100644
>> --- a/arch/x86/kvm/vmx.c
>> +++ b/arch/x86/kvm/vmx.c
>> @@ -442,7 +442,7 @@ struct nested_vmx {
>>   	u32 nested_vmx_true_entry_ctls_low;
>>   	u32 nested_vmx_misc_low;
>>   	u32 nested_vmx_misc_high;
>> -	u32 nested_vmx_ept_caps;
>> +	u64 nested_vmx_ept_vpid_caps;
> Considering that all VMX_VPID_ constants are off by 32, perhaps it's
> simpler to have separate variables for nested_vmx_ept_caps and
> nested_vmx_vpid_caps, and only rejoin them when reading the MSR.  It
> will make this patch smaller too.
>
> You can add the new field to struct nested_vmx in patch 3 (leaving it
> initialized to 0, of course).

Good point. I will do it after the new travel recently. :-)

Regards,
Wanpeng Li
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ