]> git.ipfire.org Git - thirdparty/ipset.git/commitdiff
Handle "netfilter: propagate net to nf_bridge_get_physindev" patch
authorJozsef Kadlecsik <kadlec@netfilter.org>
Wed, 22 May 2024 17:55:29 +0000 (19:55 +0200)
committerJozsef Kadlecsik <kadlec@netfilter.org>
Wed, 22 May 2024 17:55:29 +0000 (19:55 +0200)
Handle backward compatibility with regard of the patch.

Signed-off-by: Jozsef Kadlecsik <kadlec@netfilter.org>
configure.ac
kernel/include/linux/netfilter/ipset/ip_set_compat.h.in

index 1e449457f578425e3d005715fe3d18b3fb4436c8..5f1be0e7de9b6fe18ec8274bb89aa16a2eee0f92 100644 (file)
@@ -890,6 +890,16 @@ else
        AC_SUBST(HAVE_GFP_KERNEL_ACCOUNT, undef)
 fi
 
+AC_MSG_CHECKING([kernel source for second arg of nf_bridge_get_physindev() in netfilter_bridge.h])
+if test -f $ksourcedir/include/linux/netfilter_bridge.h && \
+   $GREP 'nf_bridge_get_physindev' $ksourcedir/include/linux/netfilter_bridge.h | $GREP -q ' struct net '; then
+       AC_MSG_RESULT(yes)
+       AC_SUBST(HAVE_NF_BRIDGE_GET_PYSINDEV_NET, define)
+else
+       AC_MSG_RESULT(no)
+       AC_SUBST(HAVE_NF_BRIDGE_GET_PYSINDEV_NET, undef)
+fi
+
 AC_MSG_CHECKING([kernel source for struct net_generic])
 if test -f $ksourcedir/include/net/netns/generic.h && \
    $GREP -q 'struct net_generic' $ksourcedir/include/net/netns/generic.h; then
index 5746f39c168f711ba36e573810c9f08ef36ee46d..8878da9ab9faeb9f1c2a13738dec4b36f86e2665 100644 (file)
@@ -69,6 +69,7 @@
 #@HAVE_NFNL_CALLBACK_TYPE@ HAVE_NFNL_CALLBACK_TYPE
 #@HAVE_EAGAIN_IN_NFNETLINK_UNICAST@ HAVE_EAGAIN_IN_NFNETLINK_UNICAST
 #@HAVE_NLMSG_UNICAST@ HAVE_NLMSG_UNICAST
+#@HAVE_NF_BRIDGE_GET_PYSINDEV_NET@ HAVE_NF_BRIDGE_GET_PYSINDEV_NET
 
 #ifdef HAVE_EXPORT_SYMBOL_GPL_IN_MODULE_H
 #include <linux/module.h>