diff options
author | Andrii Nakryiko <[email protected]> | 2023-06-13 15:35:30 -0700 |
---|---|---|
committer | Daniel Borkmann <[email protected]> | 2023-06-19 14:04:04 +0200 |
commit | 1d28635abcf1914425d6516e641978011984c58a (patch) | |
tree | 61f1f7064c102c9d9d493f61484e9405845b213b /tools/perf/scripts/python/flamegraph.py | |
parent | ab5d47bd41b1db82c295b0e751e2b822b43a4b5a (diff) |
bpf: Move unprivileged checks into map_create() and bpf_prog_load()
Make each bpf() syscall command a bit more self-contained, making it
easier to further enhance it. We move sysctl_unprivileged_bpf_disabled
handling down to map_create() and bpf_prog_load(), two special commands
in this regard.
Also swap the order of checks, calling bpf_capable() only if
sysctl_unprivileged_bpf_disabled is true, avoiding unnecessary audit
messages.
Signed-off-by: Andrii Nakryiko <[email protected]>
Signed-off-by: Daniel Borkmann <[email protected]>
Acked-by: Stanislav Fomichev <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions