]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
x86 numa: don't check if node is NUMA_NO_NODE
authorWen Congyang <wency@cn.fujitsu.com>
Fri, 28 Sep 2012 00:18:51 +0000 (10:18 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 3 Oct 2012 06:46:36 +0000 (16:46 +1000)
If we aren't debugging per_cpu maps, the cpu's node is stored in per_cpu
variable numa_node.  If `node' is NUMA_NO_NODE, it means the caller wants
to clear the cpu's node.  So we should also call set_cpu_numa_node() in
this case.

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
Cc: Len Brown <len.brown@intel.com>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/x86/mm/numa.c

index 2d125be1bae9f2c229b835b8ea1421e685c38879..21d02f0d7a2c4a563722e0ecc266d4fb433029b1 100644 (file)
@@ -97,8 +97,7 @@ void __cpuinit numa_set_node(int cpu, int node)
 #endif
        per_cpu(x86_cpu_to_node_map, cpu) = node;
 
-       if (node != NUMA_NO_NODE)
-               set_cpu_numa_node(cpu, node);
+       set_cpu_numa_node(cpu, node);
 }
 
 void __cpuinit numa_clear_node(int cpu)