]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: atlantic: fix reading SFP module info on some AQC100 cards
authorTiernan Hubble <thubble@thubble.ca>
Wed, 25 Feb 2026 00:20:25 +0000 (18:20 -0600)
committerJakub Kicinski <kuba@kernel.org>
Fri, 27 Feb 2026 03:20:53 +0000 (19:20 -0800)
commitb70190d767be4464e092b252185fa65398bcc662
tree6b8773fa1c8e04b9dbc9adda4c9ab1a342c6f9df
parented02c6b8b570d49e9766d60b1d9b48ea5e2cfaed
net: atlantic: fix reading SFP module info on some AQC100 cards

Commit 853a2944aaf3 ("net: atlantic: support reading SFP module info")
added support for reading SFP module info on AQC100-based cards. However,
it only supports reading directly from the controller's hardware
registers, and this does not seem to be supported on certain cards,
including my TRENDnet TEG-10GECSFP V3. "ethtool -m" times out when reading
certain registers, even when I increase the read poll timeout values.

The DPDK "atlantic" driver reads module info via firmware calls instead of
directly reading the hardware registers, provided that the NIC's firmware
version supports it.

This change adapts the DPDK firmware call code to the kernel driver. It
preserves the old hardware-based module read code as a fallback when the
firmware does not support it, to avoid breaking cards that are currently
working.

Tested on 2 different TRENDnet TEG-10GECSFP V3 cards, both with firmware
version 3.1.121 (current at the time of this patch). Both cards correctly
reported module info for a passive DAC cable and 2 different 10G optical
transceivers.

Signed-off-by: Tiernan Hubble <thubble@thubble.ca>
Link: https://patch.msgid.link/20260225002026.1754045-1-thubble@thubble.ca
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/aquantia/atlantic/aq_ethtool.c
drivers/net/ethernet/aquantia/atlantic/aq_hw.h
drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h
drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils_fw2x.c