diff options
author | Li Zefan <lizf@cn.fujitsu.com> | 2009-08-06 22:33:22 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2009-08-26 00:32:06 -0400 |
commit | 43b51ead3f752a3935116e5b1a94254b8573734f (patch) | |
tree | 5d9e88635c85ba7b1d273dea3c4d8d96e5000154 /include/linux/ftrace_event.h | |
parent | aa38e9fc3ea804290efd3a39316d7f7e6c945800 (diff) |
tracing/filters: Add __field_ext() to TRACE_EVENT
Add __field_ext(), so a field can be assigned to a specific
filter_type, which matches a corresponding filter function.
For example, a later patch will allow this:
__field_ext(const char *, str, FILTER_PTR_STR);
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
LKML-Reference: <4A7B9272.6050709@cn.fujitsu.com>
[
Fixed a -1 to FILTER_OTHER
Forward ported to latest kernel.
]
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'include/linux/ftrace_event.h')
-rw-r--r-- | include/linux/ftrace_event.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h index df5b085c4150..0440bea8f6bb 100644 --- a/include/linux/ftrace_event.h +++ b/include/linux/ftrace_event.h | |||
@@ -140,9 +140,16 @@ extern int filter_current_check_discard(struct ftrace_event_call *call, | |||
140 | void *rec, | 140 | void *rec, |
141 | struct ring_buffer_event *event); | 141 | struct ring_buffer_event *event); |
142 | 142 | ||
143 | enum { | ||
144 | FILTER_OTHER = 0, | ||
145 | FILTER_STATIC_STRING, | ||
146 | FILTER_DYN_STRING, | ||
147 | }; | ||
148 | |||
143 | extern int trace_define_field(struct ftrace_event_call *call, | 149 | extern int trace_define_field(struct ftrace_event_call *call, |
144 | const char *type, const char *name, | 150 | const char *type, const char *name, |
145 | int offset, int size, int is_signed); | 151 | int offset, int size, int is_signed, |
152 | int filter_type); | ||
146 | extern int trace_define_common_fields(struct ftrace_event_call *call); | 153 | extern int trace_define_common_fields(struct ftrace_event_call *call); |
147 | 154 | ||
148 | #define is_signed_type(type) (((type)(-1)) < 0) | 155 | #define is_signed_type(type) (((type)(-1)) < 0) |