Mitigation Logger logs battery related information for 1 second when it is triggered by under voltage or over current interrupts. Information collected is to help debug system brownout. Bug: 228383769 Test: Boot and Test Signed-off-by: George Lee <geolee@google.com> Change-Id: I9ac873d03d57d9a6db8d9233f25c8fabdfc399a5
16 lines
745 B
Text
16 lines
745 B
Text
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;
|