diff options
| author | Bradley Morgan <brads@mainlining.org> | 2026-09-16 18:29:53 +0000 |
|---|---|---|
| committer | Andrew Morton <akpm@linux-foundation.org> | 2026-10-06 19:03:09 -0700 |
| commit | 50ce3620bee380cd2e136803ff66cc8c997d6d7c (patch) | |
| tree | 76bf5e432f8b252c5047afaa82e84b5a79f10836 /kernel | |
| parent | c05e2c32cd322ee2899501feda5b746c14207c0e (diff) | |
| download | linux-next-50ce3620bee380cd2e136803ff66cc8c997d6d7c.tar.gz linux-next-50ce3620bee380cd2e136803ff66cc8c997d6d7c.zip | |
panic: flatten nmi_panic control flow
panic() is __noreturn, so the else after panic_try_start() is dead. Drop
it so the force_cpu path can be added cleanly on top.
Link: https://lore.kernel.org/20260916182957.7788-3-brads@mainlining.org
Signed-off-by: Bradley Morgan <brads@mainlining.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Cc: Guenetr Roeck <linux@roeck-us.net>
Cc: Sashiko <sashiko-bot@kernel.org>
Cc: Wang Jinchao <wangjinchao600@gmail.com>
Cc: Wim Van Sebroeck <wim@linux-watchdog.org>
Cc: <stable@vger.kernel.org>
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/panic.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/panic.c b/kernel/panic.c index 08072bfae422..5646d4fb82b7 100644 --- a/kernel/panic.c +++ b/kernel/panic.c @@ -517,7 +517,8 @@ void nmi_panic(struct pt_regs *regs, const char *msg) { if (panic_try_start()) panic("%s", msg); - else if (panic_on_other_cpu()) + + if (panic_on_other_cpu()) nmi_panic_self_stop(regs); } EXPORT_SYMBOL(nmi_panic); |
