]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net/mlx5e: Don't gate FEC histograms on ppcnt_statistical_group
authorAlexei Lazar <alazar@nvidia.com>
Thu, 25 Dec 2025 13:27:14 +0000 (15:27 +0200)
committerJakub Kicinski <kuba@kernel.org>
Sun, 4 Jan 2026 18:38:50 +0000 (10:38 -0800)
commit6c75dc9de40ff91ec2b621b78f6cd9031762067c
tree463166def28bf4e8dc652b11a068218a2ab921ee
parent31057979cdadfee9f934746fd84046b43506ba61
net/mlx5e: Don't gate FEC histograms on ppcnt_statistical_group

Currently, the ppcnt_statistical_group capability check
incorrectly gates access to FEC histogram statistics.
This capability applies only to statistical and physical
counter groups, not for histogram data.

Restrict the ppcnt_statistical_group check to the
Physical_Layer_Counters and Physical_Layer_Statistical_Counters
groups.
Histogram statistics access remains gated by the pphcr
capability.

The issue is harmless as of today, as it happens that
ppcnt_statistical_group is set on all existing devices that
have pphcr set.

Fixes: 6b81b8a0b197 ("net/mlx5e: Don't query FEC statistics when FEC is disabled")
Signed-off-by: Alexei Lazar <alazar@nvidia.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Mark Bloch <mbloch@nvidia.com>
Link: https://patch.msgid.link/20251225132717.358820-3-mbloch@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c