]> www.infradead.org Git - users/jedix/linux-maple.git/commit
selftests/bpf: Test attaching a bpf qdisc with incomplete operators
authorAmery Hung <ameryhung@gmail.com>
Fri, 2 May 2025 20:16:23 +0000 (13:16 -0700)
committerMartin KaFai Lau <martin.lau@kernel.org>
Fri, 2 May 2025 22:42:48 +0000 (15:42 -0700)
commit6cda0e2c4760695123dad2af3328e1cfb4f3f540
treee9f34ac2d93ff33c8dd0249c97e9520947163567
parent64d6e3b9df1b12e35181e886d771d8920118e742
selftests/bpf: Test attaching a bpf qdisc with incomplete operators

Implement .destroy in bpf_fq and bpf_fifo as it is now mandatory.

Test attaching a bpf qdisc with a missing operator .init. This is not
allowed as bpf qdisc qdisc_watchdog_cancel() could have been called with
an uninitialized timer.

Signed-off-by: Amery Hung <ameryhung@gmail.com>
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
tools/testing/selftests/bpf/prog_tests/bpf_qdisc.c
tools/testing/selftests/bpf/progs/bpf_qdisc_fail__incompl_ops.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/bpf_qdisc_fifo.c
tools/testing/selftests/bpf/progs/bpf_qdisc_fq.c