platform_system_core/rootdir
Tom Cherry 98ad32a967 init: handle sys.powerctl immediately
Currently if a process sets the sys.powerctl property, init adds this
property change into the event queue, just like any other property.
The actual logic to shutdown the device is not executed until init
gets to the action associated with the property change.

This is bad for multiple reasons, but explicitly causes deadlock in
the follow scenario:

A service is started with `exec` or `exec_start`
The same service sets sys.powerctl indicating to the system to
shutdown
The same service then waits infinitely

In this case, init doesn't process any further commands until the exec
service completes, including the command to reboot the device.

This change causes init to immediately handle sys.powerctl and reboot
the device regardless of the state of the event queue, wait for exec,
or wait for property conditions.

Bug: 37209359
Bug: 37415192

Test: Init reboots normally
Test: Update verifier can reboot the system
Change-Id: Iff2295aed970840f47e56c4bacc93001b791fa35
2017-04-17 16:40:06 -07:00
..
etc Add ld.config.txt to /system/etc 2017-03-17 12:27:37 -07:00
Android.mk ASAN: Separate SANITIZE_LITE from asan.options 2017-03-10 10:48:00 -08:00
asan.options Asan.options: Use abort_on_error 2016-08-16 15:45:56 -07:00
asan.options.off.template Rootdir: Add more asan.options support 2016-06-23 14:45:35 -07:00
init-debug.rc init-debug.rc: don't mount debugfs 2017-03-14 21:56:24 -07:00
init.environ.rc.in Add global GCOV_PREFIX option. 2017-02-27 15:00:18 -08:00
init.rc init: handle sys.powerctl immediately 2017-04-17 16:40:06 -07:00
init.usb.configfs.rc init: usb: fix audio_source function typo 2017-01-17 14:27:34 -08:00
init.usb.rc Remove redundant action triggers on persist.sys.usb.config 2016-08-01 21:56:23 +00:00
init.zygote32.rc Restart wificond when zygote died 2017-01-07 19:45:42 -08:00
init.zygote32_64.rc Reapply 1339871138: Only apply schedTune boost to top-app tasks 2017-02-13 17:34:51 +00:00
init.zygote64.rc Restart wificond when zygote died 2017-01-07 19:45:42 -08:00
init.zygote64_32.rc Reapply 1339871138: Only apply schedTune boost to top-app tasks 2017-02-13 17:34:51 +00:00
ueventd.rc ueventd: move subsystem logic from code to ueventd.rc 2017-04-12 16:36:20 -07:00