diff options
-rw-r--r-- | net/sched/sch_generic.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index 4626cef4b76e..eeb8276d7a89 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include <linux/rcupdate.h> | 25 | #include <linux/rcupdate.h> |
26 | #include <linux/list.h> | 26 | #include <linux/list.h> |
27 | #include <linux/slab.h> | 27 | #include <linux/slab.h> |
28 | #include <linux/if_vlan.h> | ||
28 | #include <net/sch_generic.h> | 29 | #include <net/sch_generic.h> |
29 | #include <net/pkt_sched.h> | 30 | #include <net/pkt_sched.h> |
30 | #include <net/dst.h> | 31 | #include <net/dst.h> |
@@ -207,15 +208,19 @@ void __qdisc_run(struct Qdisc *q) | |||
207 | 208 | ||
208 | unsigned long dev_trans_start(struct net_device *dev) | 209 | unsigned long dev_trans_start(struct net_device *dev) |
209 | { | 210 | { |
210 | unsigned long val, res = dev->trans_start; | 211 | unsigned long val, res; |
211 | unsigned int i; | 212 | unsigned int i; |
212 | 213 | ||
214 | if (is_vlan_dev(dev)) | ||
215 | dev = vlan_dev_real_dev(dev); | ||
216 | res = dev->trans_start; | ||
213 | for (i = 0; i < dev->num_tx_queues; i++) { | 217 | for (i = 0; i < dev->num_tx_queues; i++) { |
214 | val = netdev_get_tx_queue(dev, i)->trans_start; | 218 | val = netdev_get_tx_queue(dev, i)->trans_start; |
215 | if (val && time_after(val, res)) | 219 | if (val && time_after(val, res)) |
216 | res = val; | 220 | res = val; |
217 | } | 221 | } |
218 | dev->trans_start = res; | 222 | dev->trans_start = res; |
223 | |||
219 | return res; | 224 | return res; |
220 | } | 225 | } |
221 | EXPORT_SYMBOL(dev_trans_start); | 226 | EXPORT_SYMBOL(dev_trans_start); |