aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorKAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>2007-11-28 19:21:57 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-11-29 12:24:54 -0500
commite0dc3a53def41efeabb3f39ad8e9f67e81ca1025 (patch)
treef605744bf9998c062079c1369924e93a617ef42a /mm
parent164e217cec236f84718676543659181ea300a862 (diff)
memory hotplug fix: fix section mismatch in vmammap_allock_block()
Fixes section mismatch below. WARNING: vmlinux.o(.text+0x946b5): Section mismatch: reference to .init.text:' __alloc_bootmem_node (between 'vmemmap_alloc_block' and 'vmemmap_pgd_populate') Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com> Cc: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/sparse-vmemmap.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/mm/sparse-vmemmap.c b/mm/sparse-vmemmap.c
index 22620f6a976b..cd75b21dd4c3 100644
--- a/mm/sparse-vmemmap.c
+++ b/mm/sparse-vmemmap.c
@@ -34,6 +34,16 @@
34 * or to back the page tables that are used to create the mapping. 34 * or to back the page tables that are used to create the mapping.
35 * Uses the main allocators if they are available, else bootmem. 35 * Uses the main allocators if they are available, else bootmem.
36 */ 36 */
37
38static void * __init_refok __earlyonly_bootmem_alloc(int node,
39 unsigned long size,
40 unsigned long align,
41 unsigned long goal)
42{
43 return __alloc_bootmem_node(NODE_DATA(node), size, align, goal);
44}
45
46
37void * __meminit vmemmap_alloc_block(unsigned long size, int node) 47void * __meminit vmemmap_alloc_block(unsigned long size, int node)
38{ 48{
39 /* If the main allocator is up use that, fallback to bootmem. */ 49 /* If the main allocator is up use that, fallback to bootmem. */
@@ -44,7 +54,7 @@ void * __meminit vmemmap_alloc_block(unsigned long size, int node)
44 return page_address(page); 54 return page_address(page);
45 return NULL; 55 return NULL;
46 } else 56 } else
47 return __alloc_bootmem_node(NODE_DATA(node), size, size, 57 return __earlyonly_bootmem_alloc(node, size, size,
48 __pa(MAX_DMA_ADDRESS)); 58 __pa(MAX_DMA_ADDRESS));
49} 59}
50 60