Skip to contentSkip to conversation

IPv6:netfilter: defrag:Introduce net namespace to conntrack and share netns_frags with IPv6 stack

RFC PATCH Superseded Shan Wei 2 participants 2 messages Feb 24, 2010

Subsystems (3)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Shan Wei

author
#0 lore raw

RFC PATCH 1/5 IPv6:netfilter: defrag:Introduce net namespace to conntrack and share netns_frags with IPv6 stack

Introduce net namespace to conntrack and share netns_frags with IPv6 stack.

---
 net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c |    7 +-
 net/ipv6/netfilter/nf_conntrack_reasm.c        |   79 +++++++-----------------
 2 files changed, 25 insertions(+), 61 deletions(-)
net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c +3 -4
index 996c3f4..f153b2c 100644
@@ -221,7 +221,10 @@ static unsigned int ipv6_defrag(unsigned int hooknum,
 	if (skb->nfct && !nf_ct_is_template((struct nf_conn *)skb->nfct))
 		return NF_ACCEPT;
 
+	local_bh_disable();
 	reasm = nf_ct_frag6_gather(skb, nf_ct6_defrag_user(hooknum, skb));
+	local_bh_enable();
+
 	/* queued */
 	if (reasm == NULL)
 		return NF_STOLEN;
@@ -387,10 +390,6 @@ struct nf_conntrack_l3proto nf_conntrack_l3proto_ipv6 __read_mostly = {
 	.nlattr_to_tuple	= ipv6_nlattr_to_tuple,
 	.nla_policy		= ipv6_nla_policy,
 #endif
-#ifdef CONFIG_SYSCTL
-	.ctl_table_path		= nf_net_netfilter_sysctl_path,
-	.ctl_table		= nf_ct_ipv6_sysctl_table,
-#endif
 	.me			= THIS_MODULE,
 };
 
net/ipv6/netfilter/nf_conntrack_reasm.c +22 -57

187 lines not on this page · raw message

Signature · 1 line
1.6.3.3 
#1 lore raw
Quoted 13 lines · Shan Wei

Introduce net namespace to conntrack and share netns_frags with IPv6 stack.

---
 net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c |    7 +-
 net/ipv6/netfilter/nf_conntrack_reasm.c        |   79 +++++++-----------------
 2 files changed, 25 insertions(+), 61 deletions(-)
net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c +0 -0
index 996c3f4..f153b2c 100644

net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c static unsigned int ipv6_defrag(unsigned int hooknum, · line 226

Quoted 6 lines
net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c +2 -0
@@ -221,7 +221,10 @@ static unsigned int ipv6_defrag(unsigned int hooknum,
 	if (skb->nfct && !nf_ct_is_template((struct nf_conn *)skb->nfct))
 		return NF_ACCEPT;
 
+	local_bh_disable();
 	reasm = nf_ct_frag6_gather(skb, nf_ct6_defrag_user(hooknum, skb));
+	local_bh_enable();

Please seperate any locking changes from the introduction of network namespaces.