Skip to content

Commit d3439f9

Browse files
committed
tracing: Document trace_marker triggers
Add documentation and an example on how to use trace_marker triggers. Reviewed-by: Tom Zanussi <[email protected]> Reviewed-by: Namhyung Kim <[email protected]> Signed-off-by: Steven Rostedt (VMware) <[email protected]>
1 parent 3be4c1e commit d3439f9

File tree

3 files changed

+554
-2
lines changed

3 files changed

+554
-2
lines changed

Documentation/trace/events.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,10 +338,14 @@ used for conditionally invoking triggers.
338338

339339
The syntax for event triggers is roughly based on the syntax for
340340
set_ftrace_filter 'ftrace filter commands' (see the 'Filter commands'
341-
section of Documentation/trace/ftrace.txt), but there are major
341+
section of Documentation/trace/ftrace.rst), but there are major
342342
differences and the implementation isn't currently tied to it in any
343343
way, so beware about making generalizations between the two.
344344

345+
Note: Writing into trace_marker (See Documentation/trace/ftrace.rst)
346+
can also enable triggers that are written into
347+
/sys/kernel/tracing/events/ftrace/print/trigger
348+
345349
6.1 Expression syntax
346350
---------------------
347351

Documentation/trace/ftrace.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,11 @@ of ftrace. Here is a list of some of the key files:
507507

508508
trace_fd = open("trace_marker", WR_ONLY);
509509

510+
Note: Writing into the trace_marker file can also initiate triggers
511+
that are written into /sys/kernel/tracing/events/ftrace/print/trigger
512+
See "Event triggers" in Documentation/trace/events.rst and an
513+
example in Documentation/trace/histogram.rst (Section 3.)
514+
510515
trace_marker_raw:
511516

512517
This is similar to trace_marker above, but is meant for for binary data

0 commit comments

Comments
 (0)