1# communicate with perfd 2allow hal_camera perfd:unix_stream_socket connectto; 3allow hal_camera perfd_socket:sock_file write; 4allow hal_camera perfd_socket:sock_file w_file_perms; 5 6allow hal_camera self:capability sys_nice; 7 8# communicate with camera 9#allow hal_camera camera:unix_dgram_socket sendto; 10#allow hal_camera camera_data_file:sock_file write; 11#allow hal_camera camera_device:chr_file rw_file_perms; 12 13allow hal_camera gpu_device:chr_file rw_file_perms; 14 15# access to /dev/input/event{5,10} 16allow hal_camera input_device:dir r_dir_perms; 17allow hal_camera input_device:chr_file r_file_perms; 18 19set_prop(hal_camera, camera_prop) 20 21#allow hal_camera sysfs_enable_ps_sensor:file w_file_perms; 22r_dir_file(hal_camera, sysfs_type) 23# find libraries 24allow hal_camera system_file:dir r_dir_perms; 25 26allow hal_camera qdisplay_service:service_manager find; 27 28# talk to system_server 29 30allow hal_camera system_server:unix_stream_socket { read write }; 31 32allow hal_camera self:socket { create ioctl read write }; 33 34# Grant access to Qualcomm MSM Interface (QMI) radio sockets 35# qmux_socket(hal_camera) 36 37# allow hal_camera to call some socket ioctls 38allowxperm hal_camera self:socket ioctl { IPC_ROUTER_IOCTL_LOOKUP_SERVER IPC_ROUTER_IOCTL_BIND_CONTROL_PORT }; 39 40# ignore spurious denial 41dontaudit hal_camera graphics_device:dir search; 42 43userdebug_or_eng(` 44 allow hal_camera diag_device:chr_file rw_file_perms; 45') 46 47# access easel dev nodes 48allow hal_camera easel_device:chr_file { read write ioctl open getattr }; 49allow hal_camera sysfs_easel:file rw_file_perms; 50 51# access hexagon 52allow hal_camera qdsp_device:chr_file r_file_perms; 53