mirror of
https://github.com/torvalds/linux.git
synced 2026-06-04 20:46:48 +02:00
net/mlx5e: Skip PPHCR register query if not supported by the device
Check the PCAM supported registers mask before querying the PPHCR
register, as it is not supported in older devices.
Fixes: 44907e7c8f ("net/mlx5e: Add logic to read RS-FEC histogram bin ranges from PPHCR")
Signed-off-by: Alexei Lazar <alazar@nvidia.com>
Reviewed-by: Yael Chemla <ychemla@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/1761136182-918470-3-git-send-email-tariqt@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
bb65e0c141
commit
d58a9a917a
|
|
@ -1614,7 +1614,9 @@ void mlx5e_stats_fec_get(struct mlx5e_priv *priv,
|
|||
|
||||
fec_set_corrected_bits_total(priv, fec_stats);
|
||||
fec_set_block_stats(priv, mode, fec_stats);
|
||||
fec_set_histograms_stats(priv, mode, hist);
|
||||
|
||||
if (MLX5_CAP_PCAM_REG(priv->mdev, pphcr))
|
||||
fec_set_histograms_stats(priv, mode, hist);
|
||||
}
|
||||
|
||||
#define PPORT_ETH_EXT_OFF(c) \
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user