RE: [PATCH net-next v3 1/2] net: mana: Move hardware counter stats from per-port to per-VF context
From: Haiyang Zhang
Date: Sun Nov 16 2025 - 16:51:05 EST
> -----Original Message-----
> From: Erni Sri Satya Vennela <ernis@xxxxxxxxxxxxxxxxxxx>
> Sent: Friday, November 14, 2025 6:43 AM
> To: KY Srinivasan <kys@xxxxxxxxxxxxx>; Haiyang Zhang
> <haiyangz@xxxxxxxxxxxxx>; wei.liu@xxxxxxxxxx; Dexuan Cui
> <DECUI@xxxxxxxxxxxxx>; andrew+netdev@xxxxxxx; davem@xxxxxxxxxxxxx;
> edumazet@xxxxxxxxxx; kuba@xxxxxxxxxx; pabeni@xxxxxxxxxx; Long Li
> <longli@xxxxxxxxxxxxx>; Konstantin Taranov <kotaranov@xxxxxxxxxxxxx>;
> horms@xxxxxxxxxx; shradhagupta@xxxxxxxxxxxxxxxxxxx;
> ssengar@xxxxxxxxxxxxxxxxxxx; ernis@xxxxxxxxxxxxxxxxxxx;
> dipayanroy@xxxxxxxxxxxxxxxxxxx; Shiraz Saleem
> <shirazsaleem@xxxxxxxxxxxxx>; sbhatta@xxxxxxxxxxx; linux-
> hyperv@xxxxxxxxxxxxxxx; netdev@xxxxxxxxxxxxxxx; linux-
> kernel@xxxxxxxxxxxxxxx; linux-rdma@xxxxxxxxxxxxxxx
> Subject: [PATCH net-next v3 1/2] net: mana: Move hardware counter stats
> from per-port to per-VF context
>
> Move hardware counter (HC) statistics from mana_port_context to
> mana_context to enable sharing stats across multiple network ports
> on the same MANA VF. Previously, each network port queried
> hardware counters independently using MANA_QUERY_GF_STAT command
> (GF = Generic Function stats from GDMA hardware), resulting in
> redundant queries when multiple ports existed on the same device.
>
> Isolate hardware counter stats by introducing mana_ethtool_hc_stats
> in mana_context and update the code to ensure all stats are properly
> reported via ethtool -S <interface>, maintaining consistency with
> previous behavior.
>
> Signed-off-by: Erni Sri Satya Vennela <ernis@xxxxxxxxxxxxxxxxxxx>
Reviewed-by: Haiyang Zhang <haiyangz@xxxxxxxxxxxxx>