author | Nick Chalko <nchalko@google.com> | 2018-10-30 22:27:37 (GMT) |
---|---|---|
committer | Nick Chalko <nchalko@google.com> | 2018-11-16 16:37:06 (GMT) |
commit | 791aae81c14a1a3afa3d08d11598ac5cd16f4fc5 (patch) | |
tree | ecf9ce9528494c67d312777a5203be0873f8569a | |
parent | 64bc3b285adffe51e42a93c3f3055c888c8a6350 (diff) | |
download | common-791aae81c14a1a3afa3d08d11598ac5cd16f4fc5.zip common-791aae81c14a1a3afa3d08d11598ac5cd16f4fc5.tar.gz common-791aae81c14a1a3afa3d08d11598ac5cd16f4fc5.tar.bz2 |
Add policiy for /sys/class/extcon hdmi files
This allows PhoneWindowManager to be notified on hdmi state changes.
Change-Id: I39475ef3b9553cbd3d81c7fe6103840fba4c5508
Test: flash; watch "adb shell dumpsys activity broadcasts | grep HDMI"
-rw-r--r-- | sepolicy/file_contexts | 1 | ||||
-rw-r--r-- | sepolicy/system_server.te | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/sepolicy/file_contexts b/sepolicy/file_contexts index b64d41e..60499e8 100644 --- a/sepolicy/file_contexts +++ b/sepolicy/file_contexts @@ -164,6 +164,7 @@ /sys/devices/virtual/remote/amremote(/.*)? u:object_r:sysfs_remote:s0 /sys/devices/virtual/amhdmitx/amhdmitx0/hdmi_audio/state u:object_r:sysfs_hdmi:s0 +/sys/devices/virtual/amhdmitx/amhdmitx0/hdmi/state u:object_r:sysfs_hdmi:s0 /sys/devices/virtual/thermal/thermal_zone0/mode u:object_r:sysfs_display:s0 /acct/uid/cgroup.procs u:object_r:reco_file:s0 diff --git a/sepolicy/system_server.te b/sepolicy/system_server.te index 7d7e89d..84ab0ac 100644 --- a/sepolicy/system_server.te +++ b/sepolicy/system_server.te @@ -28,7 +28,9 @@ allow system_server wifi_data_file:file { read create }; allow system_server sysfs:file { getattr }; allow system_server sysfs_rtc:file { read write open getattr }; -allow system_server sysfs_hdmi:file { read write open getattr }; + +r_dir_file(system_server, sysfs_hdmi) +allow system_server sysfs_hdmi:file write; allow system_server sysfs_display:lnk_file { read write open getattr }; allow system_server sysfs_display:file { read write open getattr }; |