diff options
author | Andrii Nakryiko <andrii@kernel.org> | 2024-01-24 03:21:05 +0100 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2024-01-25 01:21:01 +0100 |
commit | d79a3549754725bb90e58104417449edddf3da3d (patch) | |
tree | dbcb8b033e1d9bc85127d229aa6d7bd3b933e356 /kernel/bpf/arraymap.c | |
parent | bpf: Take into account BPF token when fetching helper protos (diff) | |
download | linux-d79a3549754725bb90e58104417449edddf3da3d.tar.xz linux-d79a3549754725bb90e58104417449edddf3da3d.zip |
bpf: Consistently use BPF token throughout BPF verifier logic
Remove remaining direct queries to perfmon_capable() and bpf_capable()
in BPF verifier logic and instead use BPF token (if available) to make
decisions about privileges.
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20240124022127.2379740-9-andrii@kernel.org
Diffstat (limited to 'kernel/bpf/arraymap.c')
-rw-r--r-- | kernel/bpf/arraymap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/bpf/arraymap.c b/kernel/bpf/arraymap.c index 0bdbbbeab155..13358675ff2e 100644 --- a/kernel/bpf/arraymap.c +++ b/kernel/bpf/arraymap.c @@ -82,7 +82,7 @@ static struct bpf_map *array_map_alloc(union bpf_attr *attr) bool percpu = attr->map_type == BPF_MAP_TYPE_PERCPU_ARRAY; int numa_node = bpf_map_attr_numa_node(attr); u32 elem_size, index_mask, max_entries; - bool bypass_spec_v1 = bpf_bypass_spec_v1(); + bool bypass_spec_v1 = bpf_bypass_spec_v1(NULL); u64 array_size, mask64; struct bpf_array *array; |