samples: bpf: Convert xdp_redirect to XDP samples helper
authorKumar Kartikeya Dwivedi <memxor@gmail.com>
Sat, 21 Aug 2021 00:20:04 +0000 (05:50 +0530)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 24 Aug 2021 21:48:42 +0000 (14:48 -0700)
commitb926c55d856cbe2593c44e783b31e2cdb0ef6371
tree9265e21b7c201c2ee4372154858f0cc96038648e
parent66fc4ca85d910bdeecf019c3999bc2df7c80b726
samples: bpf: Convert xdp_redirect to XDP samples helper

Use the libbpf skeleton facility and other utilities provided by XDP
samples helper.

One important note:
The XDP samples helper handles ownership of installed XDP programs on
devices, including responding to SIGINT and SIGTERM, so drop the code
here and use the helpers we provide going forward for all xdp_redirect*
conversions.

Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20210821002010.845777-17-memxor@gmail.com
samples/bpf/Makefile
samples/bpf/xdp_redirect_user.c