Chintan Pandya d6b9cc46bf Introduce interrupts module for debug and trace
Interrupts module has following functions to perform:

1. Apply boot time configuration
	- Create a new trace instance
	- Enable required irq and irq_gia events in the
          instance
	- Apply required filters on the high frequency
          events
	- Set instance's trace buffer size
	- Enable tracing
2. Sepolicy for every required access
3. Copy interrupts trace buffer to dumpsys whenever triggered

AVC denials:
avc:  denied  { search } for  comm="dump_interrupts" name="radio" dev="dm-53" ino=373 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=dir permissive=1
avc:  denied  { write } for  comm="dump_interrupts" name="all_logs" dev="dm-53" ino=7808 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=dir permissive=1
avc:  denied  { add_name } for  comm="dump_interrupts" name="interrupts" scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=dir permissive=1
avc:  denied  { create } for  comm="dump_interrupts" name="interrupts" scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=dir permissive=1
avc:  denied  { search } for  comm="dump_interrupts" name="instances" dev="tracefs" ino=2151 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:debugfs_tracing_instances:s0 tclass=dir permissive=1
avc:  denied  { search } for  comm="dump_interrupts" name="radio" dev="dm-53" ino=373 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=dir permissive=1
avc:  denied  { read } for  comm="dump_interrupts" name="trace" dev="tracefs" ino=143409 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:tracefs_instances_interrupts:s0 tclass=file permissive=1
avc:  denied  { open } for  comm="dump_interrupts" path="/sys/kernel/tracing/instances/irq_gia_google/trace" dev="tracefs" ino=143409 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:tracefs_instances_interrupts:s0 tclass=file permissive=1
avc:  denied  { create } for  comm="dump_interrupts" name="interrupts_trace" scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=file permissive=1
avc:  denied  { write open } for  comm="dump_interrupts" path="/data/vendor/radio/logs/always-on/all_logs/interrupts/interrupts_trace" dev="dm-53" ino=8102 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=file permissive=1
avc:  denied  { getattr } for  comm="dump_interrupts" path="/sys/kernel/tracing/instances/irq_gia_google/trace" dev="tracefs" ino=141578 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:tracefs_instances_interrupts:s0 tclass=file permissive=1
avc:  denied  { getattr } for  comm="dump_interrupts" path="/data/vendor/radio/logs/always-on/all_logs/interrupts/interrupts_trace" dev="dm-53" ino=7965 scontext=u:r:dump_interrupts_traces:s0 tcontext=u:object_r:radio_vendor_data_file:s0 tclass=file permissive=1

Flag: EXEMPT, add interrupts traces dump program to bugreport
Bug: 376124648
Test: Manually checked boot time trace configuration. Collected
      `adb bugreport`. And checked interrupt traces are dumped
      into and extracted out from the bugreport. More details
      in the bug.
Change-Id: I08872a321fa9726b50a54aeb0a91ed63c0652a3a
2024-11-22 21:38:57 +00:00
2024-11-18 03:08:08 +00:00
2024-10-11 00:56:55 +00:00
2024-11-12 18:40:13 +00:00
2024-10-24 08:05:26 +00:00
2023-02-13 12:48:47 +08:00
2024-11-13 07:52:03 +00:00
2024-10-25 17:58:48 +00:00
2024-03-13 17:49:16 +01:00
2023-03-31 06:28:07 +08:00
2022-08-12 09:55:21 +08:00

Please refer to go/pixel-recycle to modularize your code in this space.
Description
No description provided
Readme 325 MiB
Languages
C++ 90.2%
Rust 9.8%