netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
@ 2024-12-10  2:27 Yafang Shao
  2024-12-10 19:49 ` Simon Horman
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Yafang Shao @ 2024-12-10  2:27 UTC (permalink / raw)
  To: saeedm, tariqt, leon, gal, kuba
  Cc: netdev, linux-rdma, Yafang Shao, Tariq Toukan

We noticed a high number of rx_discards_phy events on certain servers while
running `ethtool -S`. However, this critical counter is not currently
included in the standard /proc/net/dev statistics file, making it difficult
to monitor effectively—especially given the diversity of vendors across a
large fleet of servers.

Let's report it via the standard rx_dropped metric.

Suggested-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Yafang Shao <laoar.shao@gmail.com>
Cc: Tariq Toukan <ttoukan.linux@gmail.com>
Cc: Saeed Mahameed <saeedm@nvidia.com>
Cc: Leon Romanovsky <leon@kernel.org>
Cc: Gal Pressman <gal@nvidia.com>
Cc: Jakub Kicinski <kuba@kernel.org>
---
 drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
index e601324a690a..3117fafdabcd 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
@@ -3916,6 +3916,7 @@ mlx5e_get_stats(struct net_device *dev, struct rtnl_link_stats64 *stats)
 	}
 
 	stats->rx_missed_errors = priv->stats.qcnt.rx_out_of_buffer;
+	stats->rx_dropped = PPORT_2863_GET(pstats, if_in_discards);
 
 	stats->rx_length_errors =
 		PPORT_802_3_GET(pstats, a_in_range_length_errors) +
-- 
2.43.5


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

* Re: [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
  2024-12-10  2:27 [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped Yafang Shao
@ 2024-12-10 19:49 ` Simon Horman
  2024-12-17 18:45 ` Jakub Kicinski
  2024-12-19  1:00 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 5+ messages in thread
From: Simon Horman @ 2024-12-10 19:49 UTC (permalink / raw)
  To: Yafang Shao
  Cc: saeedm, tariqt, leon, gal, kuba, netdev, linux-rdma, Tariq Toukan

On Tue, Dec 10, 2024 at 10:27:06AM +0800, Yafang Shao wrote:
> We noticed a high number of rx_discards_phy events on certain servers while
> running `ethtool -S`. However, this critical counter is not currently
> included in the standard /proc/net/dev statistics file, making it difficult
> to monitor effectively—especially given the diversity of vendors across a
> large fleet of servers.
> 
> Let's report it via the standard rx_dropped metric.
> 
> Suggested-by: Jakub Kicinski <kuba@kernel.org>
> Signed-off-by: Yafang Shao <laoar.shao@gmail.com>

Reviewed-by: Simon Horman <horms@kernel.org>


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

* Re: [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
  2024-12-10  2:27 [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped Yafang Shao
  2024-12-10 19:49 ` Simon Horman
@ 2024-12-17 18:45 ` Jakub Kicinski
  2024-12-18  6:20   ` Tariq Toukan
  2024-12-19  1:00 ` patchwork-bot+netdevbpf
  2 siblings, 1 reply; 5+ messages in thread
From: Jakub Kicinski @ 2024-12-17 18:45 UTC (permalink / raw)
  To: saeedm, tariqt, gal; +Cc: Yafang Shao, netdev, Tariq Toukan

On Tue, 10 Dec 2024 10:27:06 +0800 Yafang Shao wrote:
> We noticed a high number of rx_discards_phy events on certain servers while
> running `ethtool -S`. However, this critical counter is not currently
> included in the standard /proc/net/dev statistics file, making it difficult
> to monitor effectively—especially given the diversity of vendors across a
> large fleet of servers.
> 
> Let's report it via the standard rx_dropped metric.

nVidia folks, could you review? Or you're just taking it via your tree
and it will reappear on the list soon? I want to make sure there is no
off-list discussion with the author that leads to the patch being
"lost"...

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

* Re: [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
  2024-12-17 18:45 ` Jakub Kicinski
@ 2024-12-18  6:20   ` Tariq Toukan
  0 siblings, 0 replies; 5+ messages in thread
From: Tariq Toukan @ 2024-12-18  6:20 UTC (permalink / raw)
  To: Jakub Kicinski, saeedm, tariqt, gal; +Cc: Yafang Shao, netdev



On 17/12/2024 20:45, Jakub Kicinski wrote:
> On Tue, 10 Dec 2024 10:27:06 +0800 Yafang Shao wrote:
>> We noticed a high number of rx_discards_phy events on certain servers while
>> running `ethtool -S`. However, this critical counter is not currently
>> included in the standard /proc/net/dev statistics file, making it difficult
>> to monitor effectively—especially given the diversity of vendors across a
>> large fleet of servers.
>>
>> Let's report it via the standard rx_dropped metric.
> 

Reviewed-by: Tariq Toukan <tariqt@nvidia.com>

> nVidia folks, could you review? Or you're just taking it via your tree
> and it will reappear on the list soon?

Please take it.

We do not work anymore with our own netdev tree.
We still work with the mlx5-next tree for patches that should be 
"shared" with non-netdev trees, mainly IFC changes.

> I want to make sure there is no
> off-list discussion with the author that leads to the patch being
> "lost"...




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

* Re: [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
  2024-12-10  2:27 [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped Yafang Shao
  2024-12-10 19:49 ` Simon Horman
  2024-12-17 18:45 ` Jakub Kicinski
@ 2024-12-19  1:00 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 5+ messages in thread
From: patchwork-bot+netdevbpf @ 2024-12-19  1:00 UTC (permalink / raw)
  To: Yafang Shao
  Cc: saeedm, tariqt, leon, gal, kuba, netdev, linux-rdma,
	ttoukan.linux

Hello:

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

On Tue, 10 Dec 2024 10:27:06 +0800 you wrote:
> We noticed a high number of rx_discards_phy events on certain servers while
> running `ethtool -S`. However, this critical counter is not currently
> included in the standard /proc/net/dev statistics file, making it difficult
> to monitor effectively—especially given the diversity of vendors across a
> large fleet of servers.
> 
> Let's report it via the standard rx_dropped metric.
> 
> [...]

Here is the summary with links:
  - [v4,net-next] net/mlx5e: Report rx_discards_phy via rx_dropped
    https://git.kernel.org/netdev/net-next/c/c9cfced17365

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] 5+ messages in thread

end of thread, other threads:[~2024-12-19  1:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-10  2:27 [PATCH v4 net-next] net/mlx5e: Report rx_discards_phy via rx_dropped Yafang Shao
2024-12-10 19:49 ` Simon Horman
2024-12-17 18:45 ` Jakub Kicinski
2024-12-18  6:20   ` Tariq Toukan
2024-12-19  1:00 ` 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).