summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2005-10-27 22:42:04 +1000
committerPaul Mackerras <paulus@samba.org>2005-10-27 22:42:04 +1000
commit80579e1f4a6b5f5dec92faa6c3e0645961c99091 (patch)
treed8fd5e184b54145811a92914c806544ad745087a /arch/powerpc/kernel
parenteef69e3cfb38d83166dbd8bcb12ededa1b6e78b6 (diff)
powerpc: 32-bit CHRP SMP fixes
Untested, but "should" work... at least this way it compiles. Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r--arch/powerpc/kernel/prom.c12
-rw-r--r--arch/powerpc/kernel/setup_32.c4
2 files changed, 10 insertions, 6 deletions
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index ab9b291dda5..6309a1a17c4 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -1110,22 +1110,22 @@ static int __init early_init_dt_scan_cpus(unsigned long node,
}
#endif
-#ifdef CONFIG_PPC64
+ boot_cpuid = 0;
+ boot_cpuid_phys = 0;
if (initial_boot_params && initial_boot_params->version >= 2) {
/* version 2 of the kexec param format adds the phys cpuid
* of booted proc.
*/
boot_cpuid_phys = initial_boot_params->boot_cpuid_phys;
- boot_cpuid = 0;
} else {
- /* Check if it's the boot-cpu, set it's hw index in paca now */
+ /* Check if it's the boot-cpu, set it's hw index now */
if (get_flat_dt_prop(node, "linux,boot-cpu", NULL) != NULL) {
prop = get_flat_dt_prop(node, "reg", NULL);
- set_hard_smp_processor_id(0, prop == NULL ? 0 : *prop);
- boot_cpuid_phys = get_hard_smp_processor_id(0);
+ if (prop != NULL)
+ boot_cpuid_phys = *prop;
}
}
-#endif
+ set_hard_smp_processor_id(0, boot_cpuid_phys);
#ifdef CONFIG_ALTIVEC
/* Check if we have a VMX and eventually update CPU features */
diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
index 150a919269a..7c99e6b8c76 100644
--- a/arch/powerpc/kernel/setup_32.c
+++ b/arch/powerpc/kernel/setup_32.c
@@ -59,6 +59,10 @@ struct ide_machdep_calls ppc_ide_md;
int __irq_offset_value;
EXPORT_SYMBOL(__irq_offset_value);
+int boot_cpuid;
+EXPORT_SYMBOL_GPL(boot_cpuid);
+int boot_cpuid_phys;
+
unsigned long ISA_DMA_THRESHOLD;
unsigned int DMA_MODE_READ;
unsigned int DMA_MODE_WRITE;