From: Xiantao Zhang <xiantao.zhang@intel.com>
To: xen-devel@lists.xen.org
Cc: keir@xen.org, jun.nakajima@intel.com, tim@xen.org,
eddie.dong@intel.com, JBeulich@suse.com,
Zhang Xiantao <xiantao.zhang@intel.com>
Subject: [PATCH v5 00/10] Nested VMX: Add virtual EPT & VPID support to L1 VMM
Date: Wed, 9 Jan 2013 12:16:14 +0800 [thread overview]
Message-ID: <1357704984-11614-1-git-send-email-xiantao.zhang@intel.com> (raw)
From: Zhang Xiantao <xiantao.zhang@intel.com>
With virtual EPT support, L1 hyerpvisor can use EPT hardware for L2 guest's memory virtualization.
In this way, L2 guest's performance can be improved sharply.
According to our testing, some benchmarks can show > 5x performance gain.
Changes from v1:
Update the patches according to Tim's comments.
1. Patch 03: Enhance the virtual EPT's walker logic.
2. Patch 04: Add a new field in struct p2m_domain, and use it to store
EPT-specific data. For host p2m, it saves L1 VMM's EPT data,
and for nested p2m, it saves nested EPT's data 3. Patch 07: strictly check host's p2m access type.
4. Other patches: some whitespace mangling fixes.
Changes form v2:
Addressed comments from Jan and Jun:
1. Add Acked-by message for reviewed patches by Tim.
2. Fixed one whitespace mangling issue in PATCH 08 3. Add some comments to describe the meaning of
the return value of hvm_hap_nested_page_fault
in PATCH 05.
4. Add the logic for handling default case of two switch
statements.
Changes from v3:
1. Re-check all patches' whitespace mangling issue.
2. Addressed Jan's comments in Patch08 and Patch09 that once return X86EMUL_EXCEPTION, the callee
should be responsible for handling the execption before its return.
3. Addressed Tim's comments in Patch03 and Patch04 and Patch07:
Patch03: If host doesn't support exec-only capability, we shoudln't expost this feature to L1 VMM.
Once map guest's EPT table error, inject an EPT misconfiguration errot to L1.
Patch04: Re-organize p2m's and nested p2m's structure {init/teardown} logic.
Patch07: Initialize p2ma_21 -> p2m_access_rwx, so not to change SVM's behavior.
Changes from v4:
Patch08/09: Minor changes according to Jan's comments.
Zhang Xiantao (10):
nestedhap: Change hostcr3 and p2m->cr3 to meaningful words
nestedhap: Change nested p2m's walker to vendor-specific
nested_ept: Implement guest ept's walker
EPT: Make ept data structure or operations neutral
nEPT: Try to enable EPT paging for L2 guest.
nEPT: Sync PDPTR fields if L2 guest in PAE paging mode
nEPT: Use minimal permission for nested p2m.
nEPT: handle invept instruction from L1 VMM
nVMX: virutalize VPID capability to nested VMM.
nEPT: Expose EPT & VPID capablities to L1 VMM
xen/arch/x86/hvm/hvm.c | 7 +-
xen/arch/x86/hvm/svm/nestedsvm.c | 31 ++++
xen/arch/x86/hvm/svm/svm.c | 3 +-
xen/arch/x86/hvm/vmx/vmcs.c | 8 +-
xen/arch/x86/hvm/vmx/vmx.c | 97 ++++------
xen/arch/x86/hvm/vmx/vvmx.c | 205 ++++++++++++++++++++--
xen/arch/x86/mm/guest_walk.c | 16 +-
xen/arch/x86/mm/hap/Makefile | 1 +
xen/arch/x86/mm/hap/nested_ept.c | 298 +++++++++++++++++++++++++++++++
xen/arch/x86/mm/hap/nested_hap.c | 96 ++++++-----
xen/arch/x86/mm/mm-locks.h | 2 +-
xen/arch/x86/mm/p2m-ept.c | 104 +++++++++---
xen/arch/x86/mm/p2m.c | 158 +++++++++++------
xen/include/asm-x86/guest_pt.h | 8 +
xen/include/asm-x86/hvm/hvm.h | 9 +-
xen/include/asm-x86/hvm/nestedhvm.h | 1 +
xen/include/asm-x86/hvm/svm/nestedsvm.h | 3 +
xen/include/asm-x86/hvm/vmx/vmcs.h | 24 ++--
xen/include/asm-x86/hvm/vmx/vmx.h | 41 ++++-
xen/include/asm-x86/hvm/vmx/vvmx.h | 30 +++-
xen/include/asm-x86/p2m.h | 20 ++-
21 files changed, 937 insertions(+), 225 deletions(-)
create mode 100644 xen/arch/x86/mm/hap/nested_ept.c
next reply other threads:[~2013-01-09 4:16 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-09 4:16 Xiantao Zhang [this message]
2013-01-09 4:16 ` [PATCH v5 01/10] nestedhap: Change hostcr3 and p2m->cr3 to meaningful words Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 02/10] nestedhap: Change nested p2m's walker to vendor-specific Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 03/10] nested_ept: Implement guest ept's walker Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 04/10] EPT: Make ept data structure or operations neutral Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 05/10] nEPT: Try to enable EPT paging for L2 guest Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 06/10] nEPT: Sync PDPTR fields if L2 guest in PAE paging mode Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 07/10] nEPT: Use minimal permission for nested p2m Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 08/10] nEPT: handle invept instruction from L1 VMM Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 09/10] nVMX: virutalize VPID capability to nested VMM Xiantao Zhang
2013-01-09 4:16 ` [PATCH v5 10/10] nEPT: Expose EPT & VPID capablities to L1 VMM Xiantao Zhang
2013-01-09 11:38 ` [PATCH v5 00/10] Nested VMX: Add virtual EPT & VPID support " Jan Beulich
2013-01-10 12:46 ` Tim Deegan
2013-01-10 13:55 ` Nakajima, Jun
2013-01-11 0:55 ` Dong, Eddie
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=1357704984-11614-1-git-send-email-xiantao.zhang@intel.com \
--to=xiantao.zhang@intel.com \
--cc=JBeulich@suse.com \
--cc=eddie.dong@intel.com \
--cc=jun.nakajima@intel.com \
--cc=keir@xen.org \
--cc=tim@xen.org \
--cc=xen-devel@lists.xen.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;
as well as URLs for NNTP newsgroup(s).