diff options
author | Jan Beulich <jbeulich@suse.com> | 2012-06-06 16:37:05 +0100 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2012-06-06 16:37:05 +0100 |
commit | d4b4e22f2b94e5a5f9392f7db2c44b219966f9d0 (patch) | |
tree | 455669e45a92622b965f48e88f566abb6003b113 /xen/include/xen/mm.h | |
parent | db48465811a8d983a349d7b8a96c16f6adf942dc (diff) | |
download | xen-d4b4e22f2b94e5a5f9392f7db2c44b219966f9d0.tar.gz xen-d4b4e22f2b94e5a5f9392f7db2c44b219966f9d0.tar.bz2 xen-d4b4e22f2b94e5a5f9392f7db2c44b219966f9d0.zip |
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>
Committed-by: Keir Fraser <keir@xen.org>
Diffstat (limited to 'xen/include/xen/mm.h')
-rw-r--r-- | xen/include/xen/mm.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xen/include/xen/mm.h b/xen/include/xen/mm.h index 11381a1303..64a0cc15f2 100644 --- a/xen/include/xen/mm.h +++ b/xen/include/xen/mm.h @@ -270,7 +270,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); |