diff options
author | David S. Miller <davem@davemloft.net> | 2016-06-10 14:52:24 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-06-10 14:52:24 -0400 |
commit | 1578b0a5e92825334760741e5c166b8873886f1b (patch) | |
tree | ac8299191f37990111f7d4b615601f4356e24fea /net/sched/sch_hfsc.c | |
parent | 3d5479e92087f6249231e26a2d7327e86a8d0dfc (diff) | |
parent | 698ea54dde6768d4a96080d0fb796cb3a4eadaf8 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
net/sched/act_police.c
net/sched/sch_drr.c
net/sched/sch_hfsc.c
net/sched/sch_prio.c
net/sched/sch_red.c
net/sched/sch_tbf.c
In net-next the drop methods of the packet schedulers got removed, so
the bug fixes to them in 'net' are irrelevant.
A packet action unload crash fix conflicts with the addition of the
new firstuse timestamp.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_hfsc.c')
-rw-r--r-- | net/sched/sch_hfsc.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/net/sched/sch_hfsc.c b/net/sched/sch_hfsc.c index 155e3ce81270..eb3d3f5aba80 100644 --- a/net/sched/sch_hfsc.c +++ b/net/sched/sch_hfsc.c | |||
@@ -1529,6 +1529,7 @@ hfsc_reset_qdisc(struct Qdisc *sch) | |||
1529 | q->eligible = RB_ROOT; | 1529 | q->eligible = RB_ROOT; |
1530 | INIT_LIST_HEAD(&q->droplist); | 1530 | INIT_LIST_HEAD(&q->droplist); |
1531 | qdisc_watchdog_cancel(&q->watchdog); | 1531 | qdisc_watchdog_cancel(&q->watchdog); |
1532 | sch->qstats.backlog = 0; | ||
1532 | sch->q.qlen = 0; | 1533 | sch->q.qlen = 0; |
1533 | } | 1534 | } |
1534 | 1535 | ||
@@ -1559,14 +1560,6 @@ hfsc_dump_qdisc(struct Qdisc *sch, struct sk_buff *skb) | |||
1559 | struct hfsc_sched *q = qdisc_priv(sch); | 1560 | struct hfsc_sched *q = qdisc_priv(sch); |
1560 | unsigned char *b = skb_tail_pointer(skb); | 1561 | unsigned char *b = skb_tail_pointer(skb); |
1561 | struct tc_hfsc_qopt qopt; | 1562 | struct tc_hfsc_qopt qopt; |
1562 | struct hfsc_class *cl; | ||
1563 | unsigned int i; | ||
1564 | |||
1565 | sch->qstats.backlog = 0; | ||
1566 | for (i = 0; i < q->clhash.hashsize; i++) { | ||
1567 | hlist_for_each_entry(cl, &q->clhash.hash[i], cl_common.hnode) | ||
1568 | sch->qstats.backlog += cl->qdisc->qstats.backlog; | ||
1569 | } | ||
1570 | 1563 | ||
1571 | qopt.defcls = q->defcls; | 1564 | qopt.defcls = q->defcls; |
1572 | if (nla_put(skb, TCA_OPTIONS, sizeof(qopt), &qopt)) | 1565 | if (nla_put(skb, TCA_OPTIONS, sizeof(qopt), &qopt)) |
@@ -1604,6 +1597,7 @@ hfsc_enqueue(struct sk_buff *skb, struct Qdisc *sch) | |||
1604 | if (cl->qdisc->q.qlen == 1) | 1597 | if (cl->qdisc->q.qlen == 1) |
1605 | set_active(cl, qdisc_pkt_len(skb)); | 1598 | set_active(cl, qdisc_pkt_len(skb)); |
1606 | 1599 | ||
1600 | qdisc_qstats_backlog_inc(sch, skb); | ||
1607 | sch->q.qlen++; | 1601 | sch->q.qlen++; |
1608 | 1602 | ||
1609 | return NET_XMIT_SUCCESS; | 1603 | return NET_XMIT_SUCCESS; |
@@ -1672,6 +1666,7 @@ hfsc_dequeue(struct Qdisc *sch) | |||
1672 | 1666 | ||
1673 | qdisc_unthrottled(sch); | 1667 | qdisc_unthrottled(sch); |
1674 | qdisc_bstats_update(sch, skb); | 1668 | qdisc_bstats_update(sch, skb); |
1669 | qdisc_qstats_backlog_dec(sch, skb); | ||
1675 | sch->q.qlen--; | 1670 | sch->q.qlen--; |
1676 | 1671 | ||
1677 | return skb; | 1672 | return skb; |