summaryrefslogtreecommitdiff
path: root/arch/x86/mm/amdtopology_64.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2011-02-16 19:11:09 +0300
committerTejun Heo <tj@kernel.org>2011-02-16 19:11:09 +0300
commita844ef46fa3055165c28feede6114a711b8375ad (patch)
treefcbe0deaa1d743bef8ebeed4d37b7089a561d91b /arch/x86/mm/amdtopology_64.c
parent56e827fbde9a3cb886a2fe138db0d99e98efbfb1 (diff)
downloadlinux-a844ef46fa3055165c28feede6114a711b8375ad.tar.xz
x86-64, NUMA: Add common find_node_by_addr()
srat_64.c and amdtopology_64.c had their own versions of find_node_by_addr() which were basically the same. Add common one in numa_64.c and remove the duplicates. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Yinghai Lu <yinghai@kernel.org> Cc: Brian Gerst <brgerst@gmail.com> Cc: Cyrill Gorcunov <gorcunov@gmail.com> Cc: Shaohui Zheng <shaohui.zheng@intel.com> Cc: David Rientjes <rientjes@google.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'arch/x86/mm/amdtopology_64.c')
-rw-r--r--arch/x86/mm/amdtopology_64.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/arch/x86/mm/amdtopology_64.c b/arch/x86/mm/amdtopology_64.c
index 90cf297b3b59..8f7a5eb4bd3c 100644
--- a/arch/x86/mm/amdtopology_64.c
+++ b/arch/x86/mm/amdtopology_64.c
@@ -205,19 +205,6 @@ static s16 fake_apicid_to_node[MAX_LOCAL_APIC] __initdata = {
[0 ... MAX_LOCAL_APIC-1] = NUMA_NO_NODE
};
-static int __init find_node_by_addr(unsigned long addr)
-{
- int ret = NUMA_NO_NODE;
- int i;
-
- for (i = 0; i < 8; i++)
- if (addr >= numa_nodes[i].start && addr < numa_nodes[i].end) {
- ret = i;
- break;
- }
- return ret;
-}
-
/*
* For NUMA emulation, fake proximity domain (_PXM) to node id mappings must be
* setup to represent the physical topology but reflect the emulated