forked from luck/tmp_suning_uos_patched
[PATCH] powerpc numa: fix boot_cpuid always assigned to node 0
At boot, the numa code is assigning boot_cpuid to node 0 unconditionally. Basically, numa_setup_cpu is being stupid about it, but this is the minimal fix -- just call numa_setup_cpu(boot_cpuid) later, after all nodes have been set online. Signed-off-by: Nathan Lynch <nathanl@austin.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
This commit is contained in:
parent
1d7aac5b3b
commit
c08888cf3c
@ -375,7 +375,7 @@ static int __init parse_numa_properties(void)
|
|||||||
{
|
{
|
||||||
struct device_node *cpu = NULL;
|
struct device_node *cpu = NULL;
|
||||||
struct device_node *memory = NULL;
|
struct device_node *memory = NULL;
|
||||||
int max_domain;
|
int max_domain = 0;
|
||||||
unsigned long i;
|
unsigned long i;
|
||||||
|
|
||||||
if (numa_enabled == 0) {
|
if (numa_enabled == 0) {
|
||||||
@ -389,8 +389,6 @@ static int __init parse_numa_properties(void)
|
|||||||
if (min_common_depth < 0)
|
if (min_common_depth < 0)
|
||||||
return min_common_depth;
|
return min_common_depth;
|
||||||
|
|
||||||
max_domain = numa_setup_cpu(boot_cpuid);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Even though we connect cpus to numa domains later in SMP init,
|
* Even though we connect cpus to numa domains later in SMP init,
|
||||||
* we need to know the maximum node id now. This is because each
|
* we need to know the maximum node id now. This is because each
|
||||||
@ -469,6 +467,8 @@ static int __init parse_numa_properties(void)
|
|||||||
for (i = 0; i <= max_domain; i++)
|
for (i = 0; i <= max_domain; i++)
|
||||||
node_set_online(i);
|
node_set_online(i);
|
||||||
|
|
||||||
|
max_domain = numa_setup_cpu(boot_cpuid);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user