sepolicy: allow dump_power to read battery_history_device

avc:  denied  { open } for  path="/dev/maxfg_history" dev="tmpfs" ino=1235 scontext=u:r:dump_power:s0 tcontext=u:object_r:battery_history_device:s0 tclass=chr_file permissive=0
avc:  denied  { read } for  name="maxfg_history" dev="tmpfs" ino=1250 scontext=u:r:dump_power:s0 tcontext=u:object_r:battery_history_device:s0 tclass=chr_file permissive=0

Bug: 377895720
Flag: EXEMPT bugfix
Test: /dev/maxfg_history correctly dumped
Change-Id: I766f8a21468370e69a7c11b028b2326434ad2380
Signed-off-by: Spade Lee <spadelee@google.com>
This commit is contained in:
Spade Lee 2024-11-07 17:30:16 +00:00
parent d2f8dde307
commit 8b6e654781

View file

@ -13,6 +13,7 @@ allow dump_power mitigation_vendor_data_file:dir r_dir_perms;
allow dump_power mitigation_vendor_data_file:file r_file_perms; allow dump_power mitigation_vendor_data_file:file r_file_perms;
allow dump_power sysfs_bcl:dir r_dir_perms; allow dump_power sysfs_bcl:dir r_dir_perms;
allow dump_power sysfs_bcl:file r_file_perms; allow dump_power sysfs_bcl:file r_file_perms;
allow dump_power battery_history_device:chr_file r_file_perms;
userdebug_or_eng(` userdebug_or_eng(`
r_dir_file(dump_power, vendor_battery_debugfs) r_dir_file(dump_power, vendor_battery_debugfs)