OSDN Git Service

sample/bpf: Add xdp_redirect_map_multi for redirect_map broadcast test
authorHangbin Liu <liuhangbin@gmail.com>
Wed, 19 May 2021 09:07:46 +0000 (17:07 +0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 26 May 2021 07:46:16 +0000 (09:46 +0200)
commite48cfe4bbfadd7b88821fe98f625a6b5a6d1cbb4
tree96f402b1b92f739b8722ba375fdb61e3e0a4042d
parente624d4ed4aa8cc3c69d1359b0aaea539203ed266
sample/bpf: Add xdp_redirect_map_multi for redirect_map broadcast test

This is a sample for xdp redirect broadcast. In the sample we could forward
all packets between given interfaces. There is also an option -X that could
enable 2nd xdp_prog on egress interface.

Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Toke Høiland-Jørgensen <toke@redhat.com>
Link: https://lore.kernel.org/bpf/20210519090747.1655268-4-liuhangbin@gmail.com
samples/bpf/Makefile
samples/bpf/xdp_redirect_map_multi_kern.c [new file with mode: 0644]
samples/bpf/xdp_redirect_map_multi_user.c [new file with mode: 0644]