Re: [PATCH bpf-next v6 6/7] selftests/bpf: Fix xdp_tx.c prog section name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 5, 2021 at 9:10 AM Jussi Maki <joamaki@xxxxxxxxx> wrote:
>
> The program type cannot be deduced from 'tx' which causes an invalid
> argument error when trying to load xdp_tx.o using the skeleton.
> Rename the section name to "xdp" so that libbpf can deduce the type.
>
> Signed-off-by: Jussi Maki <joamaki@xxxxxxxxx>
> ---

LGTM.

Acked-by: Andrii Nakryiko <andrii@xxxxxxxxxx>

>  tools/testing/selftests/bpf/progs/xdp_tx.c   | 2 +-
>  tools/testing/selftests/bpf/test_xdp_veth.sh | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tools/testing/selftests/bpf/progs/xdp_tx.c b/tools/testing/selftests/bpf/progs/xdp_tx.c
> index 94e6c2b281cb..5f725c720e00 100644
> --- a/tools/testing/selftests/bpf/progs/xdp_tx.c
> +++ b/tools/testing/selftests/bpf/progs/xdp_tx.c
> @@ -3,7 +3,7 @@
>  #include <linux/bpf.h>
>  #include <bpf/bpf_helpers.h>
>
> -SEC("tx")
> +SEC("xdp")
>  int xdp_tx(struct xdp_md *xdp)
>  {
>         return XDP_TX;
> diff --git a/tools/testing/selftests/bpf/test_xdp_veth.sh b/tools/testing/selftests/bpf/test_xdp_veth.sh
> index ba8ffcdaac30..995278e684b6 100755
> --- a/tools/testing/selftests/bpf/test_xdp_veth.sh
> +++ b/tools/testing/selftests/bpf/test_xdp_veth.sh
> @@ -108,7 +108,7 @@ ip link set dev veth2 xdp pinned $BPF_DIR/progs/redirect_map_1
>  ip link set dev veth3 xdp pinned $BPF_DIR/progs/redirect_map_2
>
>  ip -n ns1 link set dev veth11 xdp obj xdp_dummy.o sec xdp_dummy
> -ip -n ns2 link set dev veth22 xdp obj xdp_tx.o sec tx
> +ip -n ns2 link set dev veth22 xdp obj xdp_tx.o sec xdp
>  ip -n ns3 link set dev veth33 xdp obj xdp_dummy.o sec xdp_dummy
>
>  trap cleanup EXIT
> --
> 2.17.1
>



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux