diff options
Diffstat (limited to 'kernel/panic.c')
-rw-r--r-- | kernel/panic.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/kernel/panic.c b/kernel/panic.c index 535c96510a44..8aa74497cc5a 100644 --- a/kernel/panic.c +++ b/kernel/panic.c | |||
@@ -160,8 +160,10 @@ void panic(const char *fmt, ...) | |||
160 | * | 160 | * |
161 | * Bypass the panic_cpu check and call __crash_kexec directly. | 161 | * Bypass the panic_cpu check and call __crash_kexec directly. |
162 | */ | 162 | */ |
163 | if (!crash_kexec_post_notifiers) | 163 | if (!crash_kexec_post_notifiers) { |
164 | printk_nmi_flush_on_panic(); | ||
164 | __crash_kexec(NULL); | 165 | __crash_kexec(NULL); |
166 | } | ||
165 | 167 | ||
166 | /* | 168 | /* |
167 | * Note smp_send_stop is the usual smp shutdown function, which | 169 | * Note smp_send_stop is the usual smp shutdown function, which |
@@ -176,6 +178,8 @@ void panic(const char *fmt, ...) | |||
176 | */ | 178 | */ |
177 | atomic_notifier_call_chain(&panic_notifier_list, 0, buf); | 179 | atomic_notifier_call_chain(&panic_notifier_list, 0, buf); |
178 | 180 | ||
181 | /* Call flush even twice. It tries harder with a single online CPU */ | ||
182 | printk_nmi_flush_on_panic(); | ||
179 | kmsg_dump(KMSG_DUMP_PANIC); | 183 | kmsg_dump(KMSG_DUMP_PANIC); |
180 | 184 | ||
181 | /* | 185 | /* |