aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/ip6_tunnel.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv6/ip6_tunnel.c')
-rw-r--r--net/ipv6/ip6_tunnel.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/net/ipv6/ip6_tunnel.c b/net/ipv6/ip6_tunnel.c
index 8d7c9867a445..02894216a46d 100644
--- a/net/ipv6/ip6_tunnel.c
+++ b/net/ipv6/ip6_tunnel.c
@@ -29,7 +29,6 @@
29#include <linux/if.h> 29#include <linux/if.h>
30#include <linux/in.h> 30#include <linux/in.h>
31#include <linux/ip.h> 31#include <linux/ip.h>
32#include <linux/if_tunnel.h>
33#include <linux/net.h> 32#include <linux/net.h>
34#include <linux/in6.h> 33#include <linux/in6.h>
35#include <linux/netdevice.h> 34#include <linux/netdevice.h>
@@ -102,11 +101,12 @@ struct ip6_tnl_net {
102 101
103static struct net_device_stats *ip6_get_stats(struct net_device *dev) 102static struct net_device_stats *ip6_get_stats(struct net_device *dev)
104{ 103{
105 struct pcpu_tstats sum = { 0 }; 104 struct pcpu_sw_netstats sum = { 0 };
106 int i; 105 int i;
107 106
108 for_each_possible_cpu(i) { 107 for_each_possible_cpu(i) {
109 const struct pcpu_tstats *tstats = per_cpu_ptr(dev->tstats, i); 108 const struct pcpu_sw_netstats *tstats =
109 per_cpu_ptr(dev->tstats, i);
110 110
111 sum.rx_packets += tstats->rx_packets; 111 sum.rx_packets += tstats->rx_packets;
112 sum.rx_bytes += tstats->rx_bytes; 112 sum.rx_bytes += tstats->rx_bytes;
@@ -784,7 +784,7 @@ static int ip6_tnl_rcv(struct sk_buff *skb, __u16 protocol,
784 784
785 if ((t = ip6_tnl_lookup(dev_net(skb->dev), &ipv6h->saddr, 785 if ((t = ip6_tnl_lookup(dev_net(skb->dev), &ipv6h->saddr,
786 &ipv6h->daddr)) != NULL) { 786 &ipv6h->daddr)) != NULL) {
787 struct pcpu_tstats *tstats; 787 struct pcpu_sw_netstats *tstats;
788 788
789 if (t->parms.proto != ipproto && t->parms.proto != 0) { 789 if (t->parms.proto != ipproto && t->parms.proto != 0) {
790 rcu_read_unlock(); 790 rcu_read_unlock();
@@ -1497,12 +1497,12 @@ ip6_tnl_dev_init_gen(struct net_device *dev)
1497 1497
1498 t->dev = dev; 1498 t->dev = dev;
1499 t->net = dev_net(dev); 1499 t->net = dev_net(dev);
1500 dev->tstats = alloc_percpu(struct pcpu_tstats); 1500 dev->tstats = alloc_percpu(struct pcpu_sw_netstats);
1501 if (!dev->tstats) 1501 if (!dev->tstats)
1502 return -ENOMEM; 1502 return -ENOMEM;
1503 1503
1504 for_each_possible_cpu(i) { 1504 for_each_possible_cpu(i) {
1505 struct pcpu_tstats *ip6_tnl_stats; 1505 struct pcpu_sw_netstats *ip6_tnl_stats;
1506 ip6_tnl_stats = per_cpu_ptr(dev->tstats, i); 1506 ip6_tnl_stats = per_cpu_ptr(dev->tstats, i);
1507 u64_stats_init(&ip6_tnl_stats->syncp); 1507 u64_stats_init(&ip6_tnl_stats->syncp);
1508 } 1508 }