diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2020-10-01 11:14:22 -0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2020-10-01 11:14:22 -0300 |
commit | 08fc4762149c964c0fa8682a75591fe6f22dc39e (patch) | |
tree | b4177617b54528e55f7716fbe24c0b16f647946a /tools/io_uring/liburing.h | |
parent | 61693228b6e3f9de1c07bfec10b3204e69495fb1 (diff) | |
download | linux-stable-08fc4762149c964c0fa8682a75591fe6f22dc39e.tar.gz linux-stable-08fc4762149c964c0fa8682a75591fe6f22dc39e.tar.bz2 linux-stable-08fc4762149c964c0fa8682a75591fe6f22dc39e.zip |
tools beauty: Add script to generate table of mmap's 'prot' argument
Will be wired up in the following csets:
$ tools/perf/trace/beauty/mmap_prot.sh
static const char *mmap_prot[] = {
[ilog2(0x1) + 1] = "READ",
#ifndef PROT_READ
#define PROT_READ 0x1
#endif
[ilog2(0x2) + 1] = "WRITE",
#ifndef PROT_WRITE
#define PROT_WRITE 0x2
#endif
[ilog2(0x4) + 1] = "EXEC",
#ifndef PROT_EXEC
#define PROT_EXEC 0x4
#endif
[ilog2(0x8) + 1] = "SEM",
#ifndef PROT_SEM
#define PROT_SEM 0x8
#endif
[ilog2(0x01000000) + 1] = "GROWSDOWN",
#ifndef PROT_GROWSDOWN
#define PROT_GROWSDOWN 0x01000000
#endif
[ilog2(0x02000000) + 1] = "GROWSUP",
#ifndef PROT_GROWSUP
#define PROT_GROWSUP 0x02000000
#endif
};
$
$
$
$ tools/perf/trace/beauty/mmap_prot.sh alpha
static const char *mmap_prot[] = {
[ilog2(0x4) + 1] = "EXEC",
#ifndef PROT_EXEC
#define PROT_EXEC 0x4
#endif
[ilog2(0x01000000) + 1] = "GROWSDOWN",
#ifndef PROT_GROWSDOWN
#define PROT_GROWSDOWN 0x01000000
#endif
[ilog2(0x02000000) + 1] = "GROWSUP",
#ifndef PROT_GROWSUP
#define PROT_GROWSUP 0x02000000
#endif
[ilog2(0x1) + 1] = "READ",
#ifndef PROT_READ
#define PROT_READ 0x1
#endif
[ilog2(0x8) + 1] = "SEM",
#ifndef PROT_SEM
#define PROT_SEM 0x8
#endif
[ilog2(0x2) + 1] = "WRITE",
#ifndef PROT_WRITE
#define PROT_WRITE 0x2
#endif
};
$
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/io_uring/liburing.h')
0 files changed, 0 insertions, 0 deletions