[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZiEupQ_PDlA_3Lo4@x1>
Date: Thu, 18 Apr 2024 11:31:01 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Changbin Du <changbin.du@...wei.com>
Cc: Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...hat.com>,
Namhyung Kim <namhyung@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>, Ian Rogers <irogers@...gle.com>,
Adrian Hunter <adrian.hunter@...el.com>,
linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 4/4] perf trace beauty: Always show mprotect prot even
though PROT_NONE
On Thu, Apr 18, 2024 at 09:13:04PM +0800, Changbin Du wrote:
> Do not omit the flags even though it is PROT_NONE.
>
> Signed-off-by: Changbin Du <changbin.du@...wei.com>
> ---
> tools/perf/builtin-trace.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> index 349550b02f79..7f936f1b5519 100644
> --- a/tools/perf/builtin-trace.c
> +++ b/tools/perf/builtin-trace.c
> @@ -1042,7 +1042,7 @@ static const struct syscall_fmt syscall_fmts[] = {
> [4] = { .scnprintf = SCA_MOVE_MOUNT_FLAGS, /* flags */ }, }, },
> { .name = "mprotect",
> .arg = { [0] = { .scnprintf = SCA_HEX, /* start */ },
> - [2] = { .scnprintf = SCA_MMAP_PROT, /* prot */ }, }, },
> + [2] = { .scnprintf = SCA_MMAP_PROT, .show_zero = true, /* prot */ }, }, },
So since syscall_arg__scnprintf_mmap_prot() special cases 0 to print
NONE for prot... Ok, I'll expand a bit the commit log message _and_ the
syscall_fmts entry for mprotect.
- Arnaldo
> { .name = "mq_unlink",
> .arg = { [0] = { .scnprintf = SCA_FILENAME, /* u_name */ }, }, },
> { .name = "mremap", .hexret = true,
> --
> 2.34.1
Powered by blists - more mailing lists