diff options
Diffstat (limited to 'arch/powerpc/kernel/smp.c')
-rw-r--r-- | arch/powerpc/kernel/smp.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c index 87517ab6d365..b74411446922 100644 --- a/arch/powerpc/kernel/smp.c +++ b/arch/powerpc/kernel/smp.c | |||
@@ -218,11 +218,18 @@ void arch_send_call_function_ipi_mask(const struct cpumask *mask) | |||
218 | smp_ops->message_pass(cpu, PPC_MSG_CALL_FUNCTION); | 218 | smp_ops->message_pass(cpu, PPC_MSG_CALL_FUNCTION); |
219 | } | 219 | } |
220 | 220 | ||
221 | #ifdef CONFIG_DEBUGGER | 221 | #if defined(CONFIG_DEBUGGER) || defined(CONFIG_KEXEC) |
222 | void smp_send_debugger_break(int cpu) | 222 | void smp_send_debugger_break(void) |
223 | { | 223 | { |
224 | if (likely(smp_ops)) | 224 | int cpu; |
225 | smp_ops->message_pass(cpu, PPC_MSG_DEBUGGER_BREAK); | 225 | int me = raw_smp_processor_id(); |
226 | |||
227 | if (unlikely(!smp_ops)) | ||
228 | return; | ||
229 | |||
230 | for_each_online_cpu(cpu) | ||
231 | if (cpu != me) | ||
232 | smp_ops->message_pass(cpu, PPC_MSG_DEBUGGER_BREAK); | ||
226 | } | 233 | } |
227 | #endif | 234 | #endif |
228 | 235 | ||
@@ -230,9 +237,9 @@ void smp_send_debugger_break(int cpu) | |||
230 | void crash_send_ipi(void (*crash_ipi_callback)(struct pt_regs *)) | 237 | void crash_send_ipi(void (*crash_ipi_callback)(struct pt_regs *)) |
231 | { | 238 | { |
232 | crash_ipi_function_ptr = crash_ipi_callback; | 239 | crash_ipi_function_ptr = crash_ipi_callback; |
233 | if (crash_ipi_callback && smp_ops) { | 240 | if (crash_ipi_callback) { |
234 | mb(); | 241 | mb(); |
235 | smp_ops->message_pass(MSG_ALL_BUT_SELF, PPC_MSG_DEBUGGER_BREAK); | 242 | smp_send_debugger_break(); |
236 | } | 243 | } |
237 | } | 244 | } |
238 | #endif | 245 | #endif |