summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Tjin <pattjin@google.com>2016-09-21 14:34:11 -0700
committerPatrick Tjin <pattjin@google.com>2016-09-22 08:22:18 -0700
commite25bd405a25b7c71ffedabf6923e870587d3ff10 (patch)
tree897119cc3544cf9bfa91eb9f816ccdf5ba261509
parent4cf50f31b0ec66efc779387a8a5212162f31e042 (diff)
downloadshamu-e25bd405a25b7c71ffedabf6923e870587d3ff10.tar.gz
Allow shell to access battery info
<36>[ 121.324864] type=1400 audit(1474482824.756:42): avc: denied { read } for pid=3613 comm="sh" name="cycle_count" dev="sysfs" ino=17912 scontext=u:r:shell:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive=0 <36>[ 134.823071] type=1400 audit(1474482838.253:43): avc: denied { read } for pid=4067 comm="sh" name="temp" dev="sysfs" ino=17925 scontext=u:r:shell:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive=0 <36>[ 154.299075] type=1400 audit(1474482857.729:44): avc: denied { read } for pid=4215 comm="sh" name="temp1_input" dev="sysfs" ino=15199 scontext=u:r:shell:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive= Bug: 31653332 Change-Id: I8a4bb0f009033ea61d2feea9c48c8f74378d3be4
-rw-r--r--sepolicy/file_contexts5
1 files changed, 4 insertions, 1 deletions
diff --git a/sepolicy/file_contexts b/sepolicy/file_contexts
index 993a745d..2f905598 100644
--- a/sepolicy/file_contexts
+++ b/sepolicy/file_contexts
@@ -156,7 +156,10 @@
# mmi_touch related /sys files
/sys/devices/f9966000\.i2c/i2c-1/1-004a(/.*)? u:object_r:sysfs_mmi_touch:s0
-/sys/devices/f9925000\.i2c/i2c-0/0-001c/power_supply/battery/capacity u:object_r:sysfs_batteryinfo:s0
+/sys/devices/f9925000\.i2c/i2c-0/0-001c/power_supply/battery/capacity u:object_r:sysfs_batteryinfo:s0
+/sys/devices/f9925000\.i2c/i2c-0/0-001c/power_supply/battery/cycle_count u:object_r:sysfs_batteryinfo:s0
+/sys/devices/f9925000\.i2c/i2c-0/0-001c/power_supply/battery/temp u:object_r:sysfs_batteryinfo:s0
+/sys/devices/f9964000\.i2c/i2c-8/8-0048/temp1_input u:object_r:sysfs_batteryinfo:s0
# Context for mpdecision
/sys/module/msm_thermal/core_control/cpus_offlined u:object_r:sysfs_mpdecision:s0