Merge "[ALPS03886705] EM:hardware-testing SELinux" into alps-trunk-p0.basic

Change-Id: I55b1304744365bc136958588314801688aeb6995
MTK-Commit-Id: 284dd69d48bbf9e38d524607901ffe6072faa866
This commit is contained in:
Juan Rong 2020-01-18 10:01:44 +08:00 committed by Gerrit Code Review
commit 049e7472ec
5 changed files with 105 additions and 0 deletions

View File

@ -30,3 +30,30 @@ allow em_svr nvram_device:blk_file { open read write };
# Date: WK1812 # Date: WK1812
# Purpose: add for Gyroscope sensor # Purpose: add for Gyroscope sensor
allow em_svr gyroscope_device:chr_file { read ioctl open }; allow em_svr gyroscope_device:chr_file { read ioctl open };
# Date : 2018/06/15
# Purpose : Allow EM access touchscreen settings
allow radio sysfs_tpd_debug:dir search;
allow radio sysfs_tpd_setting:dir search;
allow radio sysfs_tpd_debug:file rw_file_perms;
allow radio sysfs_tpd_setting:file rw_file_perms;
# Date : 2018/06/15
# Purpose : EM FreqHopping setting
allow em_svr proc_freqhop:file { open read write };
# Date : 2018/06/15
# Purpose : EM flash reading
allow em_svr proc_flash:file { open read };
allow em_svr proc_partition:file { open read };
# Date : 2018/06/15
# Purpose : EM Power PMU reading/setting
allow em_svr sysfs_pmu:dir { search };
allow em_svr sysfs_pmu:file { open read write };
allow em_svr sysfs_pmu:lnk_file { read };
# Date : 2018/06/15
# Purpose : EM Power debug_log setting
allow em_svr sysfs_spm:dir { search };
allow em_svr sysfs_spm:file { open read write };

View File

@ -275,4 +275,26 @@ type sysfs_dual_role_usb20, fs_type, sysfs_type;
# Touch parameters file # Touch parameters file
type sysfs_tpd_setting, fs_type, sysfs_type; type sysfs_tpd_setting, fs_type, sysfs_type;
type sysfs_tpd_debug, fs_type, sysfs_type;
# Date : 2018/06/11
# Purpose : mtk EM FreqHopping setting
type proc_freqhop, fs_type, proc_type;
# Date : 2018/06/11
# Purpose : mtk EM flash reading
type proc_flash, fs_type, proc_type;
type proc_partition, fs_type, proc_type;
# Date : 2018/06/11
# Purpose : mtk EM PMU reading/setting
type sysfs_pmu, fs_type, sysfs_type;
# Date : 2018/06/11
# Purpose : mtk EM Power debug_log setting
type sysfs_spm, fs_type, sysfs_type;
# Date : 2018/06/11
# Purpose : mtk EM Audio headset detect
type sysfs_headset, fs_type, sysfs_type;

View File

@ -617,3 +617,26 @@
/vendor/bin/aeev u:object_r:aee_aedv_exec:s0 /vendor/bin/aeev u:object_r:aee_aedv_exec:s0
/vendor/bin/hw/android\.hardware\.drm@1\.1-service\.clearkey u:object_r:hal_drm_clearkey_exec:s0 /vendor/bin/hw/android\.hardware\.drm@1\.1-service\.clearkey u:object_r:hal_drm_clearkey_exec:s0
# Date : 2018/06/15
# Purpose : mtk EM touchscreen settings
/sys/module/tpd_debug(/.*)? u:object_r:sysfs_tpd_debug:s0
# Date : 2018/06/15
# Purpose : mtk EM flash reading
/proc/mounts u:object_r:proc_flash:s0
# Date : 2018/06/15
# Purpose : mtk EM PMU reading/setting
/sys/devices/platform/mt-pmic(/.*)? u:object_r:sysfs_pmu:s0
/sys/devices/platform/mt6333-user(/.*)? u:object_r:sysfs_pmu:s0
/sys/devices/platform/mt6311-user(/.*)? u:object_r:sysfs_pmu:s0
# Date : 2018/06/15
# Purpose : mtk EM Power debug_log setting
/sys/devices/platform/spm(/.*)? u:object_r:sysfs_spm:s0
# Date : 2018/06/15
# Purpose : mtk EM Audio headset detect
/sys/bus/platform/drivers/Accdet_Driver/state u:object_r:sysfs_headset:s0

View File

@ -45,3 +45,11 @@ genfscon sysfs /devices/platform/battery u:object_r:sysfs_batteryinfo:s0
genfscon sysfs /devices/platform/mt_charger/power_supply u:object_r:sysfs_batteryinfo:s0 genfscon sysfs /devices/platform/mt_charger/power_supply u:object_r:sysfs_batteryinfo:s0
genfscon sysfs /power/vcorefs/vcore_debug u:object_r:sysfs_vcore_debug:s0 genfscon sysfs /power/vcorefs/vcore_debug u:object_r:sysfs_vcore_debug:s0
genfscon sysfs /power/vcorefs/opp_table u:object_r:sysfs_vcore_debug:s0 genfscon sysfs /power/vcorefs/opp_table u:object_r:sysfs_vcore_debug:s0
# mtk EM FreqHopping setting
genfscon proc /freqhopping/freqhopping_debug u:object_r:proc_freqhop:s0
genfscon proc /freqhopping/status u:object_r:proc_freqhop:s0
genfscon proc /freqhopping/dumpregs u:object_r:proc_freqhop:s0
# mtk EM flash reading
genfscon proc /partitions u:object_r:proc_partition:s0

View File

@ -186,3 +186,28 @@ set_prop(radio, mtk_bt_sspdebug_prop)
allow radio sysfs_batteryinfo:dir search; allow radio sysfs_batteryinfo:dir search;
allow radio sysfs_batteryinfo:file { read write getattr open create}; allow radio sysfs_batteryinfo:file { read write getattr open create};
allow radio sysfs_vbus:file { read getattr open }; allow radio sysfs_vbus:file { read getattr open };
# Date : 2018/06/15
# Purpose : Allow EM access touchscreen settings
allow radio sysfs_tpd_debug:dir { search read open };
allow radio sysfs_tpd_setting:dir { search read open };
# Date : 2018/06/15
# Purpose : mtk EM PMU reading/setting
allow radio sysfs_pmu:dir { search };
allow radio sysfs_pmu:file { read };
allow radio sysfs_pmu:lnk_file { read };
# Date : 2018/06/15
# Purpose : mtk EM Power debug_log setting
allow radio sysfs_spm:dir { search };
# Date : 2018/06/15
# Purpose : Allow EM access AAL settings
set_prop(radio, mtk_aal_prop)
get_prop(radio, mtk_aal_prop)
# Date : 2018/06/15
# Purpose: Allow EM detect Audio headset status
allow radio sysfs_headset:file { read open };