1.位置:device/qcom/common/rootdir/etc/init.qcom.rc
添加,
chmod 777 /sys/devices/soc/soc:qcom,gpioclk/gpio_clock_duty
chmod 777 /sys/devices/soc/soc:qcom,gpioclk/gpio_clock_enable
2.位置:device/qcom/sepolicy/common/file.te
添加,
type sysfs_gpioclk, fs_type, sysfs_type, mlstrustedobject;
3.位置:device/qcom/sepolicy/common/file_contexts
sysfs files里添加,
/sys/devices/soc/soc:qcom,gpioclk/gpio_clock_duty u:object_r:sysfs_gpioclk:s0
/sys/devices/soc/soc:qcom,gpioclk/gpio_clock_enable u:object_r:sysfs_gpioclk:s0
4.位置:device/qcom/sepolicy/common/untrusted_app.te
添加,
allow untrusted_app sysfs_gpioclk:{file chr_file lnk_file} rw_file_perms;