samples/bpf: use bpf_set_link_xdp_fd
authorEric Leblond <eric@regit.org>
Tue, 30 Jan 2018 20:55:04 +0000 (21:55 +0100)
committerAlexei Starovoitov <ast@kernel.org>
Sat, 3 Feb 2018 01:53:48 +0000 (17:53 -0800)
commitb259c2ffd9b4812aa42a1d502eabd8c62a32d063
tree83671596b4c2f36d19f38f1312756022c037dbc5
parent6061a3d6720600c976b877c3ac1402b3ef0a8a55
samples/bpf: use bpf_set_link_xdp_fd

Use bpf_set_link_xdp_fd instead of set_link_xdp_fd to remove some
code duplication and benefit of netlink ext ack errors message.

Signed-off-by: Eric Leblond <eric@regit.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
samples/bpf/bpf_load.c
samples/bpf/bpf_load.h
samples/bpf/xdp1_user.c
samples/bpf/xdp_redirect_cpu_user.c
samples/bpf/xdp_redirect_map_user.c
samples/bpf/xdp_redirect_user.c
samples/bpf/xdp_router_ipv4_user.c
samples/bpf/xdp_rxq_info_user.c
samples/bpf/xdp_tx_iptunnel_user.c