]> granicus.if.org Git - ipset/commitdiff
Add compatibility support for async in pernet_operations.
authorJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Mon, 22 Oct 2018 18:47:35 +0000 (20:47 +0200)
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Mon, 22 Oct 2018 18:47:35 +0000 (20:47 +0200)
configure.ac
kernel/include/linux/netfilter/ipset/ip_set_compat.h.in

index 7d0fa0198fdc8a31bd39731f2cf88d17857ca0c5..1532997d8d02b1ae62233a987a9ad0b266c33c73 100644 (file)
@@ -363,6 +363,16 @@ else
        AC_SUBST(HAVE_NET_OPS_ID, undef)
 fi
 
+AC_MSG_CHECKING([kernel source for async in struct pernet_operations])
+if test -f $ksourcedir/include/net/net_namespace.h && \
+   $AWK '/^struct pernet_operations /,/^}/' $ksourcedir/include/net/net_namespace.h | $GREP -q 'bool async;'; then
+       AC_MSG_RESULT(yes)
+       AC_SUBST(HAVE_NET_OPS_ASYNC, define)
+else
+       AC_MSG_RESULT(no)
+       AC_SUBST(HAVE_NET_OPS_ASYNC, undef)
+fi
+
 AC_MSG_CHECKING([kernel source for user_ns in struct net])
 if test -f $ksourcedir/include/net/net_namespace.h && \
    $AWK '/^struct net \{/,/^}/' $ksourcedir/include/net/net_namespace.h | $GREP -q 'user_ns'; then
index 53bd588762b156072dcdc3633bd3ef7915a8acd4..b93d662eea0a0f1fa2f1e594b8134e61187f7d1f 100644 (file)
@@ -21,6 +21,7 @@
 #@HAVE_CHECKENTRY_BOOL@ HAVE_CHECKENTRY_BOOL
 #@HAVE_XT_TARGET_PARAM@ HAVE_XT_TARGET_PARAM
 #@HAVE_NET_OPS_ID@ HAVE_NET_OPS_ID
+#@HAVE_NET_OPS_ASYNC@ HAVE_NET_OPS_ASYNC
 #@HAVE_USER_NS_IN_STRUCT_NET@ HAVE_USER_NS_IN_STRUCT_NET
 #@HAVE_RBTREE_POSTORDER_FOR_EACH_ENTRY_SAFE@ HAVE_RBTREE_POSTORDER_FOR_EACH_ENTRY_SAFE
 #@HAVE_KVCALLOC@ HAVE_KVCALLOC