]> www.infradead.org Git - users/jedix/linux-maple.git/commit
selftests/bpf: Optionally select broadcasting flags
authorBastien Curutchet (eBPF Foundation) <bastien.curutchet@bootlin.com>
Wed, 12 Feb 2025 11:11:11 +0000 (12:11 +0100)
committerMartin KaFai Lau <martin.lau@kernel.org>
Tue, 18 Feb 2025 21:56:34 +0000 (13:56 -0800)
commit09c8bb1fae150573d5fbb2e4c2cb8d5342eb52f6
treed97128f249fbf276926e7a62b88b53871955331c
parent19a9484c1bbc4ccbe7cc69ec1995fec91bc0bdb6
selftests/bpf: Optionally select broadcasting flags

Broadcasting flags are hardcoded for each kind for protocol.

Create a redirect_flags map that allows to select the broadcasting flags
to use in the bpf_redirect_map(). The protocol ID is used as a key.
Set the old hardcoded values as default if the map isn't filled by the
BPF caller.

Signed-off-by: Bastien Curutchet (eBPF Foundation) <bastien.curutchet@bootlin.com>
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Acked-by: Stanislav Fomichev <sdf@fomichev.me>
Link: https://patch.msgid.link/20250212-redirect-multi-v5-3-fd0d39fca6e6@bootlin.com
tools/testing/selftests/bpf/progs/xdp_redirect_multi_kern.c