diff options
author | Paul Mundt <lethal@linux-sh.org> | 2007-06-01 01:21:13 -0400 |
---|---|---|
committer | Paul Mundt <lethal@hera.kernel.org> | 2007-06-07 22:43:45 -0400 |
commit | d22d9b3a1d129349518c807e7997922f869e1f48 (patch) | |
tree | 2ca207bdf654450972f29dd03ca61ce69b58d3e5 /arch/sh/kernel/topology.c | |
parent | 91e656aacf52bcd3fbd199462032efec915fb654 (diff) |
sh: Register multiple nodes in topology_init().
If we have multiple nodes, register these at topology_init() time.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/kernel/topology.c')
-rw-r--r-- | arch/sh/kernel/topology.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/sh/kernel/topology.c b/arch/sh/kernel/topology.c index 8a4664c0ab57..9687b02caf4b 100644 --- a/arch/sh/kernel/topology.c +++ b/arch/sh/kernel/topology.c | |||
@@ -2,6 +2,8 @@ | |||
2 | #include <linux/cpumask.h> | 2 | #include <linux/cpumask.h> |
3 | #include <linux/init.h> | 3 | #include <linux/init.h> |
4 | #include <linux/percpu.h> | 4 | #include <linux/percpu.h> |
5 | #include <linux/node.h> | ||
6 | #include <linux/nodemask.h> | ||
5 | 7 | ||
6 | static DEFINE_PER_CPU(struct cpu, cpu_devices); | 8 | static DEFINE_PER_CPU(struct cpu, cpu_devices); |
7 | 9 | ||
@@ -9,6 +11,11 @@ static int __init topology_init(void) | |||
9 | { | 11 | { |
10 | int i, ret; | 12 | int i, ret; |
11 | 13 | ||
14 | #ifdef CONFIG_NEED_MULTIPLE_NODES | ||
15 | for_each_online_node(i) | ||
16 | register_one_node(i); | ||
17 | #endif | ||
18 | |||
12 | for_each_present_cpu(i) { | 19 | for_each_present_cpu(i) { |
13 | ret = register_cpu(&per_cpu(cpu_devices, i), i); | 20 | ret = register_cpu(&per_cpu(cpu_devices, i), i); |
14 | if (unlikely(ret)) | 21 | if (unlikely(ret)) |