tracing: add TRACE_EVENT_MAP
authorJulien Desfossez <jdesfossez@efficios.com>
Fri, 9 Sep 2016 22:16:13 +0000 (18:16 -0400)
committerJulien Desfossez <jdesfossez@efficios.com>
Fri, 16 Sep 2016 21:05:58 +0000 (17:05 -0400)
commitb1dace68e555bd54503733782aab991403807846
tree2d38724818f6b2efd56c4bcca3b96aec6433d521
parent90db6ecbb001ad413405a71655c96b602be9bf08
tracing: add TRACE_EVENT_MAP

This macro allows to create an alias of an existing TRACE_EVENT. A
TRACE_EVENT_MAP connects a new probe to an existing tracepoint, so we
can use it to create another output of the same tracepoint without
changing the instrumented code.

This allows to create alternate versions of existing tracepoints to
output more/other fields only in specific use-cases and not all the time
(which could break existing tools and/or bloat the trace with too many
useless fields).

The usage is the same as the TRACE_EVENT macro with the addition of the
"map" parameter which is the name of the alias, the "name" field is the
name of the original tracepoint:
TRACE_EVENT_MAP(name, map, proto, args, tstruct, assign, print)
DEFINE_EVENT_MAP(template, name, map, proto, args)

Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Steven Rostedt (Red Hat) <rostedt@goodmis.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
include/linux/trace_events.h
include/linux/tracepoint.h
include/trace/define_trace.h
include/trace/perf.h
include/trace/trace_events.h
kernel/trace/trace_events.c
This page took 0.02638 seconds and 5 git commands to generate.