diff options
author | Yinghai Lu <yhlu.kernel@gmail.com> | 2008-06-01 01:51:51 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-06-03 07:26:24 -0400 |
commit | ba924c81dd5a7a7fb5ded025af7fdd3b61f8ca67 (patch) | |
tree | a451d273a87c813782bbe1cb171af0c1d9b7d4d9 /arch/x86/mm/discontig_32.c | |
parent | 4c1cbafb88490757a38119c41229251369bcecbc (diff) |
x86, numa, 32-bit: increase max_elements to 1024
so every element will represent 64M instead of 256M.
AMD opteron could have HW memory hole remapping, so could have
[0, 8g + 64M) on node0. Reduce element size to 64M to keep that on node 0
Later we need to use find_e820_area() to allocate memory_node_map like
on 64-bit. But need to move memory_present out of populate_mem_map...
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/mm/discontig_32.c')
-rw-r--r-- | arch/x86/mm/discontig_32.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/x86/mm/discontig_32.c b/arch/x86/mm/discontig_32.c index 55fdbab6b014..922af20d1d29 100644 --- a/arch/x86/mm/discontig_32.c +++ b/arch/x86/mm/discontig_32.c | |||
@@ -59,14 +59,14 @@ unsigned long node_end_pfn[MAX_NUMNODES] __read_mostly; | |||
59 | /* | 59 | /* |
60 | * 4) physnode_map - the mapping between a pfn and owning node | 60 | * 4) physnode_map - the mapping between a pfn and owning node |
61 | * physnode_map keeps track of the physical memory layout of a generic | 61 | * physnode_map keeps track of the physical memory layout of a generic |
62 | * numa node on a 256Mb break (each element of the array will | 62 | * numa node on a 64Mb break (each element of the array will |
63 | * represent 256Mb of memory and will be marked by the node id. so, | 63 | * represent 64Mb of memory and will be marked by the node id. so, |
64 | * if the first gig is on node 0, and the second gig is on node 1 | 64 | * if the first gig is on node 0, and the second gig is on node 1 |
65 | * physnode_map will contain: | 65 | * physnode_map will contain: |
66 | * | 66 | * |
67 | * physnode_map[0-3] = 0; | 67 | * physnode_map[0-15] = 0; |
68 | * physnode_map[4-7] = 1; | 68 | * physnode_map[16-31] = 1; |
69 | * physnode_map[8- ] = -1; | 69 | * physnode_map[32- ] = -1; |
70 | */ | 70 | */ |
71 | s8 physnode_map[MAX_ELEMENTS] __read_mostly = { [0 ... (MAX_ELEMENTS - 1)] = -1}; | 71 | s8 physnode_map[MAX_ELEMENTS] __read_mostly = { [0 ... (MAX_ELEMENTS - 1)] = -1}; |
72 | EXPORT_SYMBOL(physnode_map); | 72 | EXPORT_SYMBOL(physnode_map); |
@@ -81,9 +81,9 @@ void memory_present(int nid, unsigned long start, unsigned long end) | |||
81 | printk(KERN_DEBUG " "); | 81 | printk(KERN_DEBUG " "); |
82 | for (pfn = start; pfn < end; pfn += PAGES_PER_ELEMENT) { | 82 | for (pfn = start; pfn < end; pfn += PAGES_PER_ELEMENT) { |
83 | physnode_map[pfn / PAGES_PER_ELEMENT] = nid; | 83 | physnode_map[pfn / PAGES_PER_ELEMENT] = nid; |
84 | printk("%ld ", pfn); | 84 | printk(KERN_CONT "%ld ", pfn); |
85 | } | 85 | } |
86 | printk("\n"); | 86 | printk(KERN_CONT "\n"); |
87 | } | 87 | } |
88 | 88 | ||
89 | unsigned long node_memmap_size_bytes(int nid, unsigned long start_pfn, | 89 | unsigned long node_memmap_size_bytes(int nid, unsigned long start_pfn, |