WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] nestedsvm: fix shadow-on-hap

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] nestedsvm: fix shadow-on-hap
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Sat, 14 May 2011 07:15:53 +0100
Delivery-date: Fri, 13 May 2011 23:17:15 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Christoph Egger <Christoph.Egger@xxxxxxx>
# Date 1305187655 -3600
# Node ID 1e29db7a3b6bcae442676ed52f574434cfe0aba7
# Parent  19d6541c4abec3486c83de76102ec46d7fe22a16
nestedsvm: fix shadow-on-hap

Signed-off-by: Christoph Egger <Christoph.Egger@xxxxxxx>
Acked-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
---


diff -r 19d6541c4abe -r 1e29db7a3b6b xen/arch/x86/hvm/svm/entry.S
--- a/xen/arch/x86/hvm/svm/entry.S      Thu May 12 09:00:46 2011 +0100
+++ b/xen/arch/x86/hvm/svm/entry.S      Thu May 12 09:07:35 2011 +0100
@@ -65,12 +65,16 @@
         testl $~0,(r(dx),r(ax),1)
         jnz  .Lsvm_process_softirqs
 
+        testb $0, VCPU_nsvm_hap_enabled(r(bx))
+        jz  .Lsvm_asid_handle
+        
         mov  VCPU_nhvm_p2m(r(bx)),r(ax)
         test r(ax),r(ax)
         sete %al
         andb VCPU_nhvm_guestmode(r(bx)),%al
         jnz  .Lsvm_nsvm_no_p2m
 
+.Lsvm_asid_handle:
         call svm_asid_handle_vmrun
 
         cmpb $0,addr_of(tb_init_done)
diff -r 19d6541c4abe -r 1e29db7a3b6b xen/arch/x86/hvm/svm/nestedsvm.c
--- a/xen/arch/x86/hvm/svm/nestedsvm.c  Thu May 12 09:00:46 2011 +0100
+++ b/xen/arch/x86/hvm/svm/nestedsvm.c  Thu May 12 09:07:35 2011 +0100
@@ -494,6 +494,7 @@
         /* host nested paging + guest shadow paging. */
         n2vmcb->_np_enable = 1;
         /* Keep h_cr3 as it is. */
+        n2vmcb->_h_cr3 = n1vmcb->_h_cr3;
         /* When l1 guest does shadow paging
          * we assume it intercepts page faults.
          */
diff -r 19d6541c4abe -r 1e29db7a3b6b xen/arch/x86/x86_32/asm-offsets.c
--- a/xen/arch/x86/x86_32/asm-offsets.c Thu May 12 09:00:46 2011 +0100
+++ b/xen/arch/x86/x86_32/asm-offsets.c Thu May 12 09:07:35 2011 +0100
@@ -95,6 +95,7 @@
 
     OFFSET(VCPU_nhvm_guestmode, struct vcpu, arch.hvm_vcpu.nvcpu.nv_guestmode);
     OFFSET(VCPU_nhvm_p2m, struct vcpu, arch.hvm_vcpu.nvcpu.nv_p2m);
+    OFFSET(VCPU_nsvm_hap_enabled, struct vcpu, 
arch.hvm_vcpu.nvcpu.u.nsvm.ns_hap_enabled);
     BLANK();
 
     OFFSET(VMCB_rax, struct vmcb_struct, rax);
diff -r 19d6541c4abe -r 1e29db7a3b6b xen/arch/x86/x86_64/asm-offsets.c
--- a/xen/arch/x86/x86_64/asm-offsets.c Thu May 12 09:00:46 2011 +0100
+++ b/xen/arch/x86/x86_64/asm-offsets.c Thu May 12 09:07:35 2011 +0100
@@ -117,6 +117,7 @@
 
     OFFSET(VCPU_nhvm_guestmode, struct vcpu, arch.hvm_vcpu.nvcpu.nv_guestmode);
     OFFSET(VCPU_nhvm_p2m, struct vcpu, arch.hvm_vcpu.nvcpu.nv_p2m);
+    OFFSET(VCPU_nsvm_hap_enabled, struct vcpu, 
arch.hvm_vcpu.nvcpu.u.nsvm.ns_hap_enabled);
     BLANK();
 
     OFFSET(DOMAIN_is_32bit_pv, struct domain, arch.is_32bit_pv);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] nestedsvm: fix shadow-on-hap, Xen patchbot-unstable <=