From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [PATCH] KVM: nVMX: Report 2MB EPT pages as supported Date: Mon, 28 Oct 2013 13:57:10 +0100 Message-ID: <526E5F26.4010005@redhat.com> References: <5267D1CF.5000501@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Gleb Natapov , kvm To: Jan Kiszka Return-path: Received: from mx1.redhat.com ([209.132.183.28]:54574 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752050Ab3J1M5Q (ORCPT ); Mon, 28 Oct 2013 08:57:16 -0400 In-Reply-To: <5267D1CF.5000501@siemens.com> Sender: kvm-owner@vger.kernel.org List-ID: Il 23/10/2013 15:40, Jan Kiszka ha scritto: > As long as the hardware provides us 2MB EPT pages, we can also expose > them to the guest because our shadow EPT code already supports this > feature. > > Signed-off-by: Jan Kiszka > --- > arch/x86/kvm/vmx.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c > index 06fd762..feef3a1 100644 > --- a/arch/x86/kvm/vmx.c > +++ b/arch/x86/kvm/vmx.c > @@ -2261,7 +2261,8 @@ static __init void nested_vmx_setup_ctls_msrs(void) > /* nested EPT: emulate EPT also to L1 */ > nested_vmx_secondary_ctls_high |= SECONDARY_EXEC_ENABLE_EPT; > nested_vmx_ept_caps = VMX_EPT_PAGE_WALK_4_BIT | > - VMX_EPTP_WB_BIT | VMX_EPT_INVEPT_BIT; > + VMX_EPTP_WB_BIT | VMX_EPT_2MB_PAGE_BIT | > + VMX_EPT_INVEPT_BIT; > nested_vmx_ept_caps &= vmx_capability.ept; > /* > * Since invept is completely emulated we support both global > Applied to kvm.git queue, thanks. Paolo