summaryrefslogtreecommitdiff
path: root/arch/x86/mm/srat_32.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2011-05-02 12:18:52 (GMT)
committerTejun Heo <tj@kernel.org>2011-05-02 12:18:52 (GMT)
commit797390d8554b1e07aabea37d0140933b0412dba0 (patch)
tree81ec97a19bcd03de733a73fea8c88a84b64044ad /arch/x86/mm/srat_32.c
parent84914ed0ec6787d38e84b510f92ad4ca3a572fd8 (diff)
downloadlinux-fsl-qoriq-797390d8554b1e07aabea37d0140933b0412dba0.tar.xz
x86-32, NUMA: use sparse_memory_present_with_active_regions()
Instead of calling memory_present() for each region from NUMA init, call sparse_memory_present_with_active_regions() from paging_init() similarly to x86-64. For flat and numaq, this results in exactly the same memory_present() calls. For srat, if there are multiple memory chunks for a node, after this change, memory_present() will be called separately for each chunk instead of being called once to encompass the whole range, which doesn't cause any harm and actually is the better behavior. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Yinghai Lu <yinghai@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: "H. Peter Anvin" <hpa@zytor.com>
Diffstat (limited to 'arch/x86/mm/srat_32.c')
-rw-r--r--arch/x86/mm/srat_32.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/arch/x86/mm/srat_32.c b/arch/x86/mm/srat_32.c
index ae20046..6b9bfd7 100644
--- a/arch/x86/mm/srat_32.c
+++ b/arch/x86/mm/srat_32.c
@@ -209,7 +209,7 @@ static __init int node_read_chunk(int nid, struct node_memory_chunk_s *memory_ch
int __init get_memcfg_from_srat(void)
{
- int i, j, nid;
+ int i, j;
if (srat_disabled())
goto out_fail;
@@ -273,12 +273,6 @@ int __init get_memcfg_from_srat(void)
/* for out of order entries in SRAT */
sort_node_map();
- for_each_online_node(nid) {
- unsigned long start = node_start_pfn[nid];
- unsigned long end = min(node_end_pfn[nid], max_pfn);
-
- memory_present(nid, start, end);
- }
return 1;
out_fail:
printk(KERN_DEBUG "failed to get NUMA memory information from SRAT"