DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/sfc: fix getting accumulative SW xstat
@ 2021-09-15 10:40 Andrew Rybchenko
  2021-09-21 15:22 ` Ferruh Yigit
  0 siblings, 1 reply; 2+ messages in thread
From: Andrew Rybchenko @ 2021-09-15 10:40 UTC (permalink / raw)
  To: dev; +Cc: Ivan Ilchenko, stable

From: Ivan Ilchenko <ivan.ilchenko@oktetlabs.ru>

Add missing initialisation of the accumulative SW xstat to
zero since it is sum of per-queue xstats.

Fixes: fdd7719eb3c ("net/sfc: add xstats for Rx/Tx doorbells")
Cc: stable@dpdk.org

Signed-off-by: Ivan Ilchenko <ivan.ilchenko@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
---
 drivers/net/sfc/sfc_sw_stats.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/sfc/sfc_sw_stats.c b/drivers/net/sfc/sfc_sw_stats.c
index 8489b603f5..2b28ba29e6 100644
--- a/drivers/net/sfc/sfc_sw_stats.c
+++ b/drivers/net/sfc/sfc_sw_stats.c
@@ -313,6 +313,7 @@ sfc_sw_xstat_get_values_by_id(struct sfc_adapter *sa,
 	}
 
 	if (count_accum_value) {
+		values[accum_value_idx] = 0;
 		for (qid = 0; qid < nb_queues; ++qid) {
 			if (rte_bitmap_get(bmp, qid) != 0)
 				continue;
-- 
2.30.2


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

* Re: [dpdk-dev] [PATCH] net/sfc: fix getting accumulative SW xstat
  2021-09-15 10:40 [dpdk-dev] [PATCH] net/sfc: fix getting accumulative SW xstat Andrew Rybchenko
@ 2021-09-21 15:22 ` Ferruh Yigit
  0 siblings, 0 replies; 2+ messages in thread
From: Ferruh Yigit @ 2021-09-21 15:22 UTC (permalink / raw)
  To: Andrew Rybchenko, dev; +Cc: Ivan Ilchenko, stable

On 9/15/2021 11:40 AM, Andrew Rybchenko wrote:
> From: Ivan Ilchenko <ivan.ilchenko@oktetlabs.ru>
> 
> Add missing initialisation of the accumulative SW xstat to
> zero since it is sum of per-queue xstats.
> 
> Fixes: fdd7719eb3c ("net/sfc: add xstats for Rx/Tx doorbells")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Ivan Ilchenko <ivan.ilchenko@oktetlabs.ru>
> Signed-off-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>

Applied to dpdk-next-net/main, thanks.

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

end of thread, other threads:[~2021-09-21 15:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-15 10:40 [dpdk-dev] [PATCH] net/sfc: fix getting accumulative SW xstat Andrew Rybchenko
2021-09-21 15:22 ` Ferruh Yigit

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).