diff options
Diffstat (limited to 'net/ipv6/reassembly.c')
-rw-r--r-- | net/ipv6/reassembly.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/net/ipv6/reassembly.c b/net/ipv6/reassembly.c index 1815ff0cf628..ab2d53b81b70 100644 --- a/net/ipv6/reassembly.c +++ b/net/ipv6/reassembly.c | |||
@@ -234,7 +234,7 @@ out: | |||
234 | } | 234 | } |
235 | 235 | ||
236 | static __inline__ struct frag_queue * | 236 | static __inline__ struct frag_queue * |
237 | fq_find(__be32 id, struct in6_addr *src, struct in6_addr *dst, | 237 | fq_find(struct net *net, __be32 id, struct in6_addr *src, struct in6_addr *dst, |
238 | struct inet6_dev *idev) | 238 | struct inet6_dev *idev) |
239 | { | 239 | { |
240 | struct inet_frag_queue *q; | 240 | struct inet_frag_queue *q; |
@@ -246,7 +246,7 @@ fq_find(__be32 id, struct in6_addr *src, struct in6_addr *dst, | |||
246 | arg.dst = dst; | 246 | arg.dst = dst; |
247 | hash = ip6qhashfn(id, src, dst); | 247 | hash = ip6qhashfn(id, src, dst); |
248 | 248 | ||
249 | q = inet_frag_find(&ip6_frags, &arg, hash); | 249 | q = inet_frag_find(&net->ipv6.frags, &ip6_frags, &arg, hash); |
250 | if (q == NULL) | 250 | if (q == NULL) |
251 | goto oom; | 251 | goto oom; |
252 | 252 | ||
@@ -568,6 +568,7 @@ static int ipv6_frag_rcv(struct sk_buff *skb) | |||
568 | struct frag_hdr *fhdr; | 568 | struct frag_hdr *fhdr; |
569 | struct frag_queue *fq; | 569 | struct frag_queue *fq; |
570 | struct ipv6hdr *hdr = ipv6_hdr(skb); | 570 | struct ipv6hdr *hdr = ipv6_hdr(skb); |
571 | struct net *net; | ||
571 | 572 | ||
572 | IP6_INC_STATS_BH(ip6_dst_idev(skb->dst), IPSTATS_MIB_REASMREQDS); | 573 | IP6_INC_STATS_BH(ip6_dst_idev(skb->dst), IPSTATS_MIB_REASMREQDS); |
573 | 574 | ||
@@ -598,10 +599,11 @@ static int ipv6_frag_rcv(struct sk_buff *skb) | |||
598 | return 1; | 599 | return 1; |
599 | } | 600 | } |
600 | 601 | ||
602 | net = skb->dev->nd_net; | ||
601 | if (atomic_read(&ip6_frags.mem) > init_net.ipv6.sysctl.frags.high_thresh) | 603 | if (atomic_read(&ip6_frags.mem) > init_net.ipv6.sysctl.frags.high_thresh) |
602 | ip6_evictor(ip6_dst_idev(skb->dst)); | 604 | ip6_evictor(ip6_dst_idev(skb->dst)); |
603 | 605 | ||
604 | if ((fq = fq_find(fhdr->identification, &hdr->saddr, &hdr->daddr, | 606 | if ((fq = fq_find(net, fhdr->identification, &hdr->saddr, &hdr->daddr, |
605 | ip6_dst_idev(skb->dst))) != NULL) { | 607 | ip6_dst_idev(skb->dst))) != NULL) { |
606 | int ret; | 608 | int ret; |
607 | 609 | ||