Home | History | Annotate | Download | only in vendor
      1 type hal_dumpstate_impl, domain;
      2 hal_server_domain(hal_dumpstate_impl, hal_dumpstate)
      3 
      4 type hal_dumpstate_impl_exec, exec_type, vendor_file_type, file_type;
      5 init_daemon_domain(hal_dumpstate_impl)
      6 
      7 # Execute dump scripts from vendor partition
      8 allow hal_dumpstate_impl vendor_shell_exec:file rx_file_perms;
      9 allow hal_dumpstate_impl vendor_toolbox_exec:file rx_file_perms;
     10 
     11 # Allow to read pixel-trace trace file
     12 allow hal_dumpstate_impl debugfs_tracing_instances:dir search;
     13 allow hal_dumpstate_impl debugfs_tracing_instances:file r_file_perms;
     14 
     15 userdebug_or_eng(`
     16   # smlog_dump
     17   domain_auto_trans(hal_dumpstate_impl, smlog_dump_exec, smlog_dump)
     18   allow hal_dumpstate_impl modem_dump_file:dir create_dir_perms;
     19   allow hal_dumpstate_impl modem_dump_file:file create_file_perms;
     20   allow hal_dumpstate_impl radio_vendor_data_file:dir r_dir_perms;
     21   allow hal_dumpstate_impl netmgr_data_file:dir r_dir_perms;
     22   allow hal_dumpstate_impl radio_vendor_data_file:file r_file_perms;
     23   allow hal_dumpstate_impl netmgr_data_file:file r_file_perms;
     24   allow hal_dumpstate_impl debugfs_tzdbg:dir search;
     25   allow hal_dumpstate_impl debugfs_tzdbg:file r_file_perms;
     26   allow hal_dumpstate_impl sysfs_usb_device:dir r_dir_perms;
     27   allow hal_dumpstate_impl sysfs_usb_device:file r_file_perms;
     28   allow hal_dumpstate_impl sysfs_msm_subsys:file write;
     29 
     30   set_prop(hal_dumpstate_impl, modem_diag_prop)
     31 ')
     32 
     33 get_prop(hal_dumpstate_impl, vendor_radio_prop)
     34 
     35 allow hal_dumpstate_impl uio_device:chr_file rw_file_perms;
     36 r_dir_file(hal_dumpstate_impl, sysfs_uio)
     37 r_dir_file(hal_dumpstate_impl, sysfs_rmtfs)
     38 r_dir_file(hal_dumpstate_impl, sysfs_msm_subsys)
     39 r_dir_file(hal_dumpstate_impl, sysfs_soc)
     40 r_dir_file(hal_dumpstate_impl, sysfs_thermal)
     41 r_dir_file(hal_dumpstate_impl, sysfs_easel)
     42 
     43 allow hal_dumpstate_impl debugfs_ion:dir r_dir_perms;
     44 allow hal_dumpstate_impl debugfs_ion:file r_file_perms;
     45 allow hal_dumpstate_impl debugfs_rpm:file r_file_perms;
     46 allow hal_dumpstate_impl debugfs_wlan:dir r_dir_perms;
     47 allow hal_dumpstate_impl debugfs_wlan:file r_file_perms;
     48 allow hal_dumpstate_impl debugfs_icnss:dir r_dir_perms;
     49 allow hal_dumpstate_impl debugfs_icnss:file r_file_perms;
     50 allow hal_dumpstate_impl debugfs_ipc:dir r_dir_perms;
     51 allow hal_dumpstate_impl debugfs_ipc:file r_file_perms;
     52 allow hal_dumpstate_impl proc_stat:file r_file_perms;
     53 dontaudit hal_dumpstate_impl debugfs_tzdbg:dir search;
     54 dontaudit hal_dumpstate_impl debugfs_tzdbg:file r_file_perms;
     55 allow hal_dumpstate_impl debugfs_ufs:dir r_dir_perms;
     56 allow hal_dumpstate_impl debugfs_ufs:file r_file_perms;
     57 
     58 # Access to files for dumping
     59 allow hal_dumpstate_impl  sysfs:dir r_dir_perms;
     60 # rpm stat
     61 # usb logs
     62 allow hal_dumpstate_impl debugfs_usb:file r_file_perms;
     63 
     64 #Access display debug data
     65 allow hal_dumpstate_impl display_vendor_data_file:dir r_dir_perms;
     66 allow hal_dumpstate_impl display_vendor_data_file:file r_file_perms;
     67 
     68 # Access to touch firmware info
     69 allow hal_dumpstate_impl sysfs_touch:dir r_dir_perms;
     70 allow hal_dumpstate_impl sysfs_touch:file rw_file_perms;
     71 
     72 # Access to UFS info
     73 allow hal_dumpstate_impl sysfs_scsi_devices_0000:dir r_dir_perms;
     74 allow hal_dumpstate_impl sysfs_scsi_devices_0000:file r_file_perms;
     75 
     76 # For collecting bugreports.
     77 allow hal_dumpstate_impl shell_data_file:file getattr;
     78 userdebug_or_eng(`allow hal_dumpstate_impl debugfs_dma_bufinfo:file r_file_perms;')
     79 dontaudit hal_dumpstate_impl debugfs_dma_bufinfo:file r_file_perms;
     80 
     81 # Query and dump power supply nodes
     82 allow hal_dumpstate_impl sysfs_batteryinfo:dir search;
     83 allow hal_dumpstate_impl sysfs_batteryinfo:file r_file_perms;
     84 
     85 # Dump QCOM FG content
     86 allow hal_dumpstate_impl debugfs_fg_sram:dir search;
     87 allow hal_dumpstate_impl debugfs_fg_sram:file rw_file_perms;
     88