powerpc: Move definitions of secondary CPU spinloop to header file
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 23 Jul 2009 23:15:28 +0000 (23:15 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 20 Aug 2009 00:12:44 +0000 (10:12 +1000)
Those definitions are currently declared extern in the .c file where
they are used, move them to a header file instead.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/include/asm/smp.h
arch/powerpc/kernel/prom_init.c
arch/powerpc/kernel/setup_64.c
arch/powerpc/platforms/85xx/smp.c
arch/powerpc/platforms/86xx/mpc86xx_smp.c
arch/powerpc/platforms/cell/smp.c
arch/powerpc/platforms/pseries/smp.c

index c25f73d1d84203e0393d26d5da07e390c79417e5..e782f43ee669c904ccb4b0a0cbd71faf46723379 100644 (file)
@@ -148,6 +148,15 @@ extern struct smp_ops_t *smp_ops;
 extern void arch_send_call_function_single_ipi(int cpu);
 extern void arch_send_call_function_ipi(cpumask_t mask);
 
+/* Definitions relative to the secondary CPU spin loop
+ * and entry point. Not all of them exist on both 32 and
+ * 64-bit but defining them all here doesn't harm
+ */
+extern void generic_secondary_smp_init(void);
+extern unsigned long __secondary_hold_spinloop;
+extern unsigned long __secondary_hold_acknowledge;
+extern char __secondary_hold;
+
 #endif /* __ASSEMBLY__ */
 
 #endif /* __KERNEL__ */
index a538824616fd736e20978bb822e09b98f2432263..d942404779c1d2d871cd7024ae045e4448a2aa44 100644 (file)
@@ -1259,10 +1259,6 @@ static void __init prom_initialize_tce_table(void)
  *
  * -- Cort
  */
-extern char __secondary_hold;
-extern unsigned long __secondary_hold_spinloop;
-extern unsigned long __secondary_hold_acknowledge;
-
 /*
  * We want to reference the copy of __secondary_hold_* in the
  * 0 - 0x100 address range
index 325dc5b2e62649eb616cca0919217e7072cffb84..a6b6c4c9ae419b3afd7f0b1f37d00b0733273b67 100644 (file)
@@ -230,9 +230,6 @@ void early_setup_secondary(void)
 #endif /* CONFIG_SMP */
 
 #if defined(CONFIG_SMP) || defined(CONFIG_KEXEC)
-extern unsigned long __secondary_hold_spinloop;
-extern void generic_secondary_smp_init(void);
-
 void smp_release_cpus(void)
 {
        unsigned long *ptr;
index 62c592ede641c4a374a7760fd67604cfc9b2f9de..9f526ba31c1e731f6525760870e0e1d75035df51 100644 (file)
@@ -25,7 +25,6 @@
 
 #include <sysdev/fsl_soc.h>
 
-extern volatile unsigned long __secondary_hold_acknowledge;
 extern void __early_start(void);
 
 #define BOOT_ENTRY_ADDR_UPPER  0
index d84bbb508ee7650719857bd6aaf1ee6c2f7ecee8..eacea0e3fcc88b5d42f13bed9e75ca4b589f2db0 100644 (file)
@@ -27,7 +27,6 @@
 #include "mpc86xx.h"
 
 extern void __secondary_start_mpc86xx(void);
-extern unsigned long __secondary_hold_acknowledge;
 
 #define MCM_PORT_CONFIG_OFFSET 0x10
 
index bc97fada48c664662ee59808c9f6424820d42f6a..f774530075b749122424549c2c4009a32737cd0f 100644 (file)
@@ -58,8 +58,6 @@
  */
 static cpumask_t of_spin_map;
 
-extern void generic_secondary_smp_init(unsigned long);
-
 /**
  * smp_startup_cpu() - start the given cpu
  *
index 1f8f6cfb94f7f504b4f44f025fc02b600b392000..440000cc71307ac83df8ac251af13085c910aec6 100644 (file)
@@ -56,8 +56,6 @@
  */
 static cpumask_t of_spin_map;
 
-extern void generic_secondary_smp_init(unsigned long);
-
 /**
  * smp_startup_cpu() - start the given cpu
  *