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] shadow: Re-initialise page_info's lock fi

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] shadow: Re-initialise page_info's lock field when freeing shadow pages.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 28 Jun 2008 16:00:31 -0700
Delivery-date: Sat, 28 Jun 2008 16:01:13 -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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1214573921 -3600
# Node ID 7eab6475c60afc47d1b33231d7b768232370aee6
# Parent  cebedb30a9644bdd1b7a610eaddef764c59806f9
shadow: Re-initialise page_info's lock field when freeing shadow pages.

Fixes boot failure of xenU after destroying a HVM guest.

Signed-off-by: Dongxiao Xu <dongxiao.xu@xxxxxxxxx>
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 xen/arch/x86/mm/shadow/common.c |    8 ++++++++
 1 files changed, 8 insertions(+)

diff -r cebedb30a964 -r 7eab6475c60a xen/arch/x86/mm/shadow/common.c
--- a/xen/arch/x86/mm/shadow/common.c   Fri Jun 27 14:16:53 2008 +0100
+++ b/xen/arch/x86/mm/shadow/common.c   Fri Jun 27 14:38:41 2008 +0100
@@ -1830,6 +1830,14 @@ static unsigned int sh_set_allocation(st
             sp = list_entry(d->arch.paging.shadow.freelists[order].next,
                             struct shadow_page_info, list);
             list_del(&sp->list);
+#if defined(__x86_64__)
+            /*
+             * Re-instate lock field which we overwrite with shadow_page_info.
+             * This was safe, since the lock is only used on guest pages.
+             */
+            for ( j = 0; j < 1U << order; j++ )
+                spin_lock_init(&((struct page_info *)sp)[j].lock);
+#endif
             d->arch.paging.shadow.free_pages -= 1 << order;
             d->arch.paging.shadow.total_pages -= 1 << order;
             free_domheap_pages((struct page_info *)sp, order);

_______________________________________________
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] shadow: Re-initialise page_info's lock field when freeing shadow pages., Xen patchbot-unstable <=