From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Yang, Sheng" Subject: [RFC][PATCH 1/7] KVM: Add EPT support in kvm_arch Date: Fri, 1 Feb 2008 16:21:07 +0800 Message-ID: <200802011621.07697.sheng.yang@intel.com> Mime-Version: 1.0 Content-Type: Multipart/Mixed; boundary="Boundary-00=_zZtoH+zDf8CBfCU" Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org To: Avi Kivity Return-path: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org --Boundary-00=_zZtoH+zDf8CBfCU Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline =46rom 51705fa4cee9ee6eb4244599a4eb26bb055199c9 Mon Sep 17 00:00:00 2001 =46rom: Sheng Yang Date: Fri, 1 Feb 2008 05:08:35 +0800 Subject: [PATCH] KVM: Add EPT support in kvm_arch EPT pointer is a per-domain data, and it contains info more than root_hpa. = It may can be put in a better place, but we haven't found yet. Signed-off-by: Sheng Yang =2D-- include/asm-x86/kvm_host.h | 15 +++++++++++++++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git a/include/asm-x86/kvm_host.h b/include/asm-x86/kvm_host.h index 67ae307..f6028c6 100644 =2D-- a/include/asm-x86/kvm_host.h +++ b/include/asm-x86/kvm_host.h @@ -269,6 +269,17 @@ struct kvm_mem_alias { gfn_t target_gfn; }; +typedef union { + struct { + u64 etmt : 3, + gaw : 3, + rsvd1 : 6, + asr_mfn : 45, + rsvd2 : 7; + } fields; + u64 entry; +} eptp_t; + struct kvm_arch{ int naliases; struct kvm_mem_alias aliases[KVM_ALIAS_SLOTS]; @@ -287,6 +298,10 @@ struct kvm_arch{ int round_robin_prev_vcpu; unsigned int tss_addr; struct page *apic_access_page; + + eptp_t eptp; + atomic_t ept_npages, guest_npages; + struct mutex ept_mutex; }; struct kvm_vm_stat { =2D- debian.1.5.3.7.1-dirty --Boundary-00=_zZtoH+zDf8CBfCU Content-Type: text/x-diff; charset="utf-8"; name="0001-KVM-Add-EPT-support-in-kvm_arch.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="0001-KVM-Add-EPT-support-in-kvm_arch.patch" =46rom 51705fa4cee9ee6eb4244599a4eb26bb055199c9 Mon Sep 17 00:00:00 2001 =46rom: Sheng Yang Date: Fri, 1 Feb 2008 05:08:35 +0800 Subject: [PATCH] KVM: Add EPT support in kvm_arch EPT pointer is a per-domain data, and it contains info more than root_hpa. = It may can be put in a better place, but we haven't found yet. Signed-off-by: Sheng Yang =2D-- include/asm-x86/kvm_host.h | 15 +++++++++++++++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git a/include/asm-x86/kvm_host.h b/include/asm-x86/kvm_host.h index 67ae307..f6028c6 100644 =2D-- a/include/asm-x86/kvm_host.h +++ b/include/asm-x86/kvm_host.h @@ -269,6 +269,17 @@ struct kvm_mem_alias { gfn_t target_gfn; }; =20 +typedef union { + struct { + u64 etmt : 3, + gaw : 3, + rsvd1 : 6, + asr_mfn : 45, + rsvd2 : 7; + } fields; + u64 entry; +} eptp_t; + struct kvm_arch{ int naliases; struct kvm_mem_alias aliases[KVM_ALIAS_SLOTS]; @@ -287,6 +298,10 @@ struct kvm_arch{ int round_robin_prev_vcpu; unsigned int tss_addr; struct page *apic_access_page; + + eptp_t eptp; + atomic_t ept_npages, guest_npages; + struct mutex ept_mutex; }; =20 struct kvm_vm_stat { =2D-=20 debian.1.5.3.7.1-dirty --Boundary-00=_zZtoH+zDf8CBfCU Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ --Boundary-00=_zZtoH+zDf8CBfCU Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kvm-devel mailing list kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/kvm-devel --Boundary-00=_zZtoH+zDf8CBfCU--