diff --git a/sepolicy/vendor/file_contexts b/sepolicy/vendor/file_contexts index 53ac6c4..63ca34f 100644 --- a/sepolicy/vendor/file_contexts +++ b/sepolicy/vendor/file_contexts @@ -1,6 +1,7 @@ # Audio /dev/socket/audio_hw_socket u:object_r:audio_socket:s0 /dev/elliptic(.*)? u:object_r:sound_device:s0 +/dev/mius(.*)? u:object_r:sound_device:s0 # Battery /vendor/bin/batteryd u:object_r:batteryd_exec:s0 @@ -20,6 +21,9 @@ /vendor/bin/hw/vendor\.lineage\.powershare@1\.0-service\.xiaomi_sm8350 u:object_r:hal_lineage_powershare_default_exec:s0 # Sensors +/sys/bus/iio/devices u:object_r:vendor_sysfs_iio:s0 +/sys/devices/platform/us_prox.0/iio:device1(/.*)? u:object_r:vendor_sysfs_iio:s0 +/sys/devices/platform/soc/c440000.qcom,spmi/spmi-0/spmi0-00/c440000.qcom,spmi:qcom,pmk8350@0:vadc@3100/iio:device0(/.*)? u:object_r:vendor_sysfs_iio:s0 /vendor/bin/hw/android\.hardware\.sensors@2.1-service\.xiaomi_sm8350-multihal u:object_r:hal_sensors_default_exec:s0 # Fingerprint diff --git a/sepolicy/vendor/hal_sensors_default.te b/sepolicy/vendor/hal_sensors_default.te index 0368c1e..a5418fc 100644 --- a/sepolicy/vendor/hal_sensors_default.te +++ b/sepolicy/vendor/hal_sensors_default.te @@ -1,3 +1,9 @@ +type vendor_sysfs_iio, fs_type, sysfs_type; + allow hal_sensors_default audio_socket:sock_file rw_file_perms; allow hal_sensors_default sound_device:chr_file rw_file_perms; allow hal_sensors_default hal_audio_default:unix_stream_socket connectto; + +allow hal_sensors_default iio_device:chr_file r_file_perms; +allow hal_sensors_default vendor_sysfs_iio:dir r_dir_perms; +allow hal_sensors_default vendor_sysfs_iio:file rw_file_perms;