Skip to content

Commit

Permalink
BACKPORT: fq_codel: remove set but not used variables 'prev_ecn_mark'…
Browse files Browse the repository at this point in the history
… and 'prev_drop_count'

Fixes gcc '-Wunused-but-set-variable' warning:

net/sched/sch_fq_codel.c: In function fq_codel_dequeue:
net/sched/sch_fq_codel.c:288:23: warning: variable prev_ecn_mark set but not used [-Wunused-but-set-variable]
net/sched/sch_fq_codel.c:288:6: warning: variable prev_drop_count set but not used [-Wunused-but-set-variable]

They are not used since commit 77ddaff218fc ("fq_codel: Kill
useless per-flow dropped statistic")

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 018e5b458723d04cbeadbc3f0e06eba85798f427)

Change-Id: I09426b4d4b41b9302e534e41fdcab109ef55c571
  • Loading branch information
YueHaibing authored and diphons committed Mar 23, 2024
1 parent 71c11f6 commit a03bfe5
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions net/sched/sch_fq_codel.c
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,6 @@ static struct sk_buff *fq_codel_dequeue(struct Qdisc *sch)
struct sk_buff *skb;
struct fq_codel_flow *flow;
struct list_head *head;
u32 prev_drop_count, prev_ecn_mark;

begin:
head = &q->new_flows;
Expand All @@ -306,9 +305,6 @@ static struct sk_buff *fq_codel_dequeue(struct Qdisc *sch)
goto begin;
}

prev_drop_count = q->cstats.drop_count;
prev_ecn_mark = q->cstats.ecn_mark;

skb = codel_dequeue(sch, &sch->qstats.backlog, &q->cparams,
&flow->cvars, &q->cstats, qdisc_pkt_len,
codel_get_enqueue_time, drop_func, dequeue_func);
Expand Down

0 comments on commit a03bfe5

Please sign in to comment.