mirror of
https://github.com/Evolution-X-Devices/device_xiaomi_sapphire
synced 2026-01-27 18:16:34 +00:00
sapphire: rootdir: Give thermal profiles permissions
05-01 19:34:36.590 W/binder:2826_4(2826): type=1400 audit(0.0:3287): avc: denied { write } for name="sconfig" dev="sysfs" ino=65252 scontext=u:r:system_app:s0 tcontext=u:object_r:sysfs_thermal:s0 tclass=file permissive=0
05-01 19:34:36.594 W/FileUtils(2826): No such file /sys/class/thermal/thermal_message/sconfig for writing
05-01 19:34:36.594 W/FileUtils(2826): java.io.FileNotFoundException: /sys/class/thermal/thermal_message/sconfig: open failed: EACCES (Permission denied)
Change-Id: Ie22a96daf93288eefa65e469487bd914c105d7cd
Signed-off-by: NikitaSavc <micraftur@gmail.com>
This commit is contained in:
@@ -56,6 +56,12 @@ on init
|
||||
|
||||
on early-fs
|
||||
start vold
|
||||
|
||||
# Xiaomi Thermal Profiles permissions
|
||||
chmod 0664 /sys/class/thermal/thermal_message/sconfig
|
||||
chown system system /sys/class/thermal/thermal_message/sconfig
|
||||
chmod 0666 /sys/class/thermal/thermal_message/temp_state
|
||||
chown system system /sys/class/thermal/thermal_message/temp_state
|
||||
|
||||
on fs
|
||||
start hwservicemanager
|
||||
|
||||
1
sepolicy/vendor/system_app.te
vendored
1
sepolicy/vendor/system_app.te
vendored
@@ -1,6 +1,7 @@
|
||||
allow system_app proc_pagetypeinfo:file { read open getattr };
|
||||
allow system_app sysfs_zram:dir r_dir_perms;
|
||||
allow system_app sysfs_zram:file r_file_perms;
|
||||
allow system_app sysfs_thermal:file { rw_file_perms getattr };
|
||||
|
||||
binder_call(system_app, hal_audio_default)
|
||||
binder_call(system_app, hal_health_default)
|
||||
|
||||
Reference in New Issue
Block a user