linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: sched: fix misuse of qcpu->backlog in gnet_stats_add_queue_cpu
@ 2022-08-15  3:08 Zhengchao Shao
  2022-08-17  2:50 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Zhengchao Shao @ 2022-08-15  3:08 UTC (permalink / raw)
  To: netdev, linux-kernel, davem, edumazet, kuba, pabeni
  Cc: bigeasy, a.darwish, weiyongjun1, yuehaibing, shaozhengchao

In the gnet_stats_add_queue_cpu function, the qstats->qlen statistics
are incorrectly set to qcpu->backlog.

Fixes: 448e163f8b9b("gen_stats: Add gnet_stats_add_queue()")
Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com>
---
 net/core/gen_stats.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/gen_stats.c b/net/core/gen_stats.c
index a10335b4ba2d..c8d137ef5980 100644
--- a/net/core/gen_stats.c
+++ b/net/core/gen_stats.c
@@ -345,7 +345,7 @@ static void gnet_stats_add_queue_cpu(struct gnet_stats_queue *qstats,
 	for_each_possible_cpu(i) {
 		const struct gnet_stats_queue *qcpu = per_cpu_ptr(q, i);
 
-		qstats->qlen += qcpu->backlog;
+		qstats->qlen += qcpu->qlen;
 		qstats->backlog += qcpu->backlog;
 		qstats->drops += qcpu->drops;
 		qstats->requeues += qcpu->requeues;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] net: sched: fix misuse of qcpu->backlog in gnet_stats_add_queue_cpu
  2022-08-15  3:08 [PATCH net-next] net: sched: fix misuse of qcpu->backlog in gnet_stats_add_queue_cpu Zhengchao Shao
@ 2022-08-17  2:50 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-08-17  2:50 UTC (permalink / raw)
  To: shaozhengchao
  Cc: netdev, linux-kernel, davem, edumazet, kuba, pabeni, bigeasy,
	a.darwish, weiyongjun1, yuehaibing

Hello:

This patch was applied to netdev/net.git (master)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 15 Aug 2022 11:08:48 +0800 you wrote:
> In the gnet_stats_add_queue_cpu function, the qstats->qlen statistics
> are incorrectly set to qcpu->backlog.
> 
> Fixes: 448e163f8b9b("gen_stats: Add gnet_stats_add_queue()")
> Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com>
> ---
>  net/core/gen_stats.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Here is the summary with links:
  - [net-next] net: sched: fix misuse of qcpu->backlog in gnet_stats_add_queue_cpu
    https://git.kernel.org/netdev/net/c/de64b6b6fb6f

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-08-17  2:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-15  3:08 [PATCH net-next] net: sched: fix misuse of qcpu->backlog in gnet_stats_add_queue_cpu Zhengchao Shao
2022-08-17  2:50 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).