]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
numa, cpumask: move numa_node_id default implementation to topology.h
authorRusty Russell <rusty@rustcorp.com.au>
Fri, 13 Mar 2009 13:13:37 +0000 (23:43 +1030)
committerIngo Molnar <mingo@elte.hu>
Fri, 13 Mar 2009 13:35:31 +0000 (14:35 +0100)
Impact: cleanup, potential bugfix

Not sure what changed to expose this, but clearly that numa_node_id()
doesn't belong in mmzone.h (the inline in gfp.h is probably overkill, too).

In file included from include/linux/topology.h:34,
                 from arch/x86/mm/numa.c:2:
/home/rusty/patches-cpumask/linux-2.6/arch/x86/include/asm/topology.h:64:1: warning: "numa_node_id" redefined
In file included from include/linux/topology.h:32,
                 from arch/x86/mm/numa.c:2:
include/linux/mmzone.h:770:1: warning: this is the location of the previous definition

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Cc: Mike Travis <travis@sgi.com>
LKML-Reference: <200903132343.37661.rusty@rustcorp.com.au>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
include/linux/gfp.h
include/linux/mmzone.h
include/linux/topology.h

index dd20cd78faa8f89db0b060ff13324ef762b580dd..0bbc15f5453642e2c5057028322b29738cbf8a47 100644 (file)
@@ -4,6 +4,7 @@
 #include <linux/mmzone.h>
 #include <linux/stddef.h>
 #include <linux/linkage.h>
+#include <linux/topology.h>
 
 struct vm_area_struct;
 
index 1aca6cebbb78916aaeb4764b3ec7e7da3276cf91..e6aacf77986a5026a8f5f05aff4cdadc8a6f06e3 100644 (file)
@@ -764,12 +764,6 @@ extern int numa_zonelist_order_handler(struct ctl_table *, int,
 extern char numa_zonelist_order[];
 #define NUMA_ZONELIST_ORDER_LEN 16     /* string buffer size */
 
-#include <linux/topology.h>
-/* Returns the number of the current Node. */
-#ifndef numa_node_id
-#define numa_node_id()         (cpu_to_node(raw_smp_processor_id()))
-#endif
-
 #ifndef CONFIG_NEED_MULTIPLE_NODES
 
 extern struct pglist_data contig_page_data;
index 16b7d6896ce9da8c17051bfc8e33cb94e976960e..7402c1a27c4f5149e1fe71c02356a909ec99ccc0 100644 (file)
@@ -196,4 +196,9 @@ int arch_update_cpu_topology(void);
 #define topology_core_cpumask(cpu)             cpumask_of(cpu)
 #endif
 
+/* Returns the number of the current Node. */
+#ifndef numa_node_id
+#define numa_node_id()         (cpu_to_node(raw_smp_processor_id()))
+#endif
+
 #endif /* _LINUX_TOPOLOGY_H */