Added explanation of SIGKILL, REBOOT order.
This commit is contained in:
parent
5333d4f4e4
commit
629453fba8
@ -172,6 +172,11 @@ PUBLIC int do_reboot()
|
|||||||
return(EINVAL);
|
return(EINVAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Order matters here. When FS is told to reboot, it exits all its
|
||||||
|
* processes, and then would be confused if they're exited again by
|
||||||
|
* SIGKILL. So first kill, then reboot.
|
||||||
|
*/
|
||||||
|
|
||||||
check_sig(-1, SIGKILL); /* kill all processes except init */
|
check_sig(-1, SIGKILL); /* kill all processes except init */
|
||||||
tell_fs(REBOOT, 0, 0, 0); /* tell FS to synchronize */
|
tell_fs(REBOOT, 0, 0, 0); /* tell FS to synchronize */
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user