aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2008-10-15 01:55:21 -0400
committerDavid S. Miller <davem@davemloft.net>2008-10-15 01:55:21 -0400
commiteef9d90dcde7bb4d029b67ed36457efc4970d5a2 (patch)
treed58bd168acaa39834ff4f6c1ff94fa244fa3bdcc /net
parent4ef079ccc1d934c5f9966f2bfcd5dbbef8f7a0a7 (diff)
netns: correct mib stats in ip6_route_me_harder()
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/ipv6/netfilter.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ipv6/netfilter.c b/net/ipv6/netfilter.c
index 6b29b03925f1..fd5b3a4e3329 100644
--- a/net/ipv6/netfilter.c
+++ b/net/ipv6/netfilter.c
@@ -12,6 +12,7 @@
12 12
13int ip6_route_me_harder(struct sk_buff *skb) 13int ip6_route_me_harder(struct sk_buff *skb)
14{ 14{
15 struct net *net = dev_net(skb->dst->dev);
15 struct ipv6hdr *iph = ipv6_hdr(skb); 16 struct ipv6hdr *iph = ipv6_hdr(skb);
16 struct dst_entry *dst; 17 struct dst_entry *dst;
17 struct flowi fl = { 18 struct flowi fl = {
@@ -23,7 +24,7 @@ int ip6_route_me_harder(struct sk_buff *skb)
23 .saddr = iph->saddr, } }, 24 .saddr = iph->saddr, } },
24 }; 25 };
25 26
26 dst = ip6_route_output(dev_net(skb->dst->dev), skb->sk, &fl); 27 dst = ip6_route_output(net, skb->sk, &fl);
27 28
28#ifdef CONFIG_XFRM 29#ifdef CONFIG_XFRM
29 if (!(IP6CB(skb)->flags & IP6SKB_XFRM_TRANSFORMED) && 30 if (!(IP6CB(skb)->flags & IP6SKB_XFRM_TRANSFORMED) &&
@@ -33,8 +34,7 @@ int ip6_route_me_harder(struct sk_buff *skb)
33#endif 34#endif
34 35
35 if (dst->error) { 36 if (dst->error) {
36 IP6_INC_STATS(&init_net, ip6_dst_idev(dst), 37 IP6_INC_STATS(net, ip6_dst_idev(dst), IPSTATS_MIB_OUTNOROUTES);
37 IPSTATS_MIB_OUTNOROUTES);
38 LIMIT_NETDEBUG(KERN_DEBUG "ip6_route_me_harder: No more route.\n"); 38 LIMIT_NETDEBUG(KERN_DEBUG "ip6_route_me_harder: No more route.\n");
39 dst_release(dst); 39 dst_release(dst);
40 return -EINVAL; 40 return -EINVAL;