← Documents Documentation/ABI/testing/sysfs-bus-coresight-devices-etm4x GitHub 원문 ↗

Linux 6.18.37 · ABI / testing

CoreSight ETM4x trace source sysfs ABI

ETM4x source enable, trace resources·modes·events, address·sequencer·counter·context·VMID selectors, single-shot controls, management·TRCIDR registers와 timestamp source를 설명합니다.

Source pathDocumentation/ABI/testing/sysfs-bus-coresight-devices-etm4x
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

Trace source, affinity, capabilities와 mode

sysfs-bus-coresight-devices-etm4x:1-93

enable_source는 configured ETM4x를 identified sink에 연결하고 cpu와 resource-count files가 affinity·hardware capabilities를 제공하며 reset·mode가 configuration lifecycle을 제어합니다.

Trace events, exception levels와 address comparators

sysfs-bus-coresight-devices-etm4x:94-182

PE selection, event banks, timestamps·sync·cycle threshold·branch broadcast·instruction filtering을 제어하고 addr_idx로 single 또는 range comparator를 program합니다.

Sequencer, counter, resource, context와 VMID selectors

sysfs-bus-coresight-devices-etm4x:183-284

seq_idx·cntr_idx·res_idx·ctxid_idx·vmid_idx가 각 hardware unit을 선택하고 state/event, count, resource, context ID와 VMID values·masks를 read/write합니다.

Exception-level, PE comparator와 single-shot extensions

sysfs-bus-coresight-devices-etm4x:285-337

Secure/non-secure exception matching, PE comparator start/stop, selected address view와 indexed single-shot control·status를 제공하고 label이 hardware context를 표시합니다.

ETM4x management register views

sysfs-bus-coresight-devices-etm4x:338-435

OS·software locks, power, authentication, device architecture/type/IDs, software trace configuration과 trace ID registers를 exact offsets에서 읽습니다.

TRCIDR capabilities와 timestamp source

sysfs-bus-coresight-devices-etm4x:436-532

