diff options
Diffstat (limited to 'include/linux/ftrace_event.h')
-rw-r--r-- | include/linux/ftrace_event.h | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h index 3167f2df4126..02b8b24f8f51 100644 --- a/include/linux/ftrace_event.h +++ b/include/linux/ftrace_event.h | |||
@@ -11,8 +11,6 @@ struct trace_array; | |||
11 | struct tracer; | 11 | struct tracer; |
12 | struct dentry; | 12 | struct dentry; |
13 | 13 | ||
14 | DECLARE_PER_CPU(struct trace_seq, ftrace_event_seq); | ||
15 | |||
16 | struct trace_print_flags { | 14 | struct trace_print_flags { |
17 | unsigned long mask; | 15 | unsigned long mask; |
18 | const char *name; | 16 | const char *name; |
@@ -58,6 +56,9 @@ struct trace_iterator { | |||
58 | struct ring_buffer_iter *buffer_iter[NR_CPUS]; | 56 | struct ring_buffer_iter *buffer_iter[NR_CPUS]; |
59 | unsigned long iter_flags; | 57 | unsigned long iter_flags; |
60 | 58 | ||
59 | /* trace_seq for __print_flags() and __print_symbolic() etc. */ | ||
60 | struct trace_seq tmp_seq; | ||
61 | |||
61 | /* The below is zeroed out in pipe_read */ | 62 | /* The below is zeroed out in pipe_read */ |
62 | struct trace_seq seq; | 63 | struct trace_seq seq; |
63 | struct trace_entry *ent; | 64 | struct trace_entry *ent; |
@@ -146,14 +147,19 @@ struct ftrace_event_class { | |||
146 | int (*raw_init)(struct ftrace_event_call *); | 147 | int (*raw_init)(struct ftrace_event_call *); |
147 | }; | 148 | }; |
148 | 149 | ||
150 | extern int ftrace_event_reg(struct ftrace_event_call *event, | ||
151 | enum trace_reg type); | ||
152 | |||
149 | enum { | 153 | enum { |
150 | TRACE_EVENT_FL_ENABLED_BIT, | 154 | TRACE_EVENT_FL_ENABLED_BIT, |
151 | TRACE_EVENT_FL_FILTERED_BIT, | 155 | TRACE_EVENT_FL_FILTERED_BIT, |
156 | TRACE_EVENT_FL_RECORDED_CMD_BIT, | ||
152 | }; | 157 | }; |
153 | 158 | ||
154 | enum { | 159 | enum { |
155 | TRACE_EVENT_FL_ENABLED = (1 << TRACE_EVENT_FL_ENABLED_BIT), | 160 | TRACE_EVENT_FL_ENABLED = (1 << TRACE_EVENT_FL_ENABLED_BIT), |
156 | TRACE_EVENT_FL_FILTERED = (1 << TRACE_EVENT_FL_FILTERED_BIT), | 161 | TRACE_EVENT_FL_FILTERED = (1 << TRACE_EVENT_FL_FILTERED_BIT), |
162 | TRACE_EVENT_FL_RECORDED_CMD = (1 << TRACE_EVENT_FL_RECORDED_CMD_BIT), | ||
157 | }; | 163 | }; |
158 | 164 | ||
159 | struct ftrace_event_call { | 165 | struct ftrace_event_call { |
@@ -171,6 +177,7 @@ struct ftrace_event_call { | |||
171 | * 32 bit flags: | 177 | * 32 bit flags: |
172 | * bit 1: enabled | 178 | * bit 1: enabled |
173 | * bit 2: filter_active | 179 | * bit 2: filter_active |
180 | * bit 3: enabled cmd record | ||
174 | * | 181 | * |
175 | * Changes to flags must hold the event_mutex. | 182 | * Changes to flags must hold the event_mutex. |
176 | * | 183 | * |
@@ -257,8 +264,7 @@ static inline void | |||
257 | perf_trace_buf_submit(void *raw_data, int size, int rctx, u64 addr, | 264 | perf_trace_buf_submit(void *raw_data, int size, int rctx, u64 addr, |
258 | u64 count, struct pt_regs *regs, void *head) | 265 | u64 count, struct pt_regs *regs, void *head) |
259 | { | 266 | { |
260 | perf_tp_event(addr, count, raw_data, size, regs, head); | 267 | perf_tp_event(addr, count, raw_data, size, regs, head, rctx); |
261 | perf_swevent_put_recursion_context(rctx); | ||
262 | } | 268 | } |
263 | #endif | 269 | #endif |
264 | 270 | ||