From: Linus Torvalds Date: Mon, 7 Nov 2011 04:13:34 +0000 (-0800) Subject: Merge branch 'stable/cleanups-3.2' of git://git.kernel.org/pub/scm/linux/kernel/git... X-Git-Tag: v3.2-rc1~20 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=pandora-kernel.git;a=commitdiff_plain;h=daedd8708fe7707ed651bb1c83162f25c48a947c Merge branch 'stable/cleanups-3.2' of git://git./linux/kernel/git/konrad/xen * 'stable/cleanups-3.2' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen: xen: use static initializers in xen-balloon.c Xen: fix braces and tabs coding style issue in xenbus_probe.c Xen: fix braces coding style issue in xenbus_probe.h Xen: fix whitespaces,tabs coding style issue in drivers/xen/pci.c Xen: fix braces coding style issue in gntdev.c and grant-table.c Xen: fix whitespaces,tabs coding style issue in drivers/xen/events.c Xen: fix whitespaces,tabs coding style issue in drivers/xen/balloon.c Fix up trivial whitespace-conflicts in drivers/xen/{balloon.c,pci.c,xenbus/xenbus_probe.c} --- daedd8708fe7707ed651bb1c83162f25c48a947c diff --cc drivers/xen/balloon.c index 1779338e1d86,61c0ee7aa7dd..a767884a6c7a --- a/drivers/xen/balloon.c +++ b/drivers/xen/balloon.c @@@ -502,17 -373,16 +501,17 @@@ EXPORT_SYMBOL_GPL(balloon_set_new_targe * alloc_xenballooned_pages - get pages that have been ballooned out * @nr_pages: Number of pages to get * @pages: pages returned + * @highmem: highmem or lowmem pages * @return 0 on success, error otherwise */ -int alloc_xenballooned_pages(int nr_pages, struct page **pages) +int alloc_xenballooned_pages(int nr_pages, struct page **pages, bool highmem) { int pgno = 0; - struct page* page; + struct page *page; mutex_lock(&balloon_mutex); while (pgno < nr_pages) { - page = balloon_retrieve(true); - if (page) { + page = balloon_retrieve(highmem); + if (page && PageHighMem(page) == highmem) { pages[pgno++] = page; } else { enum bp_state st; diff --cc drivers/xen/xenbus/xenbus_probe.c index 0e867eeecb04,d4c7a9ffbcb9..1b178c6e8937 --- a/drivers/xen/xenbus/xenbus_probe.c +++ b/drivers/xen/xenbus/xenbus_probe.c @@@ -771,7 -759,12 +770,7 @@@ static int __init xenbus_init(void proc_mkdir("xen", NULL); #endif - out_error: - return 0; - + out_error: - if (page != 0) - free_page(page); - return err; }