From f1f13b95aa50a6d52ced31fd6bebfbbe757e4f69 Mon Sep 17 00:00:00 2001 From: Vincent Li Date: Thu, 19 Jun 2025 19:22:50 -0700 Subject: [PATCH] dnsdist: change the xsk v4/v6 destination map name We use xdp-loader to load dnsdist_xdp.bpf.o for dnsdist running AF_XDP: xdp-loader load green0 -P 90 -p /sys/fs/bpf/dnsdist -n xdp_dns_filter /usr/lib/bpf/dnsdist_xdp.bpf.o so the xsk v4/v6 destination map would be: /sys/fs/bpf/dnsdist/xskDestinationsV4 /sys/fs/bpf/dnsdist/xskDestinationsV6 but dnsdist-xsk.cc has: static std::string getDestinationMap(bool isV6) { return !isV6 ? "/sys/fs/bpf/dnsdist/xsk-destinations-v4" : "/sys/fs/bpf/dnsdist/xsk-destinations-v6"; } we can't use xsk-destinations-v4/v6 in dnsdist_xdp.bpf.o because bpf map could not use '-' in map definition, '-' would result in compiling error. so we patch dnsdist-xsk.cc to use xskDestinationsV4/V6 that matches the map name in dnsdist_xdp.bpf.o Signed-off-by: Vincent Li --- lfs/dnsdist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lfs/dnsdist b/lfs/dnsdist index 49c2d4143..3470bd0fd 100644 --- a/lfs/dnsdist +++ b/lfs/dnsdist @@ -50,7 +50,7 @@ objects = $(DL_FILE) $(DL_FILE) = $(DL_FROM)/$(DL_FILE) -$(DL_FILE)_BLAKE2 = ea66ca17ef66ecc64fd3a7379b22c2b0448c2a41f325e574a4edb20dfe408315be84a407b78f30a441479fbbcba31a28da2e310c275877739918ad3f9870acd1 +$(DL_FILE)_BLAKE2 = 4490a6faf11b6b7e48fc821be37d0cee1ad93455ec09dadc61e236704bb743d8e5189d085352c775d19933934230e1c5b68ed233b7de7c5cb196f7da4dc16719 install : $(TARGET)