]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/netfilter/nf_conntrack_helper.c
netfilter: netns nf_conntrack: per-netns expectations
[karo-tx-linux.git] / net / netfilter / nf_conntrack_helper.c
index 7d1b11703741e97e3de24c20220b5091bbbd30db..c793db810cd527c42284fbc1738943fd7462e4c7 100644 (file)
@@ -20,6 +20,7 @@
 #include <linux/err.h>
 #include <linux/kernel.h>
 #include <linux/netdevice.h>
+#include <linux/rculist.h>
 
 #include <net/netfilter/nf_conntrack.h>
 #include <net/netfilter/nf_conntrack_l3proto.h>
@@ -144,7 +145,7 @@ void nf_conntrack_helper_unregister(struct nf_conntrack_helper *me)
        /* Get rid of expectations */
        for (i = 0; i < nf_ct_expect_hsize; i++) {
                hlist_for_each_entry_safe(exp, n, next,
-                                         &nf_ct_expect_hash[i], hnode) {
+                                         &init_net.ct.expect_hash[i], hnode) {
                        struct nf_conn_help *help = nfct_help(exp->master);
                        if ((help->helper == me || exp->helper == me) &&
                            del_timer(&exp->timeout)) {
@@ -158,7 +159,7 @@ void nf_conntrack_helper_unregister(struct nf_conntrack_helper *me)
        hlist_for_each_entry(h, n, &unconfirmed, hnode)
                unhelp(h, me);
        for (i = 0; i < nf_conntrack_htable_size; i++) {
-               hlist_for_each_entry(h, n, &nf_conntrack_hash[i], hnode)
+               hlist_for_each_entry(h, n, &init_net.ct.hash[i], hnode)
                        unhelp(h, me);
        }
        spin_unlock_bh(&nf_conntrack_lock);