Skip to content

Commit b86ec45

Browse files
edumazetSasha Levin
authored andcommitted
net_sched: sch_fq: clear q->band_pkt_count[] in fq_reset()
[ Upstream commit a4c2b8b ] When/if a NIC resets, queues are deactivated by dev_deactivate_many(), then reactivated when the reset operation completes. fq_reset() removes all the skbs from various queues. If we do not clear q->band_pkt_count[], these counters keep growing and can eventually reach sch->limit, preventing new packets to be queued. Many thanks to Praveen for discovering the root cause. Fixes: 29f834a ("net_sched: sch_fq: add 3 bands and WRR scheduling") Diagnosed-by: Praveen Kaligineedi <pkaligineedi@google.com> Signed-off-by: Eric Dumazet <edumazet@google.com> Reviewed-by: Neal Cardwell <ncardwell@google.com> Reviewed-by: Willem de Bruijn <willemb@google.com> Link: https://patch.msgid.link/20260304015640.961780-1-edumazet@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent eb5904a commit b86ec45

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

net/sched/sch_fq.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -829,6 +829,7 @@ static void fq_reset(struct Qdisc *sch)
829829
for (idx = 0; idx < FQ_BANDS; idx++) {
830830
q->band_flows[idx].new_flows.first = NULL;
831831
q->band_flows[idx].old_flows.first = NULL;
832+
q->band_pkt_count[idx] = 0;
832833
}
833834
q->delayed = RB_ROOT;
834835
q->flows = 0;

0 commit comments

Comments
 (0)