The current fexit and fentry tests rely on a different program to exercise the functions they attach to. Instead of doing this, implement the test operations for tracing which will also be used for BPF_MODIFY_RETURN in a subsequent patch. Also, clean up the fexit test to use the generated skeleton.
Showing the changes to kernel (1 of 6 files). Show all
Unified · Split
| @@ -1266,6 +1266,7 @@ const struct bpf_verifier_ops tracing_verifier_ops = { · 1265 unmodified lines | ||
| 1266 | 1266 | }; |
| 1267 | 1267 | |
| 1268 | 1268 | const struct bpf_prog_ops tracing_prog_ops = { |
| 1269 | + .test_run = bpf_prog_test_run_tracing, | |
| 1269 | 1270 | }; |
| 1270 | 1271 | |
| 1271 | 1272 | static bool raw_tp_writable_prog_is_valid_access(int off, int size, |