aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/sch_generic.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/sch_generic.h')
-rw-r--r--include/net/sch_generic.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h
index d531baa2506a..16626a04cb03 100644
--- a/include/net/sch_generic.h
+++ b/include/net/sch_generic.h
@@ -472,7 +472,6 @@ static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch,
472{ 472{
473 __skb_queue_tail(list, skb); 473 __skb_queue_tail(list, skb);
474 sch->qstats.backlog += qdisc_pkt_len(skb); 474 sch->qstats.backlog += qdisc_pkt_len(skb);
475 qdisc_bstats_update(sch, skb);
476 475
477 return NET_XMIT_SUCCESS; 476 return NET_XMIT_SUCCESS;
478} 477}
@@ -487,8 +486,10 @@ static inline struct sk_buff *__qdisc_dequeue_head(struct Qdisc *sch,
487{ 486{
488 struct sk_buff *skb = __skb_dequeue(list); 487 struct sk_buff *skb = __skb_dequeue(list);
489 488
490 if (likely(skb != NULL)) 489 if (likely(skb != NULL)) {
491 sch->qstats.backlog -= qdisc_pkt_len(skb); 490 sch->qstats.backlog -= qdisc_pkt_len(skb);
491 qdisc_bstats_update(sch, skb);
492 }
492 493
493 return skb; 494 return skb;
494} 495}
@@ -501,10 +502,11 @@ static inline struct sk_buff *qdisc_dequeue_head(struct Qdisc *sch)
501static inline unsigned int __qdisc_queue_drop_head(struct Qdisc *sch, 502static inline unsigned int __qdisc_queue_drop_head(struct Qdisc *sch,
502 struct sk_buff_head *list) 503 struct sk_buff_head *list)
503{ 504{
504 struct sk_buff *skb = __qdisc_dequeue_head(sch, list); 505 struct sk_buff *skb = __skb_dequeue(list);
505 506
506 if (likely(skb != NULL)) { 507 if (likely(skb != NULL)) {
507 unsigned int len = qdisc_pkt_len(skb); 508 unsigned int len = qdisc_pkt_len(skb);
509 sch->qstats.backlog -= len;
508 kfree_skb(skb); 510 kfree_skb(skb);
509 return len; 511 return len;
510 } 512 }