summaryrefslogtreecommitdiffstats
path: root/net/sched/sch_htb.c
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2015-08-18 10:30:49 +0200
committerDavid S. Miller <davem@davemloft.net>2015-08-18 11:55:08 -0700
commit348e3435cbefa815bd56a5205c1412b5afe7b92e (patch)
tree018c84769b8c270f6bec9020da36e9916985a061 /net/sched/sch_htb.c
parent906470c19da771e638e7c8e16e16c31995b139cc (diff)
downloadlinux-0-day-348e3435cbefa815bd56a5205c1412b5afe7b92e.tar.gz
linux-0-day-348e3435cbefa815bd56a5205c1412b5afe7b92e.tar.xz
net: sched: drop all special handling of tx_queue_len == 0
Those were all workarounds for the formerly double meaning of tx_queue_len, which broke scheduling algorithms if untreated. Now that all in-tree drivers have been converted away from setting tx_queue_len = 0, it should be safe to drop these workarounds for categorically broken setups. Signed-off-by: Phil Sutter <phil@nwl.cc> Cc: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_htb.c')
-rw-r--r--net/sched/sch_htb.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/sched/sch_htb.c b/net/sched/sch_htb.c
index f1acb0f60dc35..cf4b0f865d1bc 100644
--- a/net/sched/sch_htb.c
+++ b/net/sched/sch_htb.c
@@ -1048,11 +1048,9 @@ static int htb_init(struct Qdisc *sch, struct nlattr *opt)
if (tb[TCA_HTB_DIRECT_QLEN])
q->direct_qlen = nla_get_u32(tb[TCA_HTB_DIRECT_QLEN]);
- else {
+ else
q->direct_qlen = qdisc_dev(sch)->tx_queue_len;
- if (q->direct_qlen < 2) /* some devices have zero tx_queue_len */
- q->direct_qlen = 2;
- }
+
if ((q->rate2quantum = gopt->rate2quantum) < 1)
q->rate2quantum = 1;
q->defcls = gopt->defcls;