TRCIDR files는 trace capability, value widths, resources, speculation과 P0/P1 keys를 보고하며 ts_source는 FEAT_TRF timestamp source 또는 unknown -1을 제공합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 What: /sys/bus/coresight/devices/etm<N>/enable_source
2 Date: April 2015
3 KernelVersion: 4.01
4 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
5 Description: (RW) Enable/disable tracing on this specific trace entiry.
6 Enabling a source implies the source has been configured
7 properly and a sink has been identidifed for it. The path
8 of coresight components linking the source to the sink is
9 configured and managed automatically by the coresight framework.
10
11 What: /sys/bus/coresight/devices/etm<N>/cpu
12 Date: April 2015
13 KernelVersion: 4.01
14 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
15 Description: (Read) The CPU this tracing entity is associated with.
16
17 What: /sys/bus/coresight/devices/etm<N>/nr_pe_cmp
18 Date: April 2015
19 KernelVersion: 4.01
20 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
21 Description: (Read) Indicates the number of PE comparator inputs that are
22 available for tracing.
23
24 What: /sys/bus/coresight/devices/etm<N>/nr_addr_cmp
25 Date: April 2015
26 KernelVersion: 4.01
27 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
28 Description: (Read) Indicates the number of address comparator pairs that are
29 available for tracing.
30
31 What: /sys/bus/coresight/devices/etm<N>/nr_cntr
32 Date: April 2015
33 KernelVersion: 4.01
34 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
35 Description: (Read) Indicates the number of counters that are available for
36 tracing.
37
38 What: /sys/bus/coresight/devices/etm<N>/nr_ext_inp
39 Date: April 2015
40 KernelVersion: 4.01
41 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
42 Description: (Read) Indicates how many external inputs are implemented.
43
44 What: /sys/bus/coresight/devices/etm<N>/numcidc
45 Date: April 2015
46 KernelVersion: 4.01
47 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
48 Description: (Read) Indicates the number of Context ID comparators that are
49 available for tracing.
50
51 What: /sys/bus/coresight/devices/etm<N>/numvmidc
52 Date: April 2015
53 KernelVersion: 4.01
54 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
55 Description: (Read) Indicates the number of VMID comparators that are available
56 for tracing.
57
58 What: /sys/bus/coresight/devices/etm<N>/nrseqstate
59 Date: April 2015
60 KernelVersion: 4.01
61 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
62 Description: (Read) Indicates the number of sequencer states that are
63 implemented.
64
65 What: /sys/bus/coresight/devices/etm<N>/nr_resource
66 Date: April 2015
67 KernelVersion: 4.01
68 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
69 Description: (Read) Indicates the number of resource selection pairs that are
70 available for tracing.
71
72 What: /sys/bus/coresight/devices/etm<N>/nr_ss_cmp
73 Date: April 2015
74 KernelVersion: 4.01
75 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
76 Description: (Read) Indicates the number of single-shot comparator controls that
77 are available for tracing.
78
79 What: /sys/bus/coresight/devices/etm<N>/reset
80 Date: April 2015
81 KernelVersion: 4.01
82 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
83 Description: (Write) Cancels all configuration on a trace unit and set it back
84 to its boot configuration.
85
86 What: /sys/bus/coresight/devices/etm<N>/mode
87 Date: April 2015
88 KernelVersion: 4.01
89 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
90 Description: (RW) Controls various modes supported by this ETM, for example
91 P0 instruction tracing, branch broadcast, cycle counting and
92 context ID tracing.
93
94 What: /sys/bus/coresight/devices/etm<N>/pe
95 Date: April 2015
96 KernelVersion: 4.01
97 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
98 Description: (RW) Controls which PE to trace.
99
100 What: /sys/bus/coresight/devices/etm<N>/event
101 Date: April 2015
102 KernelVersion: 4.01
103 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
104 Description: (RW) Controls the tracing of arbitrary events from bank 0 to 3.
105
106 What: /sys/bus/coresight/devices/etm<N>/event_instren
107 Date: April 2015
108 KernelVersion: 4.01
109 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
110 Description: (RW) Controls the behavior of the events in bank 0 to 3.
111
112 What: /sys/bus/coresight/devices/etm<N>/event_ts
113 Date: April 2015
114 KernelVersion: 4.01
115 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
116 Description: (RW) Controls the insertion of global timestamps in the trace
117 streams.
118
119 What: /sys/bus/coresight/devices/etm<N>/syncfreq
120 Date: April 2015
121 KernelVersion: 4.01
122 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
123 Description: (RW) Controls how often trace synchronization requests occur.
124
125 What: /sys/bus/coresight/devices/etm<N>/cyc_threshold
126 Date: April 2015
127 KernelVersion: 4.01
128 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
129 Description: (RW) Sets the threshold value for cycle counting.
130
131 What: /sys/bus/coresight/devices/etm<N>/bb_ctrl
132 Date: April 2015
133 KernelVersion: 4.01
134 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
135 Description: (RW) Controls which regions in the memory map are enabled to
136 use branch broadcasting.
137
138 What: /sys/bus/coresight/devices/etm<N>/event_vinst
139 Date: April 2015
140 KernelVersion: 4.01
141 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
142 Description: (RW) Controls instruction trace filtering.
143
144 What: /sys/bus/coresight/devices/etm<N>/s_exlevel_vinst
145 Date: April 2015
146 KernelVersion: 4.01
147 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
148 Description: (RW) In Secure state, each bit controls whether instruction
149 tracing is enabled for the corresponding exception level.
150
151 What: /sys/bus/coresight/devices/etm<N>/ns_exlevel_vinst
152 Date: April 2015
153 KernelVersion: 4.01
154 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
155 Description: (RW) In non-secure state, each bit controls whether instruction
156 tracing is enabled for the corresponding exception level.
157
158 What: /sys/bus/coresight/devices/etm<N>/addr_idx
159 Date: April 2015
160 KernelVersion: 4.01
161 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
162 Description: (RW) Select which address comparator or pair (of comparators) to
163 work with.
164
165 What: /sys/bus/coresight/devices/etm<N>/addr_instdatatype
166 Date: April 2015
167 KernelVersion: 4.01
168 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
169 Description: (RW) Controls what type of comparison the trace unit performs.
170
171 What: /sys/bus/coresight/devices/etm<N>/addr_single
172 Date: April 2015
173 KernelVersion: 4.01
174 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
175 Description: (RW) Used to setup single address comparator values.
176
177 What: /sys/bus/coresight/devices/etm<N>/addr_range
178 Date: April 2015
179 KernelVersion: 4.01
180 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
181 Description: (RW) Used to setup address range comparator values.
182
183 What: /sys/bus/coresight/devices/etm<N>/seq_idx
184 Date: April 2015
185 KernelVersion: 4.01
186 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
187 Description: (RW) Select which sequensor.
188
189 What: /sys/bus/coresight/devices/etm<N>/seq_state
190 Date: April 2015
191 KernelVersion: 4.01
192 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
193 Description: (RW) Use this to set, or read, the sequencer state.
194
195 What: /sys/bus/coresight/devices/etm<N>/seq_event
196 Date: April 2015
197 KernelVersion: 4.01
198 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
199 Description: (RW) Moves the sequencer state to a specific state.
200
201 What: /sys/bus/coresight/devices/etm<N>/seq_reset_event
202 Date: April 2015
203 KernelVersion: 4.01
204 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
205 Description: (RW) Moves the sequencer to state 0 when a programmed event
206 occurs.
207
208 What: /sys/bus/coresight/devices/etm<N>/cntr_idx
209 Date: April 2015
210 KernelVersion: 4.01
211 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
212 Description: (RW) Select which counter unit to work with.
213
214 What: /sys/bus/coresight/devices/etm<N>/cntrldvr
215 Date: April 2015
216 KernelVersion: 4.01
217 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
218 Description: (RW) This sets or returns the reload count value of the
219 specific counter.
220
221 What: /sys/bus/coresight/devices/etm<N>/cntr_val
222 Date: April 2015
223 KernelVersion: 4.01
224 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
225 Description: (RW) This sets or returns the current count value of the
226 specific counter.
227
228 What: /sys/bus/coresight/devices/etm<N>/cntr_ctrl
229 Date: April 2015
230 KernelVersion: 4.01
231 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
232 Description: (RW) Controls the operation of the selected counter.
233
234 What: /sys/bus/coresight/devices/etm<N>/res_idx
235 Date: April 2015
236 KernelVersion: 4.01
237 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
238 Description: (RW) Select which resource selection unit to work with.
239
240 What: /sys/bus/coresight/devices/etm<N>/res_ctrl
241 Date: April 2015
242 KernelVersion: 4.01
243 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
244 Description: (RW) Controls the selection of the resources in the trace unit.
245
246 What: /sys/bus/coresight/devices/etm<N>/ctxid_idx
247 Date: April 2015
248 KernelVersion: 4.01
249 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
250 Description: (RW) Select which context ID comparator to work with.
251
252 What: /sys/bus/coresight/devices/etm<N>/ctxid_pid
253 Date: April 2015
254 KernelVersion: 4.01
255 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
256 Description: (RW) Get/Set the context ID comparator value to trigger on.
257
258 What: /sys/bus/coresight/devices/etm<N>/ctxid_masks
259 Date: April 2015
260 KernelVersion: 4.01
261 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
262 Description: (RW) Mask for all 8 context ID comparator value
263 registers (if implemented).
264
265 What: /sys/bus/coresight/devices/etm<N>/vmid_idx
266 Date: April 2015
267 KernelVersion: 4.01
268 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
269 Description: (RW) Select which virtual machine ID comparator to work with.
270
271 What: /sys/bus/coresight/devices/etm<N>/vmid_val
272 Date: April 2015
273 KernelVersion: 4.01
274 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
275 Description: (RW) Get/Set the virtual machine ID comparator value to
276 trigger on.
277
278 What: /sys/bus/coresight/devices/etm<N>/vmid_masks
279 Date: April 2015
280 KernelVersion: 4.01
281 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
282 Description: (RW) Mask for all 8 virtual machine ID comparator value
283 registers (if implemented).
284
285 What: /sys/bus/coresight/devices/etm<N>/addr_exlevel_s_ns
286 Date: December 2019
287 KernelVersion: 5.5
288 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
289 Description: (RW) Set the Exception Level matching bits for secure and
290 non-secure exception levels.
291
292 What: /sys/bus/coresight/devices/etm<N>/vinst_pe_cmp_start_stop
293 Date: December 2019
294 KernelVersion: 5.5
295 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
296 Description: (RW) Access the start stop control register for PE input
297 comparators.
298
299 What: /sys/bus/coresight/devices/etm<N>/addr_cmp_view
300 Date: December 2019
301 KernelVersion: 5.5
302 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
303 Description: (Read) Print the current settings for the selected address
304 comparator.
305
306 What: /sys/bus/coresight/devices/etm<N>/sshot_idx
307 Date: December 2019
308 KernelVersion: 5.5
309 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
310 Description: (RW) Select the single shot control register to access.
311
312 What: /sys/bus/coresight/devices/etm<N>/sshot_ctrl
313 Date: December 2019
314 KernelVersion: 5.5
315 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
316 Description: (RW) Access the selected single shot control register.
317
318 What: /sys/bus/coresight/devices/etm<N>/sshot_status
319 Date: December 2019
320 KernelVersion: 5.5
321 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
322 Description: (Read) Print the current value of the selected single shot
323 status register.
324
325 What: /sys/bus/coresight/devices/etm<N>/sshot_pe_ctrl
326 Date: December 2019
327 KernelVersion: 5.5
328 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
329 Description: (RW) Access the selected single show PE comparator control
330 register.
331
332 What: /sys/bus/coresight/devices/etm<N>/label
333 Date: Aug 2025
334 KernelVersion 6.18
335 Contact: Mao Jinlong <quic_jinlmao@quicinc.com>
336 Description: (Read) Show hardware context information of device.
337
338 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcoslsr
339 Date: April 2015
340 KernelVersion: 4.01
341 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
342 Description: (Read) Print the content of the OS Lock Status Register (0x304).
343 The value it taken directly from the HW.
344
345 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpdcr
346 Date: April 2015
347 KernelVersion: 4.01
348 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
349 Description: (Read) Print the content of the Power Down Control Register
350 (0x310). The value is taken directly from the HW.
351
352 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpdsr
353 Date: April 2015
354 KernelVersion: 4.01
355 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
356 Description: (Read) Print the content of the Power Down Status Register
357 (0x314). The value is taken directly from the HW.
358
359 What: /sys/bus/coresight/devices/etm<N>/mgmt/trclsr
360 Date: April 2015
361 KernelVersion: 4.01
362 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
363 Description: (Read) Print the content of the SW Lock Status Register
364 (0xFB4). The value is taken directly from the HW.
365
366 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcauthstatus
367 Date: April 2015
368 KernelVersion: 4.01
369 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
370 Description: (Read) Print the content of the Authentication Status Register
371 (0xFB8). The value is taken directly from the HW.
372
373 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcdevid
374 Date: April 2015
375 KernelVersion: 4.01
376 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
377 Description: (Read) Print the content of the Device ID Register
378 (0xFC8). The value is taken directly from the HW.
379
380 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcdevarch
381 Date: January 2021
382 KernelVersion: 5.12
383 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
384 Description: (Read) Print the content of the Device Architecture Register
385 (offset 0xFBC). The value is taken directly read
386 from the HW.
387
388 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcdevtype
389 Date: April 2015
390 KernelVersion: 4.01
391 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
392 Description: (Read) Print the content of the Device Type Register
393 (0xFCC). The value is taken directly from the HW.
394
395 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpidr0
396 Date: April 2015
397 KernelVersion: 4.01
398 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
399 Description: (Read) Print the content of the Peripheral ID0 Register
400 (0xFE0). The value is taken directly from the HW.
401
402 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpidr1
403 Date: April 2015
404 KernelVersion: 4.01
405 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
406 Description: (Read) Print the content of the Peripheral ID1 Register
407 (0xFE4). The value is taken directly from the HW.
408
409 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpidr2
410 Date: April 2015
411 KernelVersion: 4.01
412 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
413 Description: (Read) Print the content of the Peripheral ID2 Register
414 (0xFE8). The value is taken directly from the HW.
415
416 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcpidr3
417 Date: April 2015
418 KernelVersion: 4.01
419 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
420 Description: (Read) Print the content of the Peripheral ID3 Register
421 (0xFEC). The value is taken directly from the HW.
422
423 What: /sys/bus/coresight/devices/etm<N>/mgmt/trcconfig
424 Date: February 2016
425 KernelVersion: 4.07
426 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
427 Description: (Read) Print the content of the trace configuration register
428 (0x010) as currently set by SW.
429
430 What: /sys/bus/coresight/devices/etm<N>/mgmt/trctraceid
431 Date: February 2016
432 KernelVersion: 4.07
433 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
434 Description: (Read) Print the content of the trace ID register (0x040).
435
436 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr0
437 Date: April 2015
438 KernelVersion: 4.01
439 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
440 Description: (Read) Returns the tracing capabilities of the trace unit (0x1E0).
441 The value is taken directly from the HW.
442
443 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr1
444 Date: April 2015
445 KernelVersion: 4.01
446 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
447 Description: (Read) Returns the tracing capabilities of the trace unit (0x1E4).
448 The value is taken directly from the HW.
449
450 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr2
451 Date: April 2015
452 KernelVersion: 4.01
453 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
454 Description: (Read) Returns the maximum size of the data value, data address,
455 VMID, context ID and instruction address in the trace unit
456 (0x1E8). The value is taken directly from the HW.
457
458 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr3
459 Date: April 2015
460 KernelVersion: 4.01
461 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
462 Description: (Read) Returns the value associated with various resources
463 available to the trace unit. See the Trace Macrocell
464 architecture specification for more details (0x1E8).
465 The value is taken directly from the HW.
466
467 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr4
468 Date: April 2015
469 KernelVersion: 4.01
470 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
471 Description: (Read) Returns how many resources the trace unit supports (0x1F0).
472 The value is taken directly from the HW.
473
474 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr5
475 Date: April 2015
476 KernelVersion: 4.01
477 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
478 Description: (Read) Returns how many resources the trace unit supports (0x1F4).
479 The value is taken directly from the HW.
480
481 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr8
482 Date: April 2015
483 KernelVersion: 4.01
484 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
485 Description: (Read) Returns the maximum speculation depth of the instruction
486 trace stream. (0x180). The value is taken directly from the HW.
487
488 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr9
489 Date: April 2015
490 KernelVersion: 4.01
491 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
492 Description: (Read) Returns the number of P0 right-hand keys that the trace unit
493 can use (0x184). The value is taken directly from the HW.
494
495 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr10
496 Date: April 2015
497 KernelVersion: 4.01
498 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
499 Description: (Read) Returns the number of P1 right-hand keys that the trace unit
500 can use (0x188). The value is taken directly from the HW.
501
502 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr11
503 Date: April 2015
504 KernelVersion: 4.01
505 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
506 Description: (Read) Returns the number of special P1 right-hand keys that the
507 trace unit can use (0x18C). The value is taken directly from
508 the HW.
509
510 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr12
511 Date: April 2015
512 KernelVersion: 4.01
513 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
514 Description: (Read) Returns the number of conditional P1 right-hand keys that
515 the trace unit can use (0x190). The value is taken directly
516 from the HW.
517
518 What: /sys/bus/coresight/devices/etm<N>/trcidr/trcidr13
519 Date: April 2015
520 KernelVersion: 4.01
521 Contact: Mathieu Poirier <mathieu.poirier@linaro.org>
522 Description: (Read) Returns the number of special conditional P1 right-hand keys
523 that the trace unit can use (0x194). The value is taken
524 directly from the HW.
525
526 What: /sys/bus/coresight/devices/etm<N>/ts_source
527 Date: October 2022
528 KernelVersion: 6.1
529 Contact: Mathieu Poirier <mathieu.poirier@linaro.org> or Suzuki K Poulose <suzuki.poulose@arm.com>
530 Description: (Read) When FEAT_TRF is implemented, value of TRFCR_ELx.TS used for
531 trace session. Otherwise -1 indicates an unknown time source. Check
532 trcidr0.tssize to see if a global timestamp is available.
533

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

