x86/reboot: Add call to do_kernel_restart()
PATCH 1/1 x86/reboot: Add call to do_kernel_restart()
SoC devices like the Intel / MaxLinear Lightning Mountain must be reset by the RCU instead of using "normal" x86 mechanisms like ACPI, BIOS, KBD, etc.
Therefore, the RCU driver (reset-intel-gw) registers a restart handler which triggers the global reset signal.
Unfortunately, this is of no use as long as the restart chain is not processed during reboot on x86 systems.
So we must call do_kernel_restart() when a reboot is performed. This has long been common practice for other architectures.
--- arch/x86/kernel/reboot.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
arch/x86/kernel/reboot.c +4 -1
@@ -773,12 +773,15 @@ static void __machine_emergency_restart(int emergency) machine_ops.emergency_restart (); } -static void native_machine_restart (char *__unused) +static void native_machine_restart (char *command) {pr_notice ("machine restart\n" );if (!reboot_force)machine_shutdown (); + +do_kernel_restart (command); +__machine_emergency_restart (0 ); }
---
base-commit: 05f7e89ab9731565d8a62e3b5d1ec206485eeb0b
change-id: 20260220-x86_do_kernel_restart-ac125c71c5c3
Best regards,
Signature · 1 line
Martin Schiller <[email protected]>
Borislav Petkov
maintainerQuoted 2 lines · Martin Schiller
SoC devices like the Intel / MaxLinear Lightning Mountain must be reset by the RCU instead of using "normal" x86 mechanisms like ACPI, BIOS,
Read-Copy-Update?
I'm relatively sure you don't mean that.
Quoted 9 lines
KBD, etc.
Therefore, the RCU driver (reset-intel-gw) registers a restart handler which triggers the global reset signal.
Unfortunately, this is of no use as long as the restart chain is not processed during reboot on x86 systems.
So we must call
do_kernel_restart()when a reboot is performed. This has
Who's "we"?
Quoted 14 lines
long been common practice for other architectures.
Signed-off-by Martin Schiller <[email protected]>--- arch/x86/kernel/reboot.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)arch/x86/kernel/reboot.c +0
-0@@ -773,12 +773,15 @@ static void __machine_emergency_restart(int emergency) machine_ops.emergency_restart (); }
arch/x86/kernel/reboot.c static void __machine_emergency_restart(int emergency) · line 783
Quoted 10 lines
arch/x86/kernel/reboot.c +3
-1-static void native_machine_restart (char *__unused) +static void native_machine_restart (char *command) {pr_notice ("machine restart\n" );if (!reboot_force)machine_shutdown (); + +do_kernel_restart (command);
I guess we can do that - the other arches do it already...
Signature · 4 lines
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquetteQuoted 5 lines · Borislav Petkov
Quoted 2 lines · Martin Schiller
SoC devices like the Intel / MaxLinear Lightning Mountain must be reset by the RCU instead of using "normal" x86 mechanisms like ACPI, BIOS,
Read-Copy-Update?
Sorry, I forgot to explain the abbreviation.
RCU is short for Reset Control Unit. That's what it's called in the Intel / MaxLinear world.
Quoted 8 lines
I'm relatively sure you don't mean that.
Quoted 5 lines
KBD, etc.
Therefore, the RCU driver (reset-intel-gw) registers a restart handler which triggers the global reset signal.
Quoted 6 lines
Quoted 4 lines
Unfortunately, this is of no use as long as the restart chain is not processed during reboot on x86 systems.
So we must call
do_kernel_restart()when a reboot is performed. This hasWho's "we"?
I don't mean anyone in particular. I just wanted to express that the function must be called.
Quoted 28 lines
Quoted 16 lines
long been common practice for other architectures.
Signed-off-by Martin Schiller <[email protected]>--- arch/x86/kernel/reboot.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)arch/x86/kernel/reboot.c +0
-0@@ -773,12 +773,15 @@ static void __machine_emergency_restart(int emergency) machine_ops.emergency_restart(); }arch/x86/kernel/reboot.c static void __machine_emergency_restart(int · line 784
Quoted 10 lines
arch/x86/kernel/reboot.c +3
-1-static void native_machine_restart (char *__unused) +static void native_machine_restart (char *command) {pr_notice ("machine restart\n" );if (!reboot_force)machine_shutdown (); + +do_kernel_restart (command);I guess we can do that - the other arches do it already...
Borislav Petkov
maintainerQuoted 3 lines · Martin Schiller
I don't mean anyone in particular. I just wanted to express that the function must be called.
Then please correct your commit message to not have ambiguous pronouns but rather use passive voice, concentrating solely on the need for the change.
Thx.
Signature · 1 line
Small device. Typos and formatting crap