From 8140a508451466f19a95097d0ce936468801b1da Mon Sep 17 00:00:00 2001 From: Rick Chen Date: Tue, 8 Nov 2022 22:44:09 +0800 Subject: [PATCH] Allow CHRE to use EPOLLWAKEUP [DO NOT MERGE] avc: denied { block_suspend } for comm="UsfTransport" capability=36 scontext=u:r:chre:s0 tcontext=u:r:chre:s0 tclass=capability2 permissive=0 Bug: 238666865 Test: Check no chre avc denied. Change-Id: Ie936055550c6221beae394c264d664c1e76f946b Signed-off-by: Rick Chen --- whitechapel_pro/chre.te | 3 +++ 1 file changed, 3 insertions(+) diff --git a/whitechapel_pro/chre.te b/whitechapel_pro/chre.te index 6d826217..26c1675f 100644 --- a/whitechapel_pro/chre.te +++ b/whitechapel_pro/chre.te @@ -22,3 +22,6 @@ allow chre hal_wifi_ext_hwservice:hwservice_manager find; # Allow CHRE host to talk to stats service allow chre fwk_stats_service:service_manager find; binder_call(chre, stats_service_server) + +# Allow CHRE to block suspend, which is required to use EPOLLWAKEUP. +allow chre self:global_capability2_class_set block_suspend;