diff options
Diffstat (limited to 'net/sched/sch_hhf.c')
-rw-r--r-- | net/sched/sch_hhf.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/net/sched/sch_hhf.c b/net/sched/sch_hhf.c index edee03d922e2..6e957c3b9854 100644 --- a/net/sched/sch_hhf.c +++ b/net/sched/sch_hhf.c | |||
@@ -553,11 +553,6 @@ static int hhf_change(struct Qdisc *sch, struct nlattr *opt) | |||
553 | if (err < 0) | 553 | if (err < 0) |
554 | return err; | 554 | return err; |
555 | 555 | ||
556 | sch_tree_lock(sch); | ||
557 | |||
558 | if (tb[TCA_HHF_BACKLOG_LIMIT]) | ||
559 | sch->limit = nla_get_u32(tb[TCA_HHF_BACKLOG_LIMIT]); | ||
560 | |||
561 | if (tb[TCA_HHF_QUANTUM]) | 556 | if (tb[TCA_HHF_QUANTUM]) |
562 | new_quantum = nla_get_u32(tb[TCA_HHF_QUANTUM]); | 557 | new_quantum = nla_get_u32(tb[TCA_HHF_QUANTUM]); |
563 | 558 | ||
@@ -567,6 +562,12 @@ static int hhf_change(struct Qdisc *sch, struct nlattr *opt) | |||
567 | non_hh_quantum = (u64)new_quantum * new_hhf_non_hh_weight; | 562 | non_hh_quantum = (u64)new_quantum * new_hhf_non_hh_weight; |
568 | if (non_hh_quantum > INT_MAX) | 563 | if (non_hh_quantum > INT_MAX) |
569 | return -EINVAL; | 564 | return -EINVAL; |
565 | |||
566 | sch_tree_lock(sch); | ||
567 | |||
568 | if (tb[TCA_HHF_BACKLOG_LIMIT]) | ||
569 | sch->limit = nla_get_u32(tb[TCA_HHF_BACKLOG_LIMIT]); | ||
570 | |||
570 | q->quantum = new_quantum; | 571 | q->quantum = new_quantum; |
571 | q->hhf_non_hh_weight = new_hhf_non_hh_weight; | 572 | q->hhf_non_hh_weight = new_hhf_non_hh_weight; |
572 | 573 | ||