blob: 3d67bd3cce0b256330b4db4af6ac4f3247c733d9 [file] [log] [blame]
Lei Juf7f93da2023-12-15 14:48:25 -08001# Allow context hub HAL to communicate with daemon via socket
2unix_socket_connect(hal_contexthub_default, chre, chre)
3
4# Permit communication with AoC
5allow hal_contexthub_default aoc_device:chr_file rw_file_perms;
6
7# Allow context hub HAL to determine AoC's current clock
8allow hal_contexthub_default sysfs_aoc:dir search;
9allow hal_contexthub_default sysfs_aoc_boottime:file r_file_perms;
10
11# Allow context hub HAL to create thread to watch AOC's device
Lei Ju403baea2023-12-20 16:36:18 -080012allow hal_contexthub_default device:dir r_dir_perms;
Lei Juf7f93da2023-12-15 14:48:25 -080013
14# Allow context hub HAL to use the USF low latency transport
15usf_low_latency_transport(hal_contexthub_default)
16
17# Allow context hub HAL to talk to the WiFi HAL
18binder_call(hal_contexthub_default, hal_wifi_ext)
19allow hal_contexthub_default hal_wifi_ext_service:service_manager find;
20
21# Allow context hub HAL to talk to stats service
22binder_call(hal_contexthub_default, stats_service_server)
23allow hal_contexthub_default fwk_stats_service:service_manager find;
24
Lei Ju403baea2023-12-20 16:36:18 -080025# Allow context hub HAL to write data to /data/vendor/chre/ directory
26allow hal_contexthub_default chre_data_file:dir create_dir_perms;
27allow hal_contexthub_default chre_data_file:file create_file_perms;
28
Lei Juf7f93da2023-12-15 14:48:25 -080029# Allow context hub HAL to use WakeLock
30wakelock_use(hal_contexthub_default)
31
32# Allow context hub HAL to block suspend, which is required to use EPOLLWAKEUP
33allow hal_contexthub_default self:global_capability2_class_set block_suspend;