From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [PATCH v7 01/15] nEPT: Support LOAD_IA32_EFER entry/exit controls for L1 Date: Mon, 5 Aug 2013 07:48:54 -0400 (EDT) Message-ID: <346584789.9552175.1375703334046.JavaMail.root@redhat.com> References: <1375690040-5764-1-git-send-email-gleb@redhat.com> <1375690040-5764-2-git-send-email-gleb@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: Gleb Natapov , kvm , Xiao Guangrong , Jun Nakajima , Yang Zhang To: Arthur Chunqi Li Return-path: Received: from mx3-phx2.redhat.com ([209.132.183.24]:45479 "EHLO mx3-phx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752362Ab3HELs6 (ORCPT ); Mon, 5 Aug 2013 07:48:58 -0400 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: > > diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c > > index e999dc7..27efa6a 100644 > > --- a/arch/x86/kvm/vmx.c > > +++ b/arch/x86/kvm/vmx.c > > @@ -2198,7 +2198,8 @@ static __init void nested_vmx_setup_ctls_msrs(void) > > #else > > nested_vmx_exit_ctls_high = 0; > > #endif > > - nested_vmx_exit_ctls_high |= VM_EXIT_ALWAYSON_WITHOUT_TRUE_MSR; > > + nested_vmx_exit_ctls_high |= (VM_EXIT_ALWAYSON_WITHOUT_TRUE_MSR | > > + VM_EXIT_LOAD_IA32_EFER); > > Gleb, why we don't need to check whether host supports > VM_EXIT_LOAD_IA32_EFER here, as what you noted in my > VM_EXIT_LOAD_IA32_PAT patch? The host can also emulate VM_EXIT_LOAD_IA32_EFER using the VM-exit MSR-load feature. If neither EFER save/load nor MSR save/load are available, I believe you are right and the feature should not be available in nested VMX.