diff mbox series

[net-next] net: sfp: add quirk for 2.5G OEM BX SFP

Message ID 96223803-95a8-4879-8a26-bc13b66a6e6b@birger-koblitz.de (mailing list archive)
State Superseded
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: sfp: add quirk for 2.5G OEM BX SFP | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/apply fail Patch does not apply to net-next-0

Commit Message

Birger Koblitz Feb. 9, 2025, 11:01 a.m. UTC
The OEM SFP-2.5G-BX10-D/U SFP module pair is meant to operate with
2500Base-X. However, in their EEPROM they incorrectly specify:
Transceiver codes   : 0x00 0x12 0x00 0x00 0x12 0x00 0x01 0x05 0x00
BR, Nominal         : 2500MBd

Use sfp_quirk_2500basex for this module to allow 2500Base-X mode anyway.
Run-tested on BananaPi R3.

Signed-off-by: Birger Koblitz <mail@birger-koblitz.de>
---
  drivers/net/phy/sfp.c | 2 ++
  1 file changed, 2 insertions(+)

Comments

Daniel Golle Feb. 9, 2025, 3:13 p.m. UTC | #1
On Sun, Feb 09, 2025 at 12:01:55PM +0100, Birger Koblitz wrote:
> The OEM SFP-2.5G-BX10-D/U SFP module pair is meant to operate with
> 2500Base-X. However, in their EEPROM they incorrectly specify:
> Transceiver codes   : 0x00 0x12 0x00 0x00 0x12 0x00 0x01 0x05 0x00
> BR, Nominal         : 2500MBd
> 
> Use sfp_quirk_2500basex for this module to allow 2500Base-X mode anyway.
> Run-tested on BananaPi R3.
> 
> Signed-off-by: Birger Koblitz <mail@birger-koblitz.de>

Reviewed-by: Daniel Golle <daniel@makrotopia.org>

> ---
>  drivers/net/phy/sfp.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c
> index 7dbcbf0a4ee2..9369f5297769 100644
> --- a/drivers/net/phy/sfp.c
> +++ b/drivers/net/phy/sfp.c
> @@ -515,6 +515,8 @@ static const struct sfp_quirk sfp_quirks[] = {
>   	SFP_QUIRK_F("OEM", "SFP-10G-T", sfp_fixup_rollball_cc),
>  	SFP_QUIRK_M("OEM", "SFP-2.5G-T", sfp_quirk_oem_2_5g),
> +	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-D", sfp_quirk_2500basex),
> +	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-U", sfp_quirk_2500basex),
>  	SFP_QUIRK_F("OEM", "RTSFP-10", sfp_fixup_rollball_cc),
>  	SFP_QUIRK_F("OEM", "RTSFP-10G", sfp_fixup_rollball_cc),
>  	SFP_QUIRK_F("Turris", "RTSFP-2.5G", sfp_fixup_rollball),
> -- 
> 2.39.5
Jakub Kicinski Feb. 12, 2025, 3:02 a.m. UTC | #2
On Sun, 9 Feb 2025 12:01:55 +0100 Birger Koblitz wrote:
>    	SFP_QUIRK_F("OEM", "SFP-10G-T", sfp_fixup_rollball_cc),

The patch is corrupted, there is an extra space at the start
of each context line. Perhaps try resending with git send-email?
Before resending please add Daniel's review tag to the commit message.

>   	SFP_QUIRK_M("OEM", "SFP-2.5G-T", sfp_quirk_oem_2_5g),
> +	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-D", sfp_quirk_2500basex),
> +	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-U", sfp_quirk_2500basex),
diff mbox series

Patch

diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c
index 7dbcbf0a4ee2..9369f5297769 100644
--- a/drivers/net/phy/sfp.c
+++ b/drivers/net/phy/sfp.c
@@ -515,6 +515,8 @@  static const struct sfp_quirk sfp_quirks[] = {
   	SFP_QUIRK_F("OEM", "SFP-10G-T", sfp_fixup_rollball_cc),
  	SFP_QUIRK_M("OEM", "SFP-2.5G-T", sfp_quirk_oem_2_5g),
+	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-D", sfp_quirk_2500basex),
+	SFP_QUIRK_M("OEM", "SFP-2.5G-BX10-U", sfp_quirk_2500basex),
  	SFP_QUIRK_F("OEM", "RTSFP-10", sfp_fixup_rollball_cc),
  	SFP_QUIRK_F("OEM", "RTSFP-10G", sfp_fixup_rollball_cc),
  	SFP_QUIRK_F("Turris", "RTSFP-2.5G", sfp_fixup_rollball),
-- 
2.39.5