Merge branch 'release' of master.kernel.org:/pub/scm/linux/kernel/git/aegl/linux-2.6
[pandora-kernel.git] / mm / sparse.c
index e0a3fe4..b3c82ba 100644 (file)
@@ -1,7 +1,6 @@
 /*
  * sparse memory mappings.
  */
-#include <linux/config.h>
 #include <linux/mm.h>
 #include <linux/mmzone.h>
 #include <linux/bootmem.h>
@@ -45,7 +44,7 @@ static struct mem_section *sparse_index_alloc(int nid)
 
 static int sparse_index_init(unsigned long section_nr, int nid)
 {
-       static spinlock_t index_init_lock = SPIN_LOCK_UNLOCKED;
+       static DEFINE_SPINLOCK(index_init_lock);
        unsigned long root = SECTION_NR_TO_ROOT(section_nr);
        struct mem_section *section;
        int ret = 0;
@@ -212,7 +211,7 @@ static struct page *__kmalloc_section_memmap(unsigned long nr_pages)
        struct page *page, *ret;
        unsigned long memmap_size = sizeof(struct page) * nr_pages;
 
-       page = alloc_pages(GFP_KERNEL, get_order(memmap_size));
+       page = alloc_pages(GFP_KERNEL|__GFP_NOWARN, get_order(memmap_size));
        if (page)
                goto got_map_page;