Merge "Adding init_power allows and supporting file_context/file.te changes."

This commit is contained in:
TreeHugger Robot
2017-02-15 22:30:13 +00:00
committed by Android (Google) Code Review
3 changed files with 13 additions and 0 deletions

View File

@@ -1,5 +1,7 @@
type sysfs_graphics, sysfs_type, fs_type;
type sysfs_camera, sysfs_type, fs_type;
type sysfs_soc, sysfs_type, fs_type;
type qmuxd_socket, file_type;
type netmgrd_socket, file_type;
type thermal_socket, file_type;

View File

@@ -47,6 +47,7 @@
/sys/module/msm_thermal(/.*)? u:object_r:sysfs_thermal:s0
/sys/devices/virtual/graphics/fb([0-2])+/idle_time u:object_r:sysfs_graphics:s0
/sys/devices/soc/8c0000\.qcom,msm-cam(/.*)? u:object_r:sysfs_camera:s0
/sys/devices/soc0(/.*)? u:object_r:sysfs_soc:s0
# files in /system
/system/bin/init\.power\.sh u:object_r:init_power_exec:s0

View File

@@ -3,6 +3,16 @@ type init_power_exec, exec_type, file_type;
init_daemon_domain(init_power)
allow init_power shell_exec:file rx_file_perms;
allow init_power toolbox_exec:file rx_file_perms;
allow init_power sysfs_thermal:dir search;
allow init_power sysfs_thermal:file w_file_perms;
allow init_power sysfs_devices_system_cpu:file w_file_perms;
allow init_power sysfs_soc:file r_file_perms;
allow init_power sysfs_soc:dir search;
userdebug_or_eng(`
permissive init_power;
')