s390/kdump: Mark __do_machine_kexec as __noreturn
PATCH v2 1/3 s390/kdump: Mark __do_machine_kexec as __noreturn
__do_machine_kexec() ends by calling the non-returning function disabled_wait() and therefore also never returns. Annotate it with the __noreturn attribute to improve compiler optimizations.
---
Changes in v2:
- Drop the first two patches from the series because store_status() does return to the caller (Heiko)
- Link to v1: https://lore.kernel.org/lkml/[email protected]/
--- arch/s390/kernel/machine_kexec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/s390/kernel/machine_kexec.c +1 -1
@@ -224,7 +224,7 @@ void machine_crash_shutdown(struct pt_regs *regs)/* * Do normal kexec */ -static void __do_machine_kexec (void *data) +static void __noreturn __do_machine_kexec (void *data) {unsigned long data_mover, entry, diag308_subcode;struct kimage *image = data;
Signature · 1 line
2.51.1
PATCH v2 2/3 s390/kdump: Mark __machine_kexec as __noreturn
__machine_kexec() ends by calling the non-returning function __do_machine_kexec() and therefore also never returns. Annotate it with the __noreturn attribute to improve compiler optimizations.
--- arch/s390/kernel/machine_kexec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/s390/kernel/machine_kexec.c +1 -1
@@ -248,7 +248,7 @@ static void __noreturn __do_machine_kexec(void *data)/* * Reset system and call either kdump or normal kexec */ -static void __machine_kexec (void *data) +static void __noreturn __machine_kexec (void *data) {pfault_fini ();tracing_off ();
Signature · 1 line
2.51.1
PATCH v2 3/3 s390/kdump: Mark __do_machine_kdump as __noreturn
In reply to Thorsten Blum__do_machine_kdump() ends by calling the non-returning function disabled_wait() and therefore also never returns. Annotate it with the __noreturn attribute to improve compiler optimizations.
--- arch/s390/kernel/machine_kexec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/s390/kernel/machine_kexec.c +1 -1
@@ -45,7 +45,7 @@ extern const unsigned long long relocate_kernel_len;* Reset the system, copy boot CPU registers to absolute zero, * and jump to the kdump image */ -static void __do_machine_kdump (void *data) +static void __noreturn __do_machine_kdump (void *data) {struct kimage *image = data;purgatory_t purgatory;
Signature · 1 line
2.51.1