]> www.infradead.org Git - users/dwmw2/linux.git/commit
mlxbf_gige: add support to display pause frame counters
authorDavid Thompson <davthompson@nvidia.com>
Tue, 5 Mar 2024 21:21:37 +0000 (16:21 -0500)
committerJakub Kicinski <kuba@kernel.org>
Thu, 7 Mar 2024 04:39:58 +0000 (20:39 -0800)
commitc2234161985212d28711c1030337515d3852db80
tree8f6f599fcc3f633babddbcd8ef3f7c5c08c55319
parent1677293ed891664796af51b64feba12a99def4a8
mlxbf_gige: add support to display pause frame counters

This patch updates the mlxbf_gige driver to support the
"get_pause_stats()" callback, which enables display of
pause frame counters via "ethtool -I -a oob_net0".

The pause frame counters are only enabled if the "counters_en"
bit is asserted in the LLU general config register. The driver
will only report stats, and thus overwrite the default stats
state of ETHTOOL_STAT_NOT_SET, if "counters_en" is asserted.

Reviewed-by: Asmaa Mnebhi <asmaa@nvidia.com>
Signed-off-by: David Thompson <davthompson@nvidia.com>
Link: https://lore.kernel.org/r/20240305212137.3525-1-davthompson@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_ethtool.c
drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_regs.h