healthd provides health@2.0 service.

* remove binder calls to healthd (storaged, system_server)
* Allow healthd to serve health HAL

Bug: 62229583
Test: no health related denials
Test: VTS health test
Test: BatteryManagerTest

Change-Id: I0cf1872c0ba69e7de7c3f529d548f9ffe39812ac
This commit is contained in:
Yifan Hong 2017-09-25 19:40:59 -07:00
parent e80177d5fd
commit b9aa010089
3 changed files with 3 additions and 10 deletions

View File

@ -2,5 +2,5 @@ typeattribute healthd coredomain;
init_daemon_domain(healthd)
# Allow callback to storaged batteryproperties listener
binder_call(healthd, storaged)
# Allow healthd to serve health HAL
hal_server_domain(healthd, hal_health)

View File

@ -40,9 +40,7 @@ add_service(storaged, storaged_service)
binder_use(storaged)
binder_call(storaged, system_server)
# use batteryproperties service
allow storaged batteryproperties_service:service_manager find;
binder_call(storaged, healthd)
hal_client_domain(storaged, hal_health)
# Implements a dumpsys interface.
allow storaged dumpstate:fd use;

View File

@ -21,9 +21,6 @@ allow healthd self:netlink_kobject_uevent_socket create_socket_perms_no_ioctl;
wakelock_use(healthd)
binder_use(healthd)
binder_service(healthd)
binder_call(healthd, system_server)
hal_client_domain(healthd, hal_health)
# Write to state file.
@ -56,8 +53,6 @@ allow healthd ashmem_device:chr_file execute;
allow healthd self:process execmem;
allow healthd proc_sysrq:file rw_file_perms;
add_service(healthd, batteryproperties_service)
# Healthd needs to tell init to continue the boot
# process when running in charger mode.
set_prop(healthd, system_prop)