ETM4x source control과 hardware capabilities

1-93
공통 항목내용
Date2015년 4월
KernelVersion4.01
ContactMathieu Poirier <mathieu.poirier@linaro.org>
적용 범위별도 metadata가 명시된 lines 285 이후 attributes를 제외한 lines 1-284
What suffixAccess전문 번역
enable_sourceRW이 특정 trace entity의 tracing을 enable 또는 disable합니다. Source를 enable한다는 것은 source가 올바르게 configure되었고 sink가 identified되었음을 전제로 합니다. Source와 sink를 연결하는 CoreSight components path는 CoreSight framework가 자동으로 configure하고 manage합니다.
cpuRead이 tracing entity와 연결된 CPU입니다.
nr_pe_cmpReadTracing에 사용할 수 있는 PE comparator inputs 수를 나타냅니다.
nr_addr_cmpReadTracing에 사용할 수 있는 address comparator pairs 수를 나타냅니다.
nr_cntrReadTracing에 사용할 수 있는 counters 수를 나타냅니다.
nr_ext_inpRead구현된 external inputs 수를 나타냅니다.
numcidcReadTracing에 사용할 수 있는 Context ID comparators 수를 나타냅니다.
numvmidcReadTracing에 사용할 수 있는 VMID comparators 수를 나타냅니다.
nrseqstateRead구현된 sequencer states 수를 나타냅니다.
nr_resourceReadTracing에 사용할 수 있는 resource selection pairs 수를 나타냅니다.
nr_ss_cmpReadTracing에 사용할 수 있는 single-shot comparator controls 수를 나타냅니다.
resetWriteTrace unit의 모든 configuration을 cancel하고 boot configuration으로 되돌립니다.
modeRWP0 instruction tracing, branch broadcast, cycle counting과 context ID tracing 등 이 ETM이 지원하는 여러 mode를 제어합니다.

모든 suffix는 /sys/bus/coresight/devices/etm<N>/ 아래의 file입니다.

ETM4x source activation and resources
Read comparator, counter and resource countsConfigure ETM4x sourceIdentify sinkEnable sourceFramework manages trace path
Write resetCancel all configurationRestore boot configuration

Hardware resource counts를 확인해 source를 configure하고 sink를 identify한 뒤 framework-managed path를 enable한다.

Trace event controls와 address comparisons

94-182
What suffixAccess전문 번역
peRW어떤 PE를 trace할지 제어합니다.
eventRWBank 0부터 3까지의 arbitrary events tracing을 제어합니다.
event_instrenRWBank 0부터 3까지 events의 behavior를 제어합니다.
event_tsRWTrace streams에 global timestamp를 삽입하는 동작을 제어합니다.
syncfreqRWTrace synchronization request가 얼마나 자주 발생하는지 제어합니다.
cyc_thresholdRWCycle counting의 threshold value를 설정합니다.
bb_ctrlRWMemory map에서 branch broadcasting을 사용할 수 있는 regions를 제어합니다.
event_vinstRWInstruction trace filtering을 제어합니다.
s_exlevel_vinstRWSecure state에서 각 bit가 corresponding exception level의 instruction tracing enable 여부를 제어합니다.
ns_exlevel_vinstRWNon-secure state에서 각 bit가 corresponding exception level의 instruction tracing enable 여부를 제어합니다.
addr_idxRW작업할 address comparator 또는 comparator pair를 선택합니다.
addr_instdatatypeRWTrace unit이 수행하는 comparison type을 제어합니다.
addr_singleRWSingle address comparator values를 setup하는 데 사용합니다.
addr_rangeRWAddress range comparator values를 setup하는 데 사용합니다.
ETM4x event and address filtering
Select PE and trace modesConfigure event banks and timestampsApply secure and non-secure exception filtersGenerate filtered trace
Write addr_idxSelect address comparatorSet comparison typeProgram single or range value

Trace mode와 event filters를 설정하고 addr_idx로 selected comparator에 single 또는 range value를 적용한다.

Indexed sequencer, counters, resources, Context ID와 VMID

183-284
What suffixAccess전문 번역
seq_idxRW작업할 sequencer를 선택합니다.
seq_stateRWSequencer state를 설정하거나 읽습니다.
seq_eventRWSequencer state를 특정 state로 이동시킵니다.
seq_reset_eventRWProgrammed event가 발생하면 sequencer를 state 0으로 이동시킵니다.
cntr_idxRW작업할 counter unit을 선택합니다.
cntrldvrRW특정 counter의 reload count value를 설정하거나 반환합니다.
cntr_valRW특정 counter의 current count value를 설정하거나 반환합니다.
cntr_ctrlRWSelected counter의 operation을 제어합니다.
res_idxRW작업할 resource selection unit을 선택합니다.
res_ctrlRWTrace unit의 resource selection을 제어합니다.
ctxid_idxRW작업할 context ID comparator를 선택합니다.
ctxid_pidRWTrigger할 context ID comparator value를 get 또는 set합니다.
ctxid_masksRW구현된 경우 context ID comparator value registers 8개 모두에 적용하는 mask입니다.
vmid_idxRW작업할 virtual machine ID comparator를 선택합니다.
vmid_valRWTrigger할 virtual machine ID comparator value를 get 또는 set합니다.
vmid_masksRW구현된 경우 virtual machine ID comparator value registers 8개 모두에 적용하는 mask입니다.
ETM4x selector pattern
seq_idxSelected sequencerstate, event and reset event
cntr_idxSelected counterreload, current value and control
res_idxSelected resource unitres_ctrl
ctxid_idxSelected Context ID comparatorctxid_pid
vmid_idxSelected VMID comparatorvmid_val
ctxid_masks and vmid_masksMasks for all eight comparator registers

각 selector가 target hardware unit을 고른 뒤 corresponding control/value file이 selected unit을 조작한다.

Exception matching, PE comparator와 single-shot controls

285-337
공통 항목내용
Date2019년 12월
KernelVersion5.5
ContactMathieu Poirier <mathieu.poirier@linaro.org>
적용 범위lines 285-331의 7개 attributes
What suffixAccess전문 번역
addr_exlevel_s_nsRWSecure와 non-secure exception levels의 Exception Level matching bits를 설정합니다.
vinst_pe_cmp_start_stopRWPE input comparators의 start/stop control register에 access합니다.
addr_cmp_viewReadSelected address comparator의 current settings를 출력합니다.
sshot_idxRWAccess할 single-shot control register를 선택합니다.
sshot_ctrlRWSelected single-shot control register에 access합니다.
sshot_statusReadSelected single-shot status register의 current value를 출력합니다.
sshot_pe_ctrlRWSelected single-shot PE comparator control register에 access합니다.
항목전문 번역
What/sys/bus/coresight/devices/etm<N>/label
Date2025년 8월
KernelVersion6.18
ContactMao Jinlong <quic_jinlmao@quicinc.com>
Description(Read) Device의 hardware context information을 보여 줍니다.

ETM4x management register contents

338-435

아래 management files는 /sys/bus/coresight/devices/etm<N>/mgmt/ 아래에 있으며 contact는 Mathieu Poirier <mathieu.poirier@linaro.org>입니다.

What suffixDate / KernelRegisterOffset전문 번역
trcoslsr2015-04 / 4.01OS Lock Status0x304Hardware에서 직접 가져온 content를 출력합니다.
trcpdcr2015-04 / 4.01Power Down Control0x310Hardware에서 직접 가져온 content를 출력합니다.
trcpdsr2015-04 / 4.01Power Down Status0x314Hardware에서 직접 가져온 content를 출력합니다.
trclsr2015-04 / 4.01SW Lock Status0xFB4Hardware에서 직접 가져온 content를 출력합니다.
trcauthstatus2015-04 / 4.01Authentication Status0xFB8Hardware에서 직접 가져온 content를 출력합니다.
trcdevid2015-04 / 4.01Device ID0xFC8Hardware에서 직접 가져온 content를 출력합니다.
trcdevarch2021-01 / 5.12Device Architecture0xFBCHardware에서 직접 읽은 content를 출력합니다.
trcdevtype2015-04 / 4.01Device Type0xFCCHardware에서 직접 가져온 content를 출력합니다.
trcpidr02015-04 / 4.01Peripheral ID00xFE0Hardware에서 직접 가져온 content를 출력합니다.
trcpidr12015-04 / 4.01Peripheral ID10xFE4Hardware에서 직접 가져온 content를 출력합니다.
trcpidr22015-04 / 4.01Peripheral ID20xFE8Hardware에서 직접 가져온 content를 출력합니다.
trcpidr32015-04 / 4.01Peripheral ID30xFECHardware에서 직접 가져온 content를 출력합니다.
trcconfig2016-02 / 4.07Trace Configuration0x010Software가 current setting으로 정한 register content를 출력합니다.
trctraceid2016-02 / 4.07Trace ID0x040Trace ID register content를 출력합니다.

TRCIDR trace capabilities와 timestamp source

436-532
공통 항목내용
Date2015년 4월
KernelVersion4.01
ContactMathieu Poirier <mathieu.poirier@linaro.org>
적용 범위lines 436-525의 TRCIDR attributes
What suffixOffset전문 번역
trcidr/trcidr00x1E0Trace unit의 tracing capabilities를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr10x1E4Trace unit의 tracing capabilities를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr20x1E8Trace unit에서 data value, data address, VMID, context ID와 instruction address의 maximum size를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr30x1E8Trace unit에서 사용할 수 있는 여러 resource와 관련된 값을 반환합니다. 자세한 내용은 Trace Macrocell architecture specification을 참조하십시오. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr40x1F0Trace unit이 지원하는 resource 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr50x1F4Trace unit이 지원하는 resource 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr80x180Instruction trace stream의 maximum speculation depth를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr90x184Trace unit이 사용할 수 있는 P0 right-hand keys 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr100x188Trace unit이 사용할 수 있는 P1 right-hand keys 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr110x18CTrace unit이 사용할 수 있는 special P1 right-hand keys 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr120x190Trace unit이 사용할 수 있는 conditional P1 right-hand keys 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
trcidr/trcidr130x194Trace unit이 사용할 수 있는 special conditional P1 right-hand keys 수를 반환합니다. Hardware에서 직접 값을 가져옵니다.
항목전문 번역
What/sys/bus/coresight/devices/etm<N>/ts_source
Date2022년 10월
KernelVersion6.1
ContactMathieu Poirier <mathieu.poirier@linaro.org>
Description(Read) FEAT_TRF가 구현되어 있으면 trace session에 사용하는 TRFCR_ELx.TS value입니다. 그렇지 않으면 -1이 unknown time source를 나타냅니다. Global timestamp를 사용할 수 있는지는 trcidr0.tssize를 확인하십시오.