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@gmail.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>

Also assert that the prev pointers are both PAGE_LIST_NULL.

Signed-off-by: Keir Fraser <keir@xen.org>
xen-unstable changeset: 25459:f6bfaf9daa50
xen-unstable date: Wed Jun  6 15:37:05 UTC 2012
This commit is contained in:
Jan Beulich committed 2012-09-04 14:46:12 +02:00
1 parent 7da8aceb07
commit d7a1b1f37f
1 file changed
+2 -1
+2 -1
View File
@@ -268,7 +268,8 @@ page_list_splice(struct page_list_head *list, struct page_list_head *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);
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.