diff options
author | David Vernet <[email protected]> | 2024-07-24 22:22:14 -0500 |
---|---|---|
committer | Andrii Nakryiko <[email protected]> | 2024-07-29 15:05:09 -0700 |
commit | ba71ffb660e4d41fe589f2459fb888ea61fdb310 (patch) | |
tree | d575fcb4a546bb50bdab67ca6cd772b8bf648c0c /tools/testing/selftests/bpf/prog_tests/autoload.c | |
parent | 41b01a0271fd0387171eb9ad4692c22e37c8c80a (diff) |
selftests/bpf: Load struct_ops map in global_maps_resize test
In prog_tests/test_global_maps_resize.c, we test various use cases for
resizing global maps. Commit 7244100e0389 ("libbpf: Don't take direct
pointers into BTF data from st_ops") updated libbpf to not store pointers
to volatile BTF data, which for some users, was causing a UAF when resizing
a datasec array.
Let's ensure we have coverage for resizing datasec arrays with struct_ops
progs by also including a struct_ops map and struct_ops prog in the
test_global_map_resize skeleton. The map is automatically loaded, so we
don't need to do anything other than add it to the BPF prog being tested
to get the coverage.
Signed-off-by: David Vernet <[email protected]>
Signed-off-by: Andrii Nakryiko <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/autoload.c')
0 files changed, 0 insertions, 0 deletions