From: Sheng Yang <sheng@linux.intel.com>
To: Greg KH <greg@kroah.com>
Cc: stable <stable@kernel.org>,
kvm@vger.kernel.org, Avi Kivity <avi@redhat.com>,
Marcelo Tosatti <mtosatti@redhat.com>,
Alexander Graf <agraf@suse.de>,
Sheng Yang <sheng@linux.intel.com>
Subject: [PATCH] KVM: VMX: Disable unrestricted guest when EPT disabled
Date: Thu, 18 Mar 2010 14:11:19 +0800 [thread overview]
Message-ID: <1268892679-20674-1-git-send-email-sheng@linux.intel.com> (raw)
Otherwise would cause VMEntry failure when using ept=0 on unrestricted guest
supported processors.
Signed-off-by: Sheng Yang <sheng@linux.intel.com>
---
Please apply this to 2.6.32 stable. Thanks!
Patch already in the upstream, commit:
046d87103addc117f0d397196e85189722d4d7de
arch/x86/kvm/vmx.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 80367c5..1092e8a 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2316,8 +2316,10 @@ static int vmx_vcpu_setup(struct vcpu_vmx *vmx)
~SECONDARY_EXEC_VIRTUALIZE_APIC_ACCESSES;
if (vmx->vpid == 0)
exec_control &= ~SECONDARY_EXEC_ENABLE_VPID;
- if (!enable_ept)
+ if (!enable_ept) {
exec_control &= ~SECONDARY_EXEC_ENABLE_EPT;
+ enable_unrestricted_guest = 0;
+ }
if (!enable_unrestricted_guest)
exec_control &= ~SECONDARY_EXEC_UNRESTRICTED_GUEST;
vmcs_write32(SECONDARY_VM_EXEC_CONTROL, exec_control);
--
1.5.4.5
next reply other threads:[~2010-03-18 6:11 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-18 6:11 Sheng Yang [this message]
2010-04-07 21:49 ` [PATCH] KVM: VMX: Disable unrestricted guest when EPT disabled Greg KH
-- strict thread matches above, loose matches on Subject: below --
2009-11-27 8:46 Sheng Yang
2009-11-30 22:02 ` Marcelo Tosatti
2010-03-17 18:37 ` Alexander Graf
2010-03-18 1:50 ` Sheng Yang
2010-03-18 5:51 ` Alexander Graf
2010-03-18 5:57 ` Sheng Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1268892679-20674-1-git-send-email-sheng@linux.intel.com \
--to=sheng@linux.intel.com \
--cc=agraf@suse.de \
--cc=avi@redhat.com \
--cc=greg@kroah.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
--cc=stable@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox