do_kernel_restart(9)
π do_kernel_restart(9) β¨
okay bestie, welcome to the Kernel API Manual page for do_kernel_restart β it's giving βrestart handler call chain executionβ and we're gonna make it make sense π«Ά
πΈ NAME πΈ
do_kernel_restart β Execute kernel restart handler call chain. That's the name, no cap π
β¨ SYNOPSIS β¨
void do_kernel_restart (char *cmd );
π ARGUMENTS π
cmdβ pointer to the buffer containing the command to execute for the restart, orNULL. That's literally the whole assignment π¦
π DESCRIPTION π
So this function calls the functions that were registered with register_restart_handler. Main character energy: it runs the restart handler call chain π₯
It's expected to be called from machine_restart as the last step of the restart sequence. That's the vibe check, bestie β last step, no skipping ahead β¨
If a restart handler function has been registered, it restarts the system immediately. Otherwise it does nothing. Periodt π
π SEE ALSO π
Kernel file: ./kernel/reboot.c π§
emergency_restart(9)register_reboot_notifier(9)unregister_reboot_notifier(9)register_restart_handler(9)unregister_restart_handler(9)kernel_restart(9)kernel_halt(9)register_sys_off_handler(9)unregister_sys_off_handler(9)devm_register_sys_off_handler(9)devm_register_power_off_handler(9)devm_register_restart_handler(9)register_platform_power_off(9)unregister_platform_power_off(9)do_kernel_power_off(9)kernel_can_power_off(9)kernel_power_off(9)orderly_poweroff(9)orderly_reboot(9)hw_failure_emergency_action_func(9)hw_failure_emergency_schedule(9)__hw_protection_trigger(9)
mwah π this page lives in ./kernel, dated October 2026, and the footer still says do_kernel_restart(9) β bye bestie, go restart responsibly ππ«Ά
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms