diff --git a/sepolicy/vendor/file_contexts b/sepolicy/vendor/file_contexts index de1b8b3..96f2c00 100644 --- a/sepolicy/vendor/file_contexts +++ b/sepolicy/vendor/file_contexts @@ -76,8 +76,8 @@ /(vendor|system/vendor)/bin/hw/android\.hardware\.secure_element@1\.2-service\.st u:object_r:hal_secure_element_default_exec:s0 # Touch -/(vendor|system/vendor)/bin/hw/vendor\.lineage\.touch@1\.0-service\.berlin u:object_r:hal_lineage_touch_default_exec:s0 -/sys/devices/platform/soc/a94000\.spi/spi_master/spi0/spi0\.0/touchscreen/primary(/.*)? u:object_r:vendor_sysfs_touchpanel:s0 +/(vendor|system/vendor)/bin/hw/vendor\.lineage\.touch@1\.0-service\.(berlin|berlna) u:object_r:hal_lineage_touch_default_exec:s0 +/sys/devices/platform/soc/a94000\.spi/spi_master/spi0/spi0\.0/touchscreen/(primary|NVT-ts)(/.*)? u:object_r:vendor_sysfs_touchpanel:s0 # Thermal /dev/mmi_sys_temp u:object_r:vendor_thermal_device:s0 diff --git a/sepolicy/vendor/property_contexts b/sepolicy/vendor/property_contexts index ab4a967..dcc482f 100644 --- a/sepolicy/vendor/property_contexts +++ b/sepolicy/vendor/property_contexts @@ -11,6 +11,7 @@ ro.vendor.product.display u:object_r:vendor_mot_hw_prop:s0 ro.vendor.product.hardware.sku.variant u:object_r:vendor_mot_hw_prop:s0 ro.vendor.product.model u:object_r:vendor_mot_hw_prop:s0 ro.vendor.product.name u:object_r:vendor_mot_hw_prop:s0 +ro.vendor.touch. u:object_r:vendor_mot_touch_prop:s0 vendor.hw.touch. u:object_r:vendor_mot_touch_prop:s0 vendor.nfc.fw_status u:object_r:vendor_mot_nfc_prop:s0 diff --git a/sepolicy/vendor/vendor_init_touch.te b/sepolicy/vendor/vendor_init_touch.te index 8ee6621..5ea6cbc 100644 --- a/sepolicy/vendor/vendor_init_touch.te +++ b/sepolicy/vendor/vendor_init_touch.te @@ -2,6 +2,10 @@ type vendor_init_touch, domain; type vendor_init_touch_exec, exec_type, vendor_file_type, file_type; init_daemon_domain(vendor_init_touch) +allow vendor_init_touch self:capability chown; +allow vendor_init_touch kmsg_device:chr_file rw_file_perms; +allow vendor_init_touch vendor_sysfs_touchpanel:file { setattr write }; + allow vendor_init_touch vendor_toolbox_exec:file rx_file_perms; r_dir_file(vendor_init_touch , vendor_sysfs_touchpanel)