health: Add CAP_BLOCK_SUSPEND

Add CAP_BLOCK_SUSPEND to android.hardware.health@1.0 and
android.hardware.health@2.1 service so that when epoll_wait()
is waiting on uevents and timer_fd events it can block suspend
to take the necessary action. Without this permission, eventpoll
is going to ignore the flags EPOLLWAKEUP used in health HAL or
healthloop.

Bug: 169873088
Change-Id: If9b0e1f60e47d7bf54942f589acbfbb883b9bac8
This commit is contained in:
Subbaraman Narayanamurthy
2020-10-14 12:32:55 -07:00
parent 1fa07549e1
commit 9ac41106d8
2 changed files with 2 additions and 2 deletions

View File

@@ -2,4 +2,4 @@ service vendor.health-hal-1-0 /vendor/bin/hw/android.hardware.health@1.0-service
class hal
user system
group system
capabilities WAKE_ALARM
capabilities WAKE_ALARM BLOCK_SUSPEND

View File

@@ -2,5 +2,5 @@ service health-hal-2-1 /vendor/bin/hw/android.hardware.health@2.1-service
class hal charger
user system
group system
capabilities WAKE_ALARM
capabilities WAKE_ALARM BLOCK_SUSPEND
file /dev/kmsg w