bcl: Add Mitigation Logger - sepolicy am: bc2cf5c153 am: e9621aaa91 am: 724884bbad

Original change: https://googleplex-android-review.googlesource.com/c/device/google/gs201-sepolicy/+/18527859

Change-Id: I1c724540e162b2093319172f88cac667b37d3643
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
George Lee 2022-05-27 18:41:39 +00:00 committed by Automerger Merge Worker
commit 6fec1f655f
3 changed files with 19 additions and 0 deletions

View file

@ -0,0 +1,16 @@
type battery_mitigation, domain;
type battery_mitigation_exec, exec_type, vendor_file_type, file_type;
init_daemon_domain(battery_mitigation)
get_prop(battery_mitigation, boot_status_prop)
hal_client_domain(battery_mitigation, hal_thermal);
hal_client_domain(battery_mitigation, hal_health);
r_dir_file(battery_mitigation, sysfs_batteryinfo)
r_dir_file(battery_mitigation, sysfs_iio_devices)
r_dir_file(battery_mitigation, sysfs_thermal)
r_dir_file(battery_mitigation, thermal_link_device)
r_dir_file(battery_mitigation, sysfs_odpm)
allow battery_mitigation sysfs_thermal:lnk_file r_file_perms;
allow battery_mitigation mitigation_vendor_data_file:dir rw_dir_perms;
allow battery_mitigation mitigation_vendor_data_file:file create_file_perms;

View file

@ -15,6 +15,7 @@ type per_boot_file, file_type, data_file_type, core_data_file_type;
type uwb_vendor_data_file, file_type, data_file_type, app_data_file_type;
type uwb_data_vendor, file_type, data_file_type;
type powerstats_vendor_data_file, file_type, data_file_type;
type mitigation_vendor_data_file, file_type, data_file_type;
userdebug_or_eng(`
typeattribute tcpdump_vendor_data_file mlstrustedobject;
typeattribute vendor_slog_file mlstrustedobject;

View file

@ -41,6 +41,7 @@
/vendor/bin/hw/android\.hardware\.qorvo\.uwb\.service u:object_r:hal_uwb_vendor_default_exec:s0
/vendor/bin/rlsservice u:object_r:rlsservice_exec:s0
/vendor/bin/hw/android\.hardware\.biometrics\.fingerprint@2\.1-service\.fpc u:object_r:fingerprint_factory_service_exec:s0
/vendor/bin/hw/battery_mitigation u:object_r:battery_mitigation_exec:s0
# Vendor Firmwares
/vendor/firmware(/.*)? u:object_r:vendor_fw_file:s0
@ -207,6 +208,7 @@
/data/vendor/uwb(/.*)? u:object_r:uwb_data_vendor:s0
/dev/battery_history u:object_r:battery_history_device:s0
/data/vendor/powerstats(/.*)? u:object_r:powerstats_vendor_data_file:s0
/data/vendor/mitigation(/.*)? u:object_r:mitigation_vendor_data_file:s0
# Persist
/mnt/vendor/persist/battery(/.*)? u:object_r:persist_battery_file:s0