diff options
author | David S. Miller <davem@davemloft.net> | 2018-07-29 16:22:13 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-09-10 10:06:52 -0700 |
commit | aea890b8b2e071bb75043353581f2197a2f13160 (patch) | |
tree | b37f76eff482d97d50dc9ecc1a82ca0129eaf58e /net/sched | |
parent | 0153167aebd0808fb90031dba07d4e696557474c (diff) | |
download | linux-aea890b8b2e071bb75043353581f2197a2f13160.tar.gz linux-aea890b8b2e071bb75043353581f2197a2f13160.tar.bz2 linux-aea890b8b2e071bb75043353581f2197a2f13160.zip |
sch_htb: Remove local SKB queue handling code.
Instead, adjust __qdisc_enqueue_tail() such that HTB can use it
instead.
The only other caller of __qdisc_enqueue_tail() is
qdisc_enqueue_tail() so we can move the backlog and return value
handling (which HTB doesn't need/want) to the latter.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched')
-rw-r--r-- | net/sched/sch_htb.c | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/net/sched/sch_htb.c b/net/sched/sch_htb.c index 43c4bfe625a9..cf23829cbede 100644 --- a/net/sched/sch_htb.c +++ b/net/sched/sch_htb.c @@ -577,22 +577,6 @@ static inline void htb_deactivate(struct htb_sched *q, struct htb_class *cl) cl->prio_activity = 0; } -static void htb_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch, - struct qdisc_skb_head *qh) -{ - struct sk_buff *last = qh->tail; - - if (last) { - skb->next = NULL; - last->next = skb; - qh->tail = skb; - } else { - qh->tail = skb; - qh->head = skb; - } - qh->qlen++; -} - static int htb_enqueue(struct sk_buff *skb, struct Qdisc *sch, struct sk_buff **to_free) { @@ -603,7 +587,7 @@ static int htb_enqueue(struct sk_buff *skb, struct Qdisc *sch, if (cl == HTB_DIRECT) { /* enqueue to helper queue */ if (q->direct_queue.qlen < q->direct_qlen) { - htb_enqueue_tail(skb, sch, &q->direct_queue); + __qdisc_enqueue_tail(skb, &q->direct_queue); q->direct_pkts++; } else { return qdisc_drop(skb, sch, to_free); |