diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-08-29 13:47:08 +0200 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-08-30 20:52:20 +0200 |
commit | 6ebb686225a83200b94777cfc651c94f4e0f6f50 (patch) | |
tree | 91d77b3084f419d06b0706cbd9d9df2128b7124c /tools/perf/examples | |
parent | perf trace augmented_syscalls: Augment bind's 'myaddr' sockaddr arg (diff) | |
download | linux-6ebb686225a83200b94777cfc651c94f4e0f6f50.tar.xz linux-6ebb686225a83200b94777cfc651c94f4e0f6f50.zip |
perf trace augmented_syscalls: Augment sendto's 'addr' arg
Its a 'struct sockaddr' pointer, augment it with the same beautifier as
for 'connect' and 'bind', that all receive from userspace that pointer.
Doing it in the other direction remains to be done, hooking at the
syscalls:sys_exit_{accept4?,recvmsg} tracepoints somehow.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: https://lkml.kernel.org/n/tip-k2eu68lsphnm2fthc32gq76c@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/examples')
-rw-r--r-- | tools/perf/examples/bpf/augmented_syscalls.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tools/perf/examples/bpf/augmented_syscalls.c b/tools/perf/examples/bpf/augmented_syscalls.c index 71edb7ad8698..be06d2c9e8c9 100644 --- a/tools/perf/examples/bpf/augmented_syscalls.c +++ b/tools/perf/examples/bpf/augmented_syscalls.c @@ -142,4 +142,17 @@ struct syscall_enter_connect_args { augmented_sockaddr_syscall_enter(connect); +struct syscall_enter_sendto_args { + unsigned long long common_tp_fields; + long syscall_nr; + long fd; + void *buff; + long len; + unsigned long flags; + struct sockaddr *addr_ptr; + long addr_len; +}; + +augmented_sockaddr_syscall_enter(sendto); + license(GPL); |