]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
selftests, xsk: Rename AF_XDP testing app
authorMaciej Fijalkowski <maciej.fijalkowski@intel.com>
Thu, 7 Jul 2022 11:16:12 +0000 (13:16 +0200)
committerDaniel Borkmann <daniel@iogearbox.net>
Fri, 8 Jul 2022 12:22:15 +0000 (14:22 +0200)
Recently, xsk part of libbpf was moved to selftests/bpf directory and
lives on its own because there is an AF_XDP testing application that
needs it called xdpxceiver. That name makes it a bit hard to indicate
who maintains it as there are other XDP samples in there, whereas this
one is strictly about AF_XDP.

Do s/xdpxceiver/xskxceiver so that it will be easier to figure out who
maintains it. A follow-up patch will correct MAINTAINERS file.

Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20220707111613.49031-2-maciej.fijalkowski@intel.com
tools/testing/selftests/bpf/.gitignore
tools/testing/selftests/bpf/Makefile
tools/testing/selftests/bpf/test_xsk.sh
tools/testing/selftests/bpf/xsk_prereqs.sh
tools/testing/selftests/bpf/xskxceiver.c [moved from tools/testing/selftests/bpf/xdpxceiver.c with 99% similarity]
tools/testing/selftests/bpf/xskxceiver.h [moved from tools/testing/selftests/bpf/xdpxceiver.h with 98% similarity]

index ca2f47f45670d11ff6731289686a0ad58c1f3255..3a8cb2404ea6e5a5f9fc139236c7d16a412018d0 100644 (file)
@@ -41,6 +41,6 @@ test_cpp
 /bench
 *.ko
 *.tmp
-xdpxceiver
+xskxceiver
 xdp_redirect_multi
 xdp_synproxy
index dfaac97222af15d2c32a6295a0e13bd763c34cc4..8d59ec7f4c2d061803adc1a609f0ae11c14c8a34 100644 (file)
@@ -82,7 +82,7 @@ TEST_PROGS_EXTENDED := with_addr.sh \
 TEST_GEN_PROGS_EXTENDED = test_sock_addr test_skb_cgroup_id_user \
        flow_dissector_load test_flow_dissector test_tcp_check_syncookie_user \
        test_lirc_mode2_user xdping test_cpp runqslower bench bpf_testmod.ko \
-       xdpxceiver xdp_redirect_multi xdp_synproxy
+       xskxceiver xdp_redirect_multi xdp_synproxy
 
 TEST_CUSTOM_PROGS = $(OUTPUT)/urandom_read
 
@@ -231,7 +231,7 @@ $(OUTPUT)/flow_dissector_load: $(TESTING_HELPERS)
 $(OUTPUT)/test_maps: $(TESTING_HELPERS)
 $(OUTPUT)/test_verifier: $(TESTING_HELPERS) $(CAP_HELPERS)
 $(OUTPUT)/xsk.o: $(BPFOBJ)
-$(OUTPUT)/xdpxceiver: $(OUTPUT)/xsk.o
+$(OUTPUT)/xskxceiver: $(OUTPUT)/xsk.o
 
 BPFTOOL ?= $(DEFAULT_BPFTOOL)
 $(DEFAULT_BPFTOOL): $(wildcard $(BPFTOOLDIR)/*.[ch] $(BPFTOOLDIR)/Makefile)    \
index 56750029923185763a257f5ee3fb3f2f02457417..096a957594cdf7ce7572c9ddbc0445d70664a09c 100755 (executable)
@@ -47,7 +47,7 @@
 #       conflict with any existing interface
 #   * tests the veth and xsk layers of the topology
 #
-# See the source xdpxceiver.c for information on each test
+# See the source xskxceiver.c for information on each test
 #
 # Kernel configuration:
 # ---------------------
@@ -160,14 +160,14 @@ statusList=()
 
 TEST_NAME="XSK_SELFTESTS_SOFTIRQ"
 
-execxdpxceiver
+exec_xskxceiver
 
 cleanup_exit ${VETH0} ${VETH1} ${NS1}
 TEST_NAME="XSK_SELFTESTS_BUSY_POLL"
 busy_poll=1
 
 setup_vethPairs
-execxdpxceiver
+exec_xskxceiver
 
 ## END TESTS
 
index 684e813803eccb354ae93f957eed76ad04ed95fe..a0b71723a8181851b959ea5b12589107c7c40fd3 100755 (executable)
@@ -8,7 +8,7 @@ ksft_xfail=2
 ksft_xpass=3
 ksft_skip=4
 
-XSKOBJ=xdpxceiver
+XSKOBJ=xskxceiver
 
 validate_root_exec()
 {
@@ -77,7 +77,7 @@ validate_ip_utility()
        [ ! $(type -P ip) ] && { echo "'ip' not found. Skipping tests."; test_exit $ksft_skip; }
 }
 
-execxdpxceiver()
+exec_xskxceiver()
 {
         if [[ $busy_poll -eq 1 ]]; then
                ARGS+="-b "
similarity index 99%
rename from tools/testing/selftests/bpf/xdpxceiver.c
rename to tools/testing/selftests/bpf/xskxceiver.c
index 4c425a43e5b00e62c35749dc9f8edb368071e0a3..74d56d971bafc1e34a5e4ca846668334694a2099 100644 (file)
 #include <unistd.h>
 #include <stdatomic.h>
 #include "xsk.h"
-#include "xdpxceiver.h"
+#include "xskxceiver.h"
 #include "../kselftest.h"
 
 /* AF_XDP APIs were moved into libxdp and marked as deprecated in libbpf.
- * Until xdpxceiver is either moved or re-writed into libxdp, suppress
+ * Until xskxceiver is either moved or re-writed into libxdp, suppress
  * deprecation warnings in this file
  */
 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
similarity index 98%
rename from tools/testing/selftests/bpf/xdpxceiver.h
rename to tools/testing/selftests/bpf/xskxceiver.h
index 8f672b0fe0e1dcabfb7f977e97b031c3992cc11b..3d17053f98e53ccb5296a08423d44257e6496976 100644 (file)
@@ -2,8 +2,8 @@
  * Copyright(c) 2020 Intel Corporation.
  */
 
-#ifndef XDPXCEIVER_H_
-#define XDPXCEIVER_H_
+#ifndef XSKXCEIVER_H_
+#define XSKXCEIVER_H_
 
 #ifndef SOL_XDP
 #define SOL_XDP 283
@@ -169,4 +169,4 @@ pthread_cond_t pacing_cond = PTHREAD_COND_INITIALIZER;
 
 int pkts_in_flight;
 
-#endif                         /* XDPXCEIVER_H */
+#endif                         /* XSKXCEIVER_H_ */