Files
device_google_wahoo/sepolicy/vendor/hal_camera.te
Emilian Peev 84ea4994d1 Allow vendor read access to 'ro.camera' property
The Camera HIDL wrapper needs access to
properties "ro.camera.req.fmq.size" and
"ro.camera.res.fmq.size" which control
the fast message queue size. Cases exist
where the default size is not sufficient.
The precise amount can be controlled by
the respective device configuration which
can set the previously mentioned properties.

Bug: 77865891
Test: Manual using application
Change-Id: I468bde2ee356e0d1d20f781fe6a3af48143cc4b2
Merged-In: I468bde2ee356e0d1d20f781fe6a3af48143cc4b2
2019-05-14 13:40:00 -07:00

48 lines
1.4 KiB
Plaintext

allow hal_camera self:capability sys_nice;
allow hal_camera gpu_device:chr_file rw_file_perms;
# access to /dev/input/event{5,10}
allow hal_camera input_device:dir r_dir_perms;
allow hal_camera input_device:chr_file r_file_perms;
set_prop(hal_camera, camera_prop)
#allow hal_camera sysfs_enable_ps_sensor:file w_file_perms;
r_dir_file(hal_camera, sysfs_type)
# find libraries
allow hal_camera system_file:dir r_dir_perms;
allow hal_camera qdisplay_service:service_manager find;
# talk to system_server
allow hal_camera system_server:unix_stream_socket { read write };
allow hal_camera self:socket { create ioctl read write };
# Grant access to Qualcomm MSM Interface (QMI) radio sockets
# qmux_socket(hal_camera)
# allow hal_camera to call some socket ioctls
allowxperm hal_camera self:socket ioctl { IPC_ROUTER_IOCTL_LOOKUP_SERVER IPC_ROUTER_IOCTL_BIND_CONTROL_PORT };
# ignore spurious denial
dontaudit hal_camera graphics_device:dir search;
userdebug_or_eng(`
allow hal_camera diag_device:chr_file rw_file_perms;
')
# access easel dev nodes
allow hal_camera easel_device:chr_file { read write ioctl open getattr };
allow hal_camera sysfs_easel:file rw_file_perms;
# access hexagon
allow hal_camera qdsp_device:chr_file r_file_perms;
# lens calibration file
allow hal_camera persist_file:dir search;
allow hal_camera persist_sensors_file:dir search;
allow hal_camera persist_sensors_file:file { getattr open read };