STRUCT ETM_CONFIG(9)
π struct etm_config(9) β the Kernel API Manual, but make it a group chat π
okay so bestie, buckle up, because today we're talking about struct etm_config β the literal MAIN CHARACTER of the ETM world. It's a struct that holds all the configuration info related to an ETM, and yes, it's giving "backstage pass to the whole tracing operation." πΈ
This one lives in the Kernel API Manual, section 9, and it's gonna be a whole journey. Grab a strawberry drink π and let's go.
β¨ SYNOPSIS β¨
Lowkey the biggest vibe reveal of the whole page. Here's the whole struct, verbatim, no cuts, no skips, no "you get the idea":
struct etm_config {
u32 mode;
u32 ctrl;
u32 trigger_event;
u32 startstop_ctrl;
u32 enable_event;
u32 enable_ctrl1;
u32 enable_ctrl2;
u32 fifofull_level;
u8 addr_idx;
u32 addr_val[ETM_MAX_ADDR_CMP];
u32 addr_acctype[ETM_MAX_ADDR_CMP];
u32 addr_type[ETM_MAX_ADDR_CMP];
u8 cntr_idx;
u32 cntr_rld_val[ETM_MAX_CNTR];
u32 cntr_event[ETM_MAX_CNTR];
u32 cntr_rld_event[ETM_MAX_CNTR];
u32 cntr_val[ETM_MAX_CNTR];
u32 seq_12_event;
u32 seq_21_event;
u32 seq_23_event;
u32 seq_31_event;
u32 seq_32_event;
u32 seq_13_event;
u32 seq_curr_state;
u8 ctxid_idx;
u32 ctxid_pid[ETM_MAX_CTXID_CMP];
u32 ctxid_mask;
u32 sync_freq;
u32 timestamp_event;
};
like, that's the whole cast. every single one of them matters. π
π Members π
okay now let's meet the members one by one, because they all have lore.
modeβ controls the various modes supported by this ETM/PTM. it's the vibe-setter fr fr.ctrlβ used in conjunction withmode. they're a duo, you can't separate them, it's giving iconic partnership.trigger_eventβ setting for registerETMTRIGGER.startstop_ctrlβ setting for registerETMTSSCR.enable_eventβ setting for registerETMTEEVR.enable_ctrl1β setting for registerETMTECR1.enable_ctrl2β setting for registerETMTECR2.fifofull_levelβ setting for registerETMFFLR.addr_idxβ index for the address comparator selection.addr_valβ value for address comparator register.addr_acctypeβ access type for address comparator register.addr_typeβ current status of the comparator register. not the past, not the future, the current status. periodt.cntr_idxβ index for the counter register selection.cntr_rld_valβ reload value of a counter register.cntr_eventβ control for counter enable register.cntr_rld_eventβ value for counter reload event register.cntr_valβ counter value register.seq_12_eventβ event causing the transition from 1 to 2.seq_21_eventβ event causing the transition from 2 to 1.seq_23_eventβ event causing the transition from 2 to 3.seq_31_eventβ event causing the transition from 3 to 1.seq_32_eventβ event causing the transition from 3 to 2.seq_13_eventβ event causing the transition from 1 to 3.seq_curr_stateβ current value of the sequencer register.ctxid_idxβ index for the context ID registers.ctxid_pidβ value for the context ID to trigger on.ctxid_maskβ mask applicable to all the context IDs. all of them. every last one. πsync_freqβ Synchronisation frequency.timestamp_eventβ Defines an event that requests the insertion of a timestamp into the trace stream. time-stamping? we love to see it. β
π¦ SEE ALSO π¦
go touch some other docs, bestie, they're right here:
- Kernel file
./drivers/hwtracing/coresight/coresight-etm.hstructetm_drvdata(9)
ngl the sequencer transitions (1β2, 2β1, 2β3, 3β1, 3β2, 1β3) are lowkey the most dramatic part of this whole page. six events, all iconic, no cap. π₯
and that's the whole page, bestie!! π«Ά this little beauty comes to you from ./drivers/hwtracing/coresight, dated October 2026, and it's filed under struct etm_config(9). mwah, go forth and configure your ETM responsibly πβ¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms