]> Gentwo Git Trees - linux/.git/commit
s390/smp: Mark pcpu_delegate() and smp_call_ipl_cpu() as __noreturn
authorThorsten Blum <thorsten.blum@linux.dev>
Thu, 30 Oct 2025 13:42:41 +0000 (14:42 +0100)
committerHeiko Carstens <hca@linux.ibm.com>
Thu, 6 Nov 2025 13:17:28 +0000 (14:17 +0100)
commiteb3a9b405b85e872d6f3dac427b7faa01e7e724e
tree00b3d152c3c63c7b3d9f8d6061b819eba3423dbe
parentf07ebfa5e48c59c41aea247982184fe956cbb756
s390/smp: Mark pcpu_delegate() and smp_call_ipl_cpu() as __noreturn

pcpu_delegate() never returns to its caller. If the target CPU is the
current CPU, it calls __pcpu_delegate(), whose delegate function is not
supposed to return. In any case, even if __pcpu_delegate() unexpectedly
returns, pcpu_delegate() sends SIGP_STOP to the current CPU and waits
in an infinite loop. Annotate pcpu_delegate() with the __noreturn
attribute to improve compiler optimizations.

Also annotate smp_call_ipl_cpu() accordingly since it always calls
pcpu_delegate().

[hca: Merge two patches from Thorsten Blum]

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/include/asm/smp.h
arch/s390/kernel/smp.c