diff options
author | Li Zefan <lizf@cn.fujitsu.com> | 2009-08-17 04:55:18 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-08-17 05:25:09 -0400 |
commit | ba8b3a40ba7e06d00c27508f090803af90e8dbbf (patch) | |
tree | 7805446c5a6a945dddb872a9b84c3ceee30d1583 /kernel | |
parent | 7ead8b8313d92b3a69a1a61b0dcbc4cd66c960dc (diff) |
tracing/syscalls: Fix to print parameter types
When syscall tracing was implemented as a tracer,
"syscall_arg_type" trace option could be set to enable the
display of syscall parameter types.
Now this option is gone since it's no longer a tracer, but the
code is still there but dead.
So we remove dead code and re-enable the printing of paramete
types via the verbose option:
# echo verbose > trace_options
# echo syscalls > set_event
# cat trace
...
bash-3331 [000] 95.348937: sys_fcntl64 -> 0x1
bash-3331 [000] 95.348942: sys_close(unsigned int fd: a)
...
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jason Baron <jbaron@redhat.com>
LKML-Reference: <4A891AF6.5050102@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/trace/trace_syscalls.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c index f837cccabcf7..f130dacfeef4 100644 --- a/kernel/trace/trace_syscalls.c +++ b/kernel/trace/trace_syscalls.c | |||
@@ -13,21 +13,6 @@ static int sys_refcount_exit; | |||
13 | static DECLARE_BITMAP(enabled_enter_syscalls, FTRACE_SYSCALL_MAX); | 13 | static DECLARE_BITMAP(enabled_enter_syscalls, FTRACE_SYSCALL_MAX); |
14 | static DECLARE_BITMAP(enabled_exit_syscalls, FTRACE_SYSCALL_MAX); | 14 | static DECLARE_BITMAP(enabled_exit_syscalls, FTRACE_SYSCALL_MAX); |
15 | 15 | ||
16 | /* Option to display the parameters types */ | ||
17 | enum { | ||
18 | TRACE_SYSCALLS_OPT_TYPES = 0x1, | ||
19 | }; | ||
20 | |||
21 | static struct tracer_opt syscalls_opts[] = { | ||
22 | { TRACER_OPT(syscall_arg_type, TRACE_SYSCALLS_OPT_TYPES) }, | ||
23 | { } | ||
24 | }; | ||
25 | |||
26 | static struct tracer_flags syscalls_flags = { | ||
27 | .val = 0, /* By default: no parameters types */ | ||
28 | .opts = syscalls_opts | ||
29 | }; | ||
30 | |||
31 | enum print_line_t | 16 | enum print_line_t |
32 | print_syscall_enter(struct trace_iterator *iter, int flags) | 17 | print_syscall_enter(struct trace_iterator *iter, int flags) |
33 | { | 18 | { |
@@ -55,7 +40,7 @@ print_syscall_enter(struct trace_iterator *iter, int flags) | |||
55 | 40 | ||
56 | for (i = 0; i < entry->nb_args; i++) { | 41 | for (i = 0; i < entry->nb_args; i++) { |
57 | /* parameter types */ | 42 | /* parameter types */ |
58 | if (syscalls_flags.val & TRACE_SYSCALLS_OPT_TYPES) { | 43 | if (trace_flags & TRACE_ITER_VERBOSE) { |
59 | ret = trace_seq_printf(s, "%s ", entry->types[i]); | 44 | ret = trace_seq_printf(s, "%s ", entry->types[i]); |
60 | if (!ret) | 45 | if (!ret) |
61 | return TRACE_TYPE_PARTIAL_LINE; | 46 | return TRACE_TYPE_PARTIAL_LINE; |