]> git.baikalelectronics.ru Git - kernel.git/commit
samples: bpf: Convert xdp_monitor to XDP samples helper
authorKumar Kartikeya Dwivedi <memxor@gmail.com>
Sat, 21 Aug 2021 00:20:02 +0000 (05:50 +0530)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 24 Aug 2021 21:48:41 +0000 (14:48 -0700)
commit248f2cf4bcff5d8965edc6d2b86c1264f2d32c89
treeeee787590ef4dbb51d720afc15053619505580d0
parent1dd172560f9c49f14bc13ad54b55e95d0739e709
samples: bpf: Convert xdp_monitor to XDP samples helper

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

A lot of the code in xdp_monitor and xdp_redirect_cpu has been moved to
the xdp_sample_user.o helper, so we remove the duplicate functions here
that are no longer needed.

Thanks to BPF skeleton, we no longer depend on order of tracepoints to
uninstall them on startup. Instead, the sample mask is used to install
the needed tracepoints.

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-15-memxor@gmail.com
samples/bpf/Makefile
samples/bpf/Makefile.target
samples/bpf/xdp_monitor_user.c