[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] xen: fix page_list_splice()


  • To: xen-changelog@xxxxxxxxxxxxxxxxxxx
  • From: Xen patchbot-unstable <patchbot@xxxxxxx>
  • Date: Thu, 07 Jun 2012 02:44:10 +0000
  • Delivery-date: Thu, 07 Jun 2012 02:44:19 +0000
  • List-id: "Change log for Mercurial \(receive only\)" <xen-changelog.lists.xen.org>

# HG changeset patch
# User Jan Beulich <jbeulich@xxxxxxxx>
# Date 1338997025 -3600
# Node ID f6bfaf9daa508c31b2bca0e461202db2759426fc
# Parent  8ec2c428f4dad55cf6d91b893a19c2218972db5e
xen: fix page_list_splice()

Other than in __list_splice(), the first element's prev pointer
doesn't need adjustment here - it already is PAGE_LIST_NULL. Rather
than fixing the assignment (to formally match __list_splice()), simply
assert that this assignment is really unnecessary.

Reported-by: Jisoo Yang <jisooy@xxxxxxxxx>
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>

Also assert that the prev pointers are both PAGE_LIST_NULL.

Signed-off-by: Keir Fraser <keir@xxxxxxx>

Committed-by: Keir Fraser <keir@xxxxxxx>
---


diff -r 8ec2c428f4da -r f6bfaf9daa50 xen/include/xen/mm.h
--- a/xen/include/xen/mm.h      Wed Jun 06 16:34:53 2012 +0100
+++ b/xen/include/xen/mm.h      Wed Jun 06 16:37:05 2012 +0100
@@ -270,7 +270,8 @@ page_list_splice(struct page_list_head *
     last = list->tail;
     at = head->next;
 
-    first->list.prev = page_to_pdx(head->next);
+    ASSERT(first->list.prev == PAGE_LIST_NULL);
+    ASSERT(first->list.prev == at->list.prev);
     head->next = first;
 
     last->list.next = page_to_pdx(at);

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.