aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNamhyung Kim <[email protected]>2013-11-12 15:24:59 +0900
committerArnaldo Carvalho de Melo <[email protected]>2013-11-12 13:00:23 -0300
commit73faab3a421351c342b10b0177fec9eea1a1d809 (patch)
tree2559ff4867c631918d55eb2823ca6cd47da9b1ed
parent67c1e4a53b17894e6a24f95057cc374c4be051cb (diff)
perf trace: Beautify fifth argument of mmap() as fd
The fifth argument of mmap syscall is fd and it often contains -1 as a value for anon mappings. Without this patch it doesn't show the file name as well as it shows -1 as 4294967295. Signed-off-by: Namhyung Kim <[email protected]> Acked-by: David Ahern <[email protected]> Cc: David Ahern <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Peter Zijlstra <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
-rw-r--r--tools/perf/builtin-trace.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index c3008b1c369c..aeb6296a76bd 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -951,7 +951,8 @@ static struct syscall_fmt {
{ .name = "mmap", .hexret = true,
.arg_scnprintf = { [0] = SCA_HEX, /* addr */
[2] = SCA_MMAP_PROT, /* prot */
- [3] = SCA_MMAP_FLAGS, /* flags */ }, },
+ [3] = SCA_MMAP_FLAGS, /* flags */
+ [4] = SCA_FD, /* fd */ }, },
{ .name = "mprotect", .errmsg = true,
.arg_scnprintf = { [0] = SCA_HEX, /* start */
[2] = SCA_MMAP_PROT, /* prot */ }, },