[PATCH 02/22] alpha/cpu: Make sure arch_cpu_idle_dead() doesn't return
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: linux-kernel@xxxxxxxxxxxxxxx
- Subject: [PATCH 02/22] alpha/cpu: Make sure arch_cpu_idle_dead() doesn't return
- From: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>
- Date: Fri, 3 Feb 2023 14:05:11 -0800
- Cc: jgross@xxxxxxxx, richard.henderson@xxxxxxxxxx, ink@xxxxxxxxxxxxxxxxxxxx, mattst88@xxxxxxxxx, linux-alpha@xxxxxxxxxxxxxxx, linux@xxxxxxxxxxxxxxx, linux-arm-kernel@xxxxxxxxxxxxxxxxxxx, catalin.marinas@xxxxxxx, will@xxxxxxxxxx, guoren@xxxxxxxxxx, linux-csky@xxxxxxxxxxxxxxx, linux-ia64@xxxxxxxxxxxxxxx, chenhuacai@xxxxxxxxxx, kernel@xxxxxxxxxx, loongarch@xxxxxxxxxxxxxxx, f.fainelli@xxxxxxxxx, bcm-kernel-feedback-list@xxxxxxxxxxxx, tsbogend@xxxxxxxxxxxxxxxx, linux-mips@xxxxxxxxxxxxxxx, jiaxun.yang@xxxxxxxxxxx, mpe@xxxxxxxxxxxxxx, npiggin@xxxxxxxxx, christophe.leroy@xxxxxxxxxx, linuxppc-dev@xxxxxxxxxxxxxxxx, ysato@xxxxxxxxxxxxx, dalias@xxxxxxxx, linux-sh@xxxxxxxxxxxxxxx, davem@xxxxxxxxxxxxx, sparclinux@xxxxxxxxxxxxxxx, tglx@xxxxxxxxxxxxx, mingo@xxxxxxxxxx, bp@xxxxxxxxx, dave.hansen@xxxxxxxxxxxxxxx, x86@xxxxxxxxxx, hpa@xxxxxxxxx, chris@xxxxxxxxxx, jcmvbkbc@xxxxxxxxx, linux-xtensa@xxxxxxxxxxxxxxxx, peterz@xxxxxxxxxxxxx, juri.lelli@xxxxxxxxxx, vincent.guittot@xxxxxxxxxx, dietmar.eggemann@xxxxxxx, rostedt@xxxxxxxxxxx, bsegall@xxxxxxxxxx, mgorman@xxxxxxx, bristot@xxxxxxxxxx, vschneid@xxxxxxxxxx, paulmck@xxxxxxxxxx
- In-reply-to: <cover.1675461757.git.jpoimboe@kernel.org>
- References: <cover.1675461757.git.jpoimboe@kernel.org>
arch_cpu_idle_dead() doesn't return. Make that more explicit with a
BUG().
BUG() is preferable to unreachable() because BUG() is a more explicit
failure mode and avoids undefined behavior like falling off the edge of
the function into whatever code happens to be next.
Signed-off-by: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>
---
arch/alpha/kernel/process.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/alpha/kernel/process.c b/arch/alpha/kernel/process.c
index 4813172547b5..94938f856545 100644
--- a/arch/alpha/kernel/process.c
+++ b/arch/alpha/kernel/process.c
@@ -63,6 +63,7 @@ void arch_cpu_idle(void)
void arch_cpu_idle_dead(void)
{
wtint(INT_MAX);
+ BUG();
}
#endif /* ALPHA_WTINT */
--
2.39.0
[Index of Archives]
[Linux Kernel]
[Sparc Linux]
[DCCP]
[Linux ARM]
[Yosemite News]
[Linux SCSI]
[Linux x86_64]
[Linux for Ham Radio]