aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh
diff options
context:
space:
mode:
authorJohannes Weiner <hannes@saeurebad.de>2008-07-24 00:26:55 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-07-24 13:47:14 -0400
commitb61bfa3c462671c48a51fb5c31af337c5a996a04 (patch)
tree020363fd43a85ddde9998759150b428ee794dae6 /arch/sh
parent8b05c7e6e159d2f33c9275281b8b909a89eb7c5d (diff)
mm: move bootmem descriptors definition to a single place
There are a lot of places that define either a single bootmem descriptor or an array of them. Use only one central array with MAX_NUMNODES items instead. Signed-off-by: Johannes Weiner <hannes@saeurebad.de> Acked-by: Ralf Baechle <ralf@linux-mips.org> Cc: Ingo Molnar <mingo@elte.hu> Cc: Richard Henderson <rth@twiddle.net> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Tony Luck <tony.luck@intel.com> Cc: Hirokazu Takata <takata@linux-m32r.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Kyle McMartin <kyle@parisc-linux.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Paul Mundt <lethal@linux-sh.org> Cc: David S. Miller <davem@davemloft.net> Cc: Yinghai Lu <yhlu.kernel@gmail.com> Cc: Christoph Lameter <cl@linux-foundation.org> Cc: Mel Gorman <mel@csn.ul.ie> 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 'arch/sh')
-rw-r--r--arch/sh/mm/numa.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/sh/mm/numa.c b/arch/sh/mm/numa.c
index 1663199ce888..095d93bec7cd 100644
--- a/arch/sh/mm/numa.c
+++ b/arch/sh/mm/numa.c
@@ -14,7 +14,6 @@
14#include <linux/pfn.h> 14#include <linux/pfn.h>
15#include <asm/sections.h> 15#include <asm/sections.h>
16 16
17static bootmem_data_t plat_node_bdata[MAX_NUMNODES];
18struct pglist_data *node_data[MAX_NUMNODES] __read_mostly; 17struct pglist_data *node_data[MAX_NUMNODES] __read_mostly;
19EXPORT_SYMBOL_GPL(node_data); 18EXPORT_SYMBOL_GPL(node_data);
20 19
@@ -35,7 +34,7 @@ void __init setup_memory(void)
35 NODE_DATA(0) = pfn_to_kaddr(free_pfn); 34 NODE_DATA(0) = pfn_to_kaddr(free_pfn);
36 memset(NODE_DATA(0), 0, sizeof(struct pglist_data)); 35 memset(NODE_DATA(0), 0, sizeof(struct pglist_data));
37 free_pfn += PFN_UP(sizeof(struct pglist_data)); 36 free_pfn += PFN_UP(sizeof(struct pglist_data));
38 NODE_DATA(0)->bdata = &plat_node_bdata[0]; 37 NODE_DATA(0)->bdata = &bootmem_node_data[0];
39 38
40 /* Set up node 0 */ 39 /* Set up node 0 */
41 setup_bootmem_allocator(free_pfn); 40 setup_bootmem_allocator(free_pfn);
@@ -66,7 +65,7 @@ void __init setup_bootmem_node(int nid, unsigned long start, unsigned long end)
66 free_pfn += PFN_UP(sizeof(struct pglist_data)); 65 free_pfn += PFN_UP(sizeof(struct pglist_data));
67 memset(NODE_DATA(nid), 0, sizeof(struct pglist_data)); 66 memset(NODE_DATA(nid), 0, sizeof(struct pglist_data));
68 67
69 NODE_DATA(nid)->bdata = &plat_node_bdata[nid]; 68 NODE_DATA(nid)->bdata = &bootmem_node_data[nid];
70 NODE_DATA(nid)->node_start_pfn = start_pfn; 69 NODE_DATA(nid)->node_start_pfn = start_pfn;
71 NODE_DATA(nid)->node_spanned_pages = end_pfn - start_pfn; 70 NODE_DATA(nid)->node_spanned_pages = end_pfn - start_pfn;
72 71