diff options
author | Lai Jiangshan <laijs@cn.fujitsu.com> | 2009-11-26 02:49:33 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-11-27 00:24:19 -0500 |
commit | 0f1ef51d244809f417bdf45cdb00109fb6005672 (patch) | |
tree | cf5c5ef305b15973a1f70deb478522bde873f32a /kernel | |
parent | dd1853c3f493f6d22d9e5390b192a07b73d2ac0a (diff) |
trace_syscalls: Add syscall nr field
Field syscall number is missed in syscall_enter_define_fields()/
syscall_exit_define_fields().
Syscall number is also needed for event filter or other users.
Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Acked-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jason Baron <jbaron@redhat.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
LKML-Reference: <4B0E330D.1070206@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/trace/trace_syscalls.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c index 9189cbe86079..63aa8070365d 100644 --- a/kernel/trace/trace_syscalls.c +++ b/kernel/trace/trace_syscalls.c | |||
@@ -261,6 +261,10 @@ int syscall_enter_define_fields(struct ftrace_event_call *call) | |||
261 | if (ret) | 261 | if (ret) |
262 | return ret; | 262 | return ret; |
263 | 263 | ||
264 | ret = trace_define_field(call, SYSCALL_FIELD(int, nr), FILTER_OTHER); | ||
265 | if (ret) | ||
266 | return ret; | ||
267 | |||
264 | for (i = 0; i < meta->nb_args; i++) { | 268 | for (i = 0; i < meta->nb_args; i++) { |
265 | ret = trace_define_field(call, meta->types[i], | 269 | ret = trace_define_field(call, meta->types[i], |
266 | meta->args[i], offset, | 270 | meta->args[i], offset, |
@@ -281,6 +285,10 @@ int syscall_exit_define_fields(struct ftrace_event_call *call) | |||
281 | if (ret) | 285 | if (ret) |
282 | return ret; | 286 | return ret; |
283 | 287 | ||
288 | ret = trace_define_field(call, SYSCALL_FIELD(int, nr), FILTER_OTHER); | ||
289 | if (ret) | ||
290 | return ret; | ||
291 | |||
284 | ret = trace_define_field(call, SYSCALL_FIELD(long, ret), | 292 | ret = trace_define_field(call, SYSCALL_FIELD(long, ret), |
285 | FILTER_OTHER); | 293 | FILTER_OTHER); |
286 | 294 | ||