diff options
author | Steven Rostedt <srostedt@redhat.com> | 2009-02-24 10:21:36 -0500 |
---|---|---|
committer | Steven Rostedt <srostedt@redhat.com> | 2009-02-24 21:54:05 -0500 |
commit | b77e38aa240c3bd9c55c98b9f7c81541e042eae5 (patch) | |
tree | bbb40993e76edc52d2cae1040b941ba4e4d2f965 /include/asm-generic/vmlinux.lds.h | |
parent | 7c37730cd31ddb2d3a1da142af9b18c29b8c433b (diff) |
tracing: add event trace infrastructure
This patch creates the event tracing infrastructure of ftrace.
It will create the files:
/debug/tracing/available_events
/debug/tracing/set_event
The available_events will list the trace points that have been
registered with the event tracer.
set_events will allow the user to enable or disable an event hook.
example:
# echo sched_wakeup > /debug/tracing/set_event
Will enable the sched_wakeup event (if it is registered).
# echo "!sched_wakeup" >> /debug/tracing/set_event
Will disable the sched_wakeup event (and only that event).
# echo > /debug/tracing/set_event
Will disable all events (notice the '>')
# cat /debug/tracing/available_events > /debug/tracing/set_event
Will enable all registered event hooks.
Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Diffstat (limited to 'include/asm-generic/vmlinux.lds.h')
-rw-r--r-- | include/asm-generic/vmlinux.lds.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h index c61fab1dd2f8..0add6b28c366 100644 --- a/include/asm-generic/vmlinux.lds.h +++ b/include/asm-generic/vmlinux.lds.h | |||
@@ -61,6 +61,14 @@ | |||
61 | #define BRANCH_PROFILE() | 61 | #define BRANCH_PROFILE() |
62 | #endif | 62 | #endif |
63 | 63 | ||
64 | #ifdef CONFIG_EVENT_TRACER | ||
65 | #define FTRACE_EVENTS() VMLINUX_SYMBOL(__start_ftrace_events) = .; \ | ||
66 | *(_ftrace_events) \ | ||
67 | VMLINUX_SYMBOL(__stop_ftrace_events) = .; | ||
68 | #else | ||
69 | #define FTRACE_EVENTS() | ||
70 | #endif | ||
71 | |||
64 | /* .data section */ | 72 | /* .data section */ |
65 | #define DATA_DATA \ | 73 | #define DATA_DATA \ |
66 | *(.data) \ | 74 | *(.data) \ |
@@ -81,7 +89,8 @@ | |||
81 | *(__tracepoints) \ | 89 | *(__tracepoints) \ |
82 | VMLINUX_SYMBOL(__stop___tracepoints) = .; \ | 90 | VMLINUX_SYMBOL(__stop___tracepoints) = .; \ |
83 | LIKELY_PROFILE() \ | 91 | LIKELY_PROFILE() \ |
84 | BRANCH_PROFILE() | 92 | BRANCH_PROFILE() \ |
93 | FTRACE_EVENTS() | ||
85 | 94 | ||
86 | #define RO_DATA(align) \ | 95 | #define RO_DATA(align) \ |
87 | . = ALIGN((align)); \ | 96 | . = ALIGN((align)); \ |