vendor_init: Fix touch avc denial of high_sensitivity.

Fixed following avc denial:
avc: denied { write } for name="high_sensitivity" dev="proc" ino=4026534550 scontext=u:r:vendor_init:s0 tcontext=u:object_r:proc:s0 tclass=file permissive=1
//The file node is proc/focaltech_touch/high_sensitivity


Bug: 199105136
Test: Verify pass by checking device log are w/o above errors while
switching setting/display/increase touch sensitivity.

Change-Id: I8dbe4190056767407413082580320593292725fe
This commit is contained in:
Mason Wang 2022-03-17 18:02:50 +08:00 committed by TreeHugger Robot
parent 22cbebd97a
commit 500e7624e9
3 changed files with 8 additions and 1 deletions

View file

@ -105,3 +105,6 @@ userdebug_or_eng(`
# USB-C throttling stats
type sysfs_usbc_throttling_stats, sysfs_type, fs_type;
# Touch
type proc_touch, proc_type, fs_type;

View file

@ -29,7 +29,8 @@ genfscon sysfs /devices/soc0/revision u
# Touch
genfscon sysfs /devices/platform/10d10000.spi/spi_master/spi0/spi0.0/synaptics_tcm.0/sysfs u:object_r:sysfs_touch:s0
genfscon sysfs /devices/virtual/sec/tsp u:object_r:sysfs_touch:s0
genfscon sysfs /devices/virtual/sec/tsp u:object_r:sysfs_touch:s0
genfscon proc /focaltech_touch u:object_r:proc_touch:s0
# tracefs
genfscon tracefs /events/dmabuf_heap/dma_heap_stat u:object_r:debugfs_tracing:s0

View file

@ -23,3 +23,6 @@ allow vendor_init sysfs_st33spi:file w_file_perms;
# Fingerprint property
set_prop(vendor_init, vendor_fingerprint_prop)
# Touch
allow vendor_init proc_touch:file w_file_perms;