OSDN Git Service

selftests/bpf: Move vxlan tunnel testcases to test_progs
authorKaixi Fan <fankaixi.li@bytedance.com>
Sat, 30 Apr 2022 07:48:43 +0000 (15:48 +0800)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 10 May 2022 17:49:03 +0000 (10:49 -0700)
commit1ee7efd40abf3ab01e67ff4be15d4385d5fa52c1
tree2c9b1e5da6b6348b4eede87ff0e37c92589a15e9
parent26101f5ab6bdf30ac25c8e578e0b4873e7849e0c
selftests/bpf: Move vxlan tunnel testcases to test_progs

Move vxlan tunnel testcases from test_tunnel.sh to test_progs.
And add vxlan tunnel source testcases also. Other tunnel testcases
will be moved to test_progs step by step in the future.
Rename bpf program section name as SEC("tc") because test_progs
bpf loader could not load sections with name SEC("gre_set_tunnel").
Because of this, add bpftool to load bpf programs in test_tunnel.sh.

Signed-off-by: Kaixi Fan <fankaixi.li@bytedance.com>
Link: https://lore.kernel.org/r/20220430074844.69214-3-fankaixi.li@bytedance.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/prog_tests/test_tunnel.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/test_tunnel_kern.c
tools/testing/selftests/bpf/test_tunnel.sh