aboutsummaryrefslogtreecommitdiffstats
path: root/mm/sparse.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/sparse.c')
-rw-r--r--mm/sparse.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/mm/sparse.c b/mm/sparse.c
index dc0cc4d43ff3..95ac219af379 100644
--- a/mm/sparse.c
+++ b/mm/sparse.c
@@ -382,13 +382,15 @@ static void __init sparse_early_usemaps_alloc_node(unsigned long**usemap_map,
382struct page __init *sparse_mem_map_populate(unsigned long pnum, int nid) 382struct page __init *sparse_mem_map_populate(unsigned long pnum, int nid)
383{ 383{
384 struct page *map; 384 struct page *map;
385 unsigned long size;
385 386
386 map = alloc_remap(nid, sizeof(struct page) * PAGES_PER_SECTION); 387 map = alloc_remap(nid, sizeof(struct page) * PAGES_PER_SECTION);
387 if (map) 388 if (map)
388 return map; 389 return map;
389 390
390 map = alloc_bootmem_pages_node(NODE_DATA(nid), 391 size = PAGE_ALIGN(sizeof(struct page) * PAGES_PER_SECTION);
391 PAGE_ALIGN(sizeof(struct page) * PAGES_PER_SECTION)); 392 map = __alloc_bootmem_node_high(NODE_DATA(nid), size,
393 PAGE_SIZE, __pa(MAX_DMA_ADDRESS));
392 return map; 394 return map;
393} 395}
394void __init sparse_mem_maps_populate_node(struct page **map_map, 396void __init sparse_mem_maps_populate_node(struct page **map_map,
@@ -412,7 +414,8 @@ void __init sparse_mem_maps_populate_node(struct page **map_map,
412 } 414 }
413 415
414 size = PAGE_ALIGN(size); 416 size = PAGE_ALIGN(size);
415 map = alloc_bootmem_pages_node(NODE_DATA(nodeid), size * map_count); 417 map = __alloc_bootmem_node_high(NODE_DATA(nodeid), size * map_count,
418 PAGE_SIZE, __pa(MAX_DMA_ADDRESS));
416 if (map) { 419 if (map) {
417 for (pnum = pnum_begin; pnum < pnum_end; pnum++) { 420 for (pnum = pnum_begin; pnum < pnum_end; pnum++) {
418 if (!present_section_nr(pnum)) 421 if (!present_section_nr(pnum))