From 51705fa4cee9ee6eb4244599a4eb26bb055199c9 Mon Sep 17 00:00:00 2001
From: Sheng Yang <[EMAIL PROTECTED]>
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 <[EMAIL PROTECTED]>
---
 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
--- 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 {
--
debian.1.5.3.7.1-dirty

From 51705fa4cee9ee6eb4244599a4eb26bb055199c9 Mon Sep 17 00:00:00 2001
From: Sheng Yang <[EMAIL PROTECTED]>
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 <[EMAIL PROTECTED]>
---
 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
--- 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 {
-- 
debian.1.5.3.7.1-dirty

-------------------------------------------------------------------------
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/
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to