kernel: cake: backport upstream tweaks & fixes
[openwrt/staging/ynezz.git] / target / linux / generic / backport-4.19 / 398-5.8-sch_cake-fix-a-few-style-nits.patch
1 From 3f608f0c41360b11b04c763f348b712f651c8bac Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Toke=20H=C3=B8iland-J=C3=B8rgensen?= <toke@redhat.com>
3 Date: Thu, 25 Jun 2020 22:12:09 +0200
4 Subject: [PATCH] sch_cake: fix a few style nits
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 I spotted a few nits when comparing the in-tree version of sch_cake with
10 the out-of-tree one: A redundant error variable declaration shadowing an
11 outer declaration, and an indentation alignment issue. Fix both of these.
12
13 Fixes: 046f6fd5daef ("sched: Add Common Applications Kept Enhanced (cake) qdisc")
14 Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
15 Signed-off-by: David S. Miller <davem@davemloft.net>
16 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
17 ---
18 net/sched/sch_cake.c | 4 ++--
19 1 file changed, 2 insertions(+), 2 deletions(-)
20
21 --- a/net/sched/sch_cake.c
22 +++ b/net/sched/sch_cake.c
23 @@ -2713,7 +2713,7 @@ static int cake_init(struct Qdisc *sch,
24 qdisc_watchdog_init(&q->watchdog, sch);
25
26 if (opt) {
27 - int err = cake_change(sch, opt, extack);
28 + err = cake_change(sch, opt, extack);
29
30 if (err)
31 return err;
32 @@ -3030,7 +3030,7 @@ static int cake_dump_class_stats(struct
33 PUT_STAT_S32(BLUE_TIMER_US,
34 ktime_to_us(
35 ktime_sub(now,
36 - flow->cvars.blue_timer)));
37 + flow->cvars.blue_timer)));
38 }
39 if (flow->cvars.dropping) {
40 PUT_STAT_S32(DROP_NEXT_US,