summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrii Nakryiko <andrii@kernel.org>2021-12-02 02:28:20 +0300
committerAlexei Starovoitov <ast@kernel.org>2021-12-03 02:23:40 +0300
commit00872de6e1b004377f6036f95db43e2145606eb2 (patch)
tree712c8663954c59a2f896453c0c6570a590e2b899
parent045b233a29a2ea3a168296f000cd5b1c08c4a2f7 (diff)
downloadlinux-00872de6e1b004377f6036f95db43e2145606eb2.tar.xz
selftests/bpf: Mute xdpxceiver.c's deprecation warnings
xdpxceiver.c is using AF_XDP APIs that are deprecated starting from libbpf 0.7. Until we migrate the test to libxdp or solve this issue in some other way, mute deprecation warnings within xdpxceiver.c. Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Link: https://lore.kernel.org/bpf/20211201232824.3166325-6-andrii@kernel.org
-rw-r--r--tools/testing/selftests/bpf/xdpxceiver.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/testing/selftests/bpf/xdpxceiver.c b/tools/testing/selftests/bpf/xdpxceiver.c
index 040164c7efc1..0a5d23da486d 100644
--- a/tools/testing/selftests/bpf/xdpxceiver.c
+++ b/tools/testing/selftests/bpf/xdpxceiver.c
@@ -100,6 +100,12 @@
#include "xdpxceiver.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
+ * deprecation warnings in this file
+ */
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
static const char *MAC1 = "\x00\x0A\x56\x9E\xEE\x62";
static const char *MAC2 = "\x00\x0A\x56\x9E\xEE\x61";
static const char *IP1 = "192.168.100.162";