]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
x86/mm/numa: use setup_nr_node_ids() instead of opencoding.
authorCody P Schafer <cody@linux.vnet.ibm.com>
Tue, 26 Mar 2013 23:24:46 +0000 (10:24 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 2 Apr 2013 07:29:13 +0000 (18:29 +1100)
Signed-off-by: Cody P Schafer <cody@linux.vnet.ibm.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/x86/mm/numa.c

index 72fe01e9e4144ac6293c3aa74c1196e864797193..a71c4e207679abf96c7b45747d84e6e7bac19bb0 100644 (file)
@@ -114,14 +114,11 @@ void numa_clear_node(int cpu)
  */
 void __init setup_node_to_cpumask_map(void)
 {
-       unsigned int node, num = 0;
+       unsigned int node;
 
        /* setup nr_node_ids if not done yet */
-       if (nr_node_ids == MAX_NUMNODES) {
-               for_each_node_mask(node, node_possible_map)
-                       num = node;
-               nr_node_ids = num + 1;
-       }
+       if (nr_node_ids == MAX_NUMNODES)
+               setup_nr_node_ids();
 
        /* allocate the map */
        for (node = 0; node < nr_node_ids; node++)