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] Fixes unmodified 32-bit guest support on the x86_64 Xen.

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Fixes unmodified 32-bit guest support on the x86_64 Xen.
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 03 Dec 2005 17:50:07 +0000
Delivery-date: Sat, 03 Dec 2005 17:50:26 +0000
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/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 kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID d234a8cfc4ca3c57437a99d377a1abf44835caa9
# Parent  1c515c7072969884e61aff5367c47e6641e015f3
Fixes unmodified 32-bit guest support on the x86_64 Xen.

Signed-off-by: Jun Nakajima <jun.nakajima@xxxxxxxxx>
Signed-off-by: Xiaohui Xin <xiaohui.xin@xxxxxxxxx>

diff -r 1c515c707296 -r d234a8cfc4ca xen/arch/x86/shadow.c
--- a/xen/arch/x86/shadow.c     Sat Dec  3 12:36:22 2005
+++ b/xen/arch/x86/shadow.c     Sat Dec  3 16:41:16 2005
@@ -637,6 +637,11 @@
         gpl1e = (guest_l1_pgentry_t *) map_domain_page(tmp_gmfn);
 
         /* If the PGT_l1_shadow has two continual pages */
+#if CONFIG_PAGING_LEVELS >=3
+        if (d->arch.ops->guest_paging_levels == PAGING_L2)
+            __shadow_get_l2e(v,  va & ~((1<<L2_PAGETABLE_SHIFT_32) - 1), 
&tmp_sl2e);
+        else
+#endif
         __shadow_get_l2e(v, va, &tmp_sl2e);
         spl1e = (l1_pgentry_t *) map_domain_page(l2e_get_pfn(tmp_sl2e));
 
@@ -1809,9 +1814,12 @@
     }
 #endif
 
-    need_flush |= resync_all(d, PGT_l2_shadow);
-
 #if CONFIG_PAGING_LEVELS >= 3
+    if (d->arch.ops->guest_paging_levels == PAGING_L2)
+        need_flush |= resync_all(d, PGT_l4_shadow);
+    else
+        need_flush |= resync_all(d, PGT_l2_shadow);
+
     if (d->arch.ops->guest_paging_levels >= PAGING_L3) 
     {
         need_flush |= resync_all(d, PGT_l3_shadow);
@@ -2943,6 +2951,8 @@
        sl2_p[sl2_idx + 1] =
             entry_from_pfn(sl1mfn + 1, entry_get_flags(sl2_p[sl2_idx]));
     }
+    else
+        sl2_p[sl2_idx + 1] = (pgentry_64_t){0};
     unmap_domain_page(sl2_p);
 
 }
@@ -3528,9 +3538,9 @@
 
     __shadow_sync_va(v, va);
 
-    if ( __shadow_get_l1e(v, va, &old_sl1e) )
+    if ( shadow_mode_external(d) && __shadow_get_l1e(v, va, &old_sl1e) )
         if ( l1e_get_flags(old_sl1e) & _PAGE_PRESENT )
-            shadow_put_page_from_l1e(old_sl1e, d);
+            put_page_from_l1e(old_sl1e, d);
 
     sl1e = l1e_empty();
     __shadow_set_l1e(v, va, &sl1e);

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Fixes unmodified 32-bit guest support on the x86_64 Xen., Xen patchbot -unstable <=