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] [XEN] Add tracing to slow path in setting

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [XEN] Add tracing to slow path in setting new guest %cr3 value.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 15 Aug 2006 20:30:29 +0000
Delivery-date: Tue, 15 Aug 2006 13:34:24 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/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 kfraser@xxxxxxxxxxxxxxxxxxxxx
# Node ID e65bb0de33cd0265244a0df50f3773d29b6f1263
# Parent  939f75570a15af51bb4173cb7fa945a86414431a
[XEN] Add tracing to slow path in setting new guest %cr3 value.
Also, allow x86/64 user cr3 value to be reset to zero.
Signed-off-by: Gerd Hoffmann <kraxel@xxxxxxx>
---
 xen/arch/x86/mm.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff -r 939f75570a15 -r e65bb0de33cd xen/arch/x86/mm.c
--- a/xen/arch/x86/mm.c Tue Aug 15 16:27:26 2006 +0100
+++ b/xen/arch/x86/mm.c Tue Aug 15 16:31:14 2006 +0100
@@ -1744,6 +1744,7 @@ int new_guest_cr3(unsigned long mfn)
         if ( unlikely(!okay) )
         {
             /* Switch to idle pagetable: this VCPU has no active p.t. now. */
+            MEM_LOG("New baseptr %lx: slow path via idle pagetables", mfn);
             old_base_mfn = pagetable_get_pfn(v->arch.guest_table);
             v->arch.guest_table = pagetable_null();
             update_pagetables(v);
@@ -2025,8 +2026,10 @@ int do_mmuext_op(
         
 #ifdef __x86_64__
         case MMUEXT_NEW_USER_BASEPTR:
-            okay = get_page_and_type_from_pagenr(
-                mfn, PGT_root_page_table, d);
+            okay = 1;
+            if (likely(mfn != 0))
+                okay = get_page_and_type_from_pagenr(
+                    mfn, PGT_root_page_table, d);
             if ( unlikely(!okay) )
             {
                 MEM_LOG("Error while installing new mfn %lx", mfn);

_______________________________________________
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] [XEN] Add tracing to slow path in setting new guest %cr3 value., Xen patchbot-unstable <=