Merge branch 'libbpf: further struct_ops fixes and improvements'
Andrii Nakryiko says:
====================
Fix yet another case of mishandling SEC("struct_ops") programs that were
nulled out programmatically through BPF skeleton by the user.
While at it, add some improvements around detecting and reporting errors,
specifically a common case of declaring SEC("struct_ops") program, but
forgetting to actually make use of it by setting it as a callback
implementation in SEC(".struct_ops") variable (i.e., map) declaration.
A bunch of new selftests are added as well.
====================
Signed-off-by:
Martin KaFai Lau <martin.lau@kernel.org>
No related branches found
No related tags found
Showing
- tools/lib/bpf/libbpf.c 26 additions, 12 deletionstools/lib/bpf/libbpf.c
- tools/lib/bpf/str_error.c 14 additions, 2 deletionstools/lib/bpf/str_error.c
- tools/testing/selftests/bpf/prog_tests/test_struct_ops_module.c 75 additions, 3 deletions...testing/selftests/bpf/prog_tests/test_struct_ops_module.c
- tools/testing/selftests/bpf/progs/struct_ops_forgotten_cb.c 19 additions, 0 deletionstools/testing/selftests/bpf/progs/struct_ops_forgotten_cb.c
- tools/testing/selftests/bpf/progs/struct_ops_nulled_out_cb.c 22 additions, 0 deletionstools/testing/selftests/bpf/progs/struct_ops_nulled_out_cb.c
Loading
Please register or sign in to comment