FreeBSD/sys/kern/kern_shutdown.c
/*
 * Called by events that want to shut down.. e.g  <CTL><ALT><DEL> on a PC
 */
Called by events that want to shut down..
Called by events that want to shut down ..
void
shutdown_nice(int howto)
{
	if (initproc != NULL) {
		PROC_LOCK(initproc);
		if (howto & RB_POWEROFF)
			kern_psignal(initproc, SIGUSR2);
		else if (howto & RB_HALT)
			kern_psignal(initproc, SIGUSR1);
		else
			kern_psignal(initproc, SIGINT);
		PROC_UNLOCK(initproc);
	} else {
		kern_reboot(howto | RB_NOSYNC);
	}
}
void shutdown_nice ( int howto ) { if ( initproc != NULL ) { PROC_LOCK ( initproc ) ; if ( howto & RB_POWEROFF ) kern_psignal ( initproc , SIGUSR2 ) ; else if ( howto & RB_HALT ) kern_psignal ( initproc , SIGUSR1 ) ; else kern_psignal ( initproc , SIGINT ) ; PROC_UNLOCK ( initproc ) ; } else { kern_reboot ( howto | RB_NOSYNC ) ; } }
Called by events that want to shut down.. e.g  <CTL><ALT><DEL> on a PC
Called by events that want to shut down .. e . g <CTL > <ALT > <DEL > on a PC
/* Send a signal to init(8) and have it shutdown the world. */ /* No init(8) running, so simply reboot. */