Skip to content

Commit 1de5b5d

Browse files
committed
perf trace: Mark the 'head' arg in the set_robust_list syscall as coming from user space
With that it uses the generic BTF based pretty printer: This one we need to think about, not being acquainted with this syscall, should we _traverse_ that list somehow? Would that be useful? root@number:~# perf trace -e set_robust_list sleep 1 0.000 ( 0.004 ms): sleep/1206493 set_robust_list(head: (struct robust_list_head){.list = (struct robust_list){.next = (struct robust_list *)0x7f48a9a02a20,},.futex_offset = (long int)-32,}, len: 24) = root@number:~# strace prints the default integer args: root@number:~# strace -e set_robust_list sleep 1 set_robust_list(0x7efd99559a20, 24) = 0 +++ exited with 0 +++ root@number:~# Cc: Adrian Hunter <[email protected]> Cc: Alan Maguire <[email protected]> Cc: Howard Chu <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Kan Liang <[email protected]> Cc: Namhyung Kim <[email protected] Link: https://lore.kernel.org/lkml/ZuH6MquMraBvODRp@x1 Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent 0c1019e commit 1de5b5d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tools/perf/builtin-trace.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1351,6 +1351,8 @@ static const struct syscall_fmt syscall_fmts[] = {
13511351
{ .name = "sendto",
13521352
.arg = { [3] = { .scnprintf = SCA_MSG_FLAGS, /* flags */ },
13531353
[4] = SCA_SOCKADDR_FROM_USER(addr), }, },
1354+
{ .name = "set_robust_list", .errpid = true,
1355+
.arg = { [0] = { .from_user = true /* head */, }, }, },
13541356
{ .name = "set_tid_address", .errpid = true, },
13551357
{ .name = "setitimer",
13561358
.arg = { [0] = STRARRAY(which, itimers), }, },

0 commit comments

Comments
 (0)