Give permissions to save usf stats and dump them in bugreports.
Creating a mechanism to save some USF stat history to device and pipe it to bugreports. Granting permissions so that this can work. Bug: 242320914 Test: Stats save and are visible in a bugreport. Change-Id: Ia1973800ed053f54da043d306e11c0a7b10132a7
This commit is contained in:
parent
1673f21545
commit
4b4afb2eea
4 changed files with 16 additions and 0 deletions
|
@ -10,3 +10,7 @@ type persist_sensor_reg_file, file_type, vendor_persist_type;
|
|||
# end with "data_file".
|
||||
type sensor_reg_data_file, file_type, data_file_type;
|
||||
|
||||
# Declare the sensor debug data file type. By convention, data file types
|
||||
# end with "data_file".
|
||||
type sensor_debug_data_file, file_type, data_file_type;
|
||||
|
||||
|
|
|
@ -8,3 +8,5 @@
|
|||
# Sensor registry data files.
|
||||
/data/vendor/sensors/registry(/.*)? u:object_r:sensor_reg_data_file:s0
|
||||
|
||||
# Sensor debug data files.
|
||||
/data/vendor/sensors/debug(/.*)? u:object_r:sensor_debug_data_file:s0
|
||||
|
|
|
@ -12,6 +12,12 @@ r_dir_file(hal_sensors_default, persist_camera_file)
|
|||
allow hal_sensors_default sensor_reg_data_file:dir rw_dir_perms;
|
||||
allow hal_sensors_default sensor_reg_data_file:file create_file_perms;
|
||||
|
||||
userdebug_or_eng(`
|
||||
# Allow creation and writing of sensor debug data files.
|
||||
allow hal_sensors_default sensor_debug_data_file:dir rw_dir_perms;
|
||||
allow hal_sensors_default sensor_debug_data_file:file create_file_perms;
|
||||
')
|
||||
|
||||
# Allow access to the AoC communication driver.
|
||||
allow hal_sensors_default aoc_device:chr_file rw_file_perms;
|
||||
|
||||
|
|
|
@ -35,6 +35,10 @@ allow hal_dumpstate_default vendor_log_file:dir search;
|
|||
allow hal_dumpstate_default vendor_usf_stats:file execute_no_trans;
|
||||
allow hal_dumpstate_default vendor_usf_reg_edit:file execute_no_trans;
|
||||
allow hal_dumpstate_default vendor_dumpsys:file execute_no_trans;
|
||||
userdebug_or_eng(`
|
||||
allow hal_dumpstate_default sensor_debug_data_file:dir r_dir_perms;
|
||||
allow hal_dumpstate_default sensor_debug_data_file:file r_file_perms;
|
||||
')
|
||||
|
||||
allow hal_dumpstate_default sscoredump_vendor_data_crashinfo_file:dir r_dir_perms;
|
||||
allow hal_dumpstate_default sscoredump_vendor_data_crashinfo_file:file r_file_perms;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue