a5a53bbc6e3056604286c14a2aec7d7a30bb0f13
[openwrt/staging/981213.git] /
1 From ad651d68cee75e9ac20002254c4e5d09ee67a84b Mon Sep 17 00:00:00 2001
2 From: Daniel Golle <daniel@makrotopia.org>
3 Date: Sun, 2 Apr 2023 12:44:37 +0100
4 Subject: [PATCH] net: sfp: add quirk enabling 2500Base-x for HG MXPD-483II
5
6 The HG MXPD-483II 1310nm SFP module is meant to operate with 2500Base-X,
7 however, in their EEPROM they incorrectly specify:
8 Transceiver type : Ethernet: 1000BASE-LX
9 ...
10 BR, Nominal : 2600MBd
11
12 Use sfp_quirk_2500basex for this module to allow 2500Base-X mode anyway.
13
14 https://forum.banana-pi.org/t/bpi-r3-sfp-module-compatibility/14573/60
15
16 Reported-by: chowtom <chowtom@gmail.com>
17 Tested-by: chowtom <chowtom@gmail.com>
18 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
19 Reviewed-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
20 Signed-off-by: David S. Miller <davem@davemloft.net>
21 ---
22 drivers/net/phy/sfp.c | 4 ++++
23 1 file changed, 4 insertions(+)
24
25 --- a/drivers/net/phy/sfp.c
26 +++ b/drivers/net/phy/sfp.c
27 @@ -366,6 +366,10 @@ static const struct sfp_quirk sfp_quirks
28 .part = "HL-GSFP",
29 .fixup = sfp_fixup_halny_gsfp,
30 }, {
31 + .vendor = "HG GENUINE",
32 + .part = "MXPD-483II",
33 + .modes = sfp_quirk_2500basex,
34 + }, {
35 // Huawei MA5671A can operate at 2500base-X, but report 1.2GBd
36 // NRZ in their EEPROM
37 .vendor = "HUAWEI",