summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorCody P Schafer <cody@linux.vnet.ibm.com>2013-11-13 10:30:35 +0100
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>2013-11-13 10:50:36 +0100
commit04ca6d3715d42277ef001f5a5252cd015d84279b (patch)
treead9ef98667d0000304b43032e3ee92744fa05bdf /configure.ac
parentea39db5d0778ced5bbed902c2b62abe5e7ee8c39 (diff)
net ipset: use rbtree postorder iteration instead of opencoding
Use rbtree_postorder_for_each_entry_safe() to destroy the rbtree instead of opencoding an alternate postorder iteration that modifies the tree Signed-off-by: Cody P Schafer <cody@linux.vnet.ibm.com> Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac10
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 228000b..b886778 100644
--- a/configure.ac
+++ b/configure.ac
@@ -313,6 +313,16 @@ else
AC_SUBST(HAVE_USER_NS_IN_STRUCT_NET, undef)
fi
+AC_MSG_CHECKING([kernel source for rbtree_postorder_for_each_entry_safe])
+if test -f $ksourcedir/include/linux/rbtree.h && \
+ $GREP -q 'rbtree_postorder_for_each_entry_safe' $ksourcedir/include/linux/rbtree.h; then
+ AC_MSG_RESULT(yes)
+ AC_SUBST(HAVE_RBTREE_POSTORDER_FOR_EACH_ENTRY_SAFE, define)
+else
+ AC_MSG_RESULT(no)
+ AC_SUBST(HAVE_RBTREE_POSTORDER_FOR_EACH_ENTRY_SAFE, 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