[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250306165513.541ff46e@kernel.org>
Date: Thu, 6 Mar 2025 16:55:13 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: MD Danish Anwar <danishanwar@...com>
Cc: Vignesh Raghavendra <vigneshr@...com>, Meghana Malladi
<m-malladi@...com>, Diogo Ivo <diogo.ivo@...mens.com>, Lee Trager
<lee@...ger.us>, Andrew Lunn <andrew+netdev@...n.ch>, Roger Quadros
<rogerq@...nel.org>, Jonathan Corbet <corbet@....net>, Simon Horman
<horms@...nel.org>, Paolo Abeni <pabeni@...hat.com>, Eric Dumazet
<edumazet@...gle.com>, "David S. Miller" <davem@...emloft.net>,
<linux-arm-kernel@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
<linux-doc@...r.kernel.org>, <netdev@...r.kernel.org>, <srk@...com>
Subject: Re: [PATCH net-next v2] net: ti: icssg-prueth: Add ICSSG FW Stats
On Wed, 5 Mar 2025 16:46:08 +0530 MD Danish Anwar wrote:
> + - ``FW_RTU_PKT_DROP``: Diagnostic error counter which increments when RTU drops a locally injected packet due to port being disabled or rule violation.
> + - ``FW_Q0_OVERFLOW``: TX overflow counter for queue0
> + - ``FW_Q1_OVERFLOW``: TX overflow counter for queue1
> + - ``FW_Q2_OVERFLOW``: TX overflow counter for queue2
> + - ``FW_Q3_OVERFLOW``: TX overflow counter for queue3
> + - ``FW_Q4_OVERFLOW``: TX overflow counter for queue4
> + - ``FW_Q5_OVERFLOW``: TX overflow counter for queue5
> + - ``FW_Q6_OVERFLOW``: TX overflow counter for queue6
> + - ``FW_Q7_OVERFLOW``: TX overflow counter for queue7
...
Thanks for the docs, it looks good. Now, do all of these get included
in the standard stats returned by icssg_ndo_get_stats64 ?
That's the primary source of information for the user regarding packet
loss.
> if (prueth->pa_stats) {
> for (i = 0; i < ARRAY_SIZE(icssg_all_pa_stats); i++) {
> - reg = ICSSG_FW_STATS_BASE +
> - icssg_all_pa_stats[i].offset *
> - PRUETH_NUM_MACS + slice * sizeof(u32);
> + reg = icssg_all_pa_stats[i].offset +
> + slice * sizeof(u32);
> regmap_read(prueth->pa_stats, reg, &val);
> emac->pa_stats[i] += val;
This gets called by icssg_ndo_get_stats64() which is under RCU
protection and nothing else. I don't see any locking here, and
I hope the regmap doesn't sleep. cat /proc/net/dev to test.
You probably need to send some fixes to net.
--
pw-bot: cr
Powered by blists - more mailing lists