Merge "init: clarify some text/README about 'critical' services"
This commit is contained in:
commit
ce27a5bc0f
4 changed files with 4 additions and 4 deletions
|
|
@ -189,7 +189,7 @@ runs the service.
|
||||||
|
|
||||||
`critical`
|
`critical`
|
||||||
> This is a device-critical service. If it exits more than four times in
|
> This is a device-critical service. If it exits more than four times in
|
||||||
four minutes, the device will reboot into recovery mode.
|
four minutes, the device will reboot into bootloader.
|
||||||
|
|
||||||
`disabled`
|
`disabled`
|
||||||
> This service will not automatically start with its class.
|
> This service will not automatically start with its class.
|
||||||
|
|
|
||||||
|
|
@ -369,7 +369,7 @@ void Service::Reap(const siginfo_t& siginfo) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// If we crash > 4 times in 4 minutes, reboot into recovery.
|
// If we crash > 4 times in 4 minutes, reboot into bootloader.
|
||||||
boot_clock::time_point now = boot_clock::now();
|
boot_clock::time_point now = boot_clock::now();
|
||||||
if ((flags_ & SVC_CRITICAL) && !(flags_ & SVC_RESTART)) {
|
if ((flags_ & SVC_CRITICAL) && !(flags_ & SVC_RESTART)) {
|
||||||
if (now < time_crashed_ + 4min) {
|
if (now < time_crashed_ + 4min) {
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@
|
||||||
#define SVC_RUNNING 0x004 // currently active
|
#define SVC_RUNNING 0x004 // currently active
|
||||||
#define SVC_RESTARTING 0x008 // waiting to restart
|
#define SVC_RESTARTING 0x008 // waiting to restart
|
||||||
#define SVC_CONSOLE 0x010 // requires console
|
#define SVC_CONSOLE 0x010 // requires console
|
||||||
#define SVC_CRITICAL 0x020 // will reboot into recovery if keeps crashing
|
#define SVC_CRITICAL 0x020 // will reboot into bootloader if keeps crashing
|
||||||
#define SVC_RESET 0x040 // Use when stopping a process,
|
#define SVC_RESET 0x040 // Use when stopping a process,
|
||||||
// but not disabling so it can be restarted with its class.
|
// but not disabling so it can be restarted with its class.
|
||||||
#define SVC_RC_DISABLED 0x080 // Remember if the disabled flag was set in the rc script.
|
#define SVC_RC_DISABLED 0x080 // Remember if the disabled flag was set in the rc script.
|
||||||
|
|
|
||||||
|
|
@ -175,7 +175,7 @@ void ColdBoot::WaitForSubProcesses() {
|
||||||
//
|
//
|
||||||
// When a subprocess crashes, we fatally abort from ueventd. init will restart ueventd when
|
// When a subprocess crashes, we fatally abort from ueventd. init will restart ueventd when
|
||||||
// init reaps it, and the cold boot process will start again. If this continues to fail, then
|
// init reaps it, and the cold boot process will start again. If this continues to fail, then
|
||||||
// since ueventd is marked as a critical service, init will reboot to recovery.
|
// since ueventd is marked as a critical service, init will reboot to bootloader.
|
||||||
//
|
//
|
||||||
// When a subprocess gets stuck, keep ueventd spinning waiting for it. init has a timeout for
|
// When a subprocess gets stuck, keep ueventd spinning waiting for it. init has a timeout for
|
||||||
// cold boot and will reboot to the bootloader if ueventd does not complete in time.
|
// cold boot and will reboot to the bootloader if ueventd does not complete in time.
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue