diff options
Diffstat (limited to 'drivers/net/loopback.c')
-rw-r--r-- | drivers/net/loopback.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/loopback.c b/drivers/net/loopback.c index 41b774baac4d..49f6bc036a92 100644 --- a/drivers/net/loopback.c +++ b/drivers/net/loopback.c | |||
@@ -153,7 +153,7 @@ static int loopback_xmit(struct sk_buff *skb, struct net_device *dev) | |||
153 | dev->last_rx = jiffies; | 153 | dev->last_rx = jiffies; |
154 | 154 | ||
155 | /* it's OK to use per_cpu_ptr() because BHs are off */ | 155 | /* it's OK to use per_cpu_ptr() because BHs are off */ |
156 | pcpu_lstats = netdev_priv(dev); | 156 | pcpu_lstats = dev->ml_priv; |
157 | lb_stats = per_cpu_ptr(pcpu_lstats, smp_processor_id()); | 157 | lb_stats = per_cpu_ptr(pcpu_lstats, smp_processor_id()); |
158 | lb_stats->bytes += skb->len; | 158 | lb_stats->bytes += skb->len; |
159 | lb_stats->packets++; | 159 | lb_stats->packets++; |
@@ -171,7 +171,7 @@ static struct net_device_stats *get_stats(struct net_device *dev) | |||
171 | unsigned long packets = 0; | 171 | unsigned long packets = 0; |
172 | int i; | 172 | int i; |
173 | 173 | ||
174 | pcpu_lstats = netdev_priv(dev); | 174 | pcpu_lstats = dev->ml_priv; |
175 | for_each_possible_cpu(i) { | 175 | for_each_possible_cpu(i) { |
176 | const struct pcpu_lstats *lb_stats; | 176 | const struct pcpu_lstats *lb_stats; |
177 | 177 | ||
@@ -207,13 +207,13 @@ static int loopback_dev_init(struct net_device *dev) | |||
207 | if (!lstats) | 207 | if (!lstats) |
208 | return -ENOMEM; | 208 | return -ENOMEM; |
209 | 209 | ||
210 | dev->priv = lstats; | 210 | dev->ml_priv = lstats; |
211 | return 0; | 211 | return 0; |
212 | } | 212 | } |
213 | 213 | ||
214 | static void loopback_dev_free(struct net_device *dev) | 214 | static void loopback_dev_free(struct net_device *dev) |
215 | { | 215 | { |
216 | struct pcpu_lstats *lstats = netdev_priv(dev); | 216 | struct pcpu_lstats *lstats = dev->ml_priv; |
217 | 217 | ||
218 | free_percpu(lstats); | 218 | free_percpu(lstats); |
219 | free_netdev(dev); | 219 | free_netdev(dev); |