aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-ppc/smp.h
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2005-09-10 07:13:13 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-10 13:15:11 -0400
commit31139971b3dc9fbb2e8a8572fb81e6e8470f363a (patch)
tree644fc6833fe6e18d00dbc8b6b281f77e7b923d35 /include/asm-ppc/smp.h
parentbb0bb3b6596cdb08adb0b72453cc67d48e139c2c (diff)
[PATCH] ppc32: support hotplug cpu on powermacs
This allows cpus to be off-lined on 32-bit SMP powermacs. When a cpu is off-lined, it is put into sleep mode with interrupts disabled. It can be on-lined again by asserting its soft-reset pin, which is connected to a GPIO pin. With this I can off-line the second cpu in my dual G4 powermac, which means that I can then suspend the machine (the suspend/resume code refuses to suspend if more than one cpu is online, and making it cope with multiple cpus is surprisingly messy). Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/asm-ppc/smp.h')
-rw-r--r--include/asm-ppc/smp.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/asm-ppc/smp.h b/include/asm-ppc/smp.h
index 17530c232c76..829481c0a9dc 100644
--- a/include/asm-ppc/smp.h
+++ b/include/asm-ppc/smp.h
@@ -41,6 +41,10 @@ extern void smp_send_xmon_break(int cpu);
41struct pt_regs; 41struct pt_regs;
42extern void smp_message_recv(int, struct pt_regs *); 42extern void smp_message_recv(int, struct pt_regs *);
43 43
44extern int __cpu_disable(void);
45extern void __cpu_die(unsigned int cpu);
46extern void cpu_die(void) __attribute__((noreturn));
47
44#define NO_PROC_ID 0xFF /* No processor magic marker */ 48#define NO_PROC_ID 0xFF /* No processor magic marker */
45#define PROC_CHANGE_PENALTY 20 49#define PROC_CHANGE_PENALTY 20
46 50
@@ -64,6 +68,8 @@ extern struct klock_info_struct klock_info;
64 68
65#else /* !(CONFIG_SMP) */ 69#else /* !(CONFIG_SMP) */
66 70
71static inline void cpu_die(void) { }
72
67#endif /* !(CONFIG_SMP) */ 73#endif /* !(CONFIG_SMP) */
68 74
69#endif /* !(_PPC_SMP_H) */ 75#endif /* !(_PPC_SMP_H) */