* [PATCH net-next 0/2] Add support to Fiberstore SFP quirks @ 2023-07-21 6:00 Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 1/2] net: sfp: add quirk for FS's 2.5G copper SFP Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) Raju Lakkaraju 0 siblings, 2 replies; 4+ messages in thread From: Raju Lakkaraju @ 2023-07-21 6:00 UTC (permalink / raw) To: netdev; +Cc: davem, kuba, linux-kernel, andrew, linux, UNGLinuxDriver This patch series adds support to Fiberstore(FS)'s SFP quirks for - 2.5G copper SFP (SFP-2.5G-T) - DAC10G SFP (SFPP-PC01) Raju Lakkaraju (2): net: sfp: add quirk for FS's 2.5G copper SFP net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) drivers/net/phy/sfp.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) -- 2.25.1 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH net-next 1/2] net: sfp: add quirk for FS's 2.5G copper SFP 2023-07-21 6:00 [PATCH net-next 0/2] Add support to Fiberstore SFP quirks Raju Lakkaraju @ 2023-07-21 6:00 ` Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) Raju Lakkaraju 1 sibling, 0 replies; 4+ messages in thread From: Raju Lakkaraju @ 2023-07-21 6:00 UTC (permalink / raw) To: netdev; +Cc: davem, kuba, linux-kernel, andrew, linux, UNGLinuxDriver Add a quirk for a copper SFP that identifies itself as "FS" "SFP-2.5G-T". This module's PHY is inaccessible, and can only run at 2500base-X with the host without negotiation. Add a quirk to enable the 2500base-X interface mode with 2500base-T support and disable auto negotiation. Signed-off-by: Raju Lakkaraju <Raju.Lakkaraju@microchip.com> --- drivers/net/phy/sfp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c index d855a18308d7..ee049efdf71b 100644 --- a/drivers/net/phy/sfp.c +++ b/drivers/net/phy/sfp.c @@ -463,6 +463,9 @@ static const struct sfp_quirk sfp_quirks[] = { SFP_QUIRK("HUAWEI", "MA5671A", sfp_quirk_2500basex, sfp_fixup_ignore_tx_fault), + // FS 2.5G Base-T + SFP_QUIRK_M("FS", "SFP-2.5G-T", sfp_quirk_oem_2_5g), + // Lantech 8330-262D-E can operate at 2500base-X, but incorrectly report // 2500MBd NRZ in their EEPROM SFP_QUIRK_M("Lantech", "8330-262D-E", sfp_quirk_2500basex), -- 2.25.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) 2023-07-21 6:00 [PATCH net-next 0/2] Add support to Fiberstore SFP quirks Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 1/2] net: sfp: add quirk for FS's 2.5G copper SFP Raju Lakkaraju @ 2023-07-21 6:00 ` Raju Lakkaraju 2023-07-21 7:50 ` Russell King (Oracle) 1 sibling, 1 reply; 4+ messages in thread From: Raju Lakkaraju @ 2023-07-21 6:00 UTC (permalink / raw) To: netdev; +Cc: davem, kuba, linux-kernel, andrew, linux, UNGLinuxDriver Add a quirk for a DAC10G SFP that identifies itself as "FS" "SFPP-PC01". Add a quirk to enable the SGMII interface, modes 2500base-T, 1000base-T, 100base-T/Full and 100base-T/Half support. Signed-off-by: Raju Lakkaraju <Raju.Lakkaraju@microchip.com> --- drivers/net/phy/sfp.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c index ee049efdf71b..80d2680f08ab 100644 --- a/drivers/net/phy/sfp.c +++ b/drivers/net/phy/sfp.c @@ -421,6 +421,18 @@ static void sfp_quirk_oem_2_5g(const struct sfp_eeprom_id *id, sfp_quirk_disable_autoneg(id, modes, interfaces); } +static void sfp_quirk_fs_dac(const struct sfp_eeprom_id *id, + unsigned long *modes, + unsigned long *interfaces) +{ + /* Fiberstore(FS)'s DAC SFP (SFPP-PC01) */ + linkmode_set_bit(ETHTOOL_LINK_MODE_2500baseT_Full_BIT, modes); + linkmode_set_bit(ETHTOOL_LINK_MODE_1000baseT_Full_BIT, modes); + linkmode_set_bit(ETHTOOL_LINK_MODE_100baseT_Full_BIT, modes); + linkmode_set_bit(ETHTOOL_LINK_MODE_100baseT_Half_BIT, modes); + __set_bit(PHY_INTERFACE_MODE_SGMII, interfaces); +} + static void sfp_quirk_ubnt_uf_instant(const struct sfp_eeprom_id *id, unsigned long *modes, unsigned long *interfaces) @@ -465,6 +477,8 @@ static const struct sfp_quirk sfp_quirks[] = { // FS 2.5G Base-T SFP_QUIRK_M("FS", "SFP-2.5G-T", sfp_quirk_oem_2_5g), + // FS DAC10G (SFPP-PC01) + SFP_QUIRK_M("FS", "SFPP-PC01", sfp_quirk_fs_dac), // Lantech 8330-262D-E can operate at 2500base-X, but incorrectly report // 2500MBd NRZ in their EEPROM -- 2.25.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) 2023-07-21 6:00 ` [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) Raju Lakkaraju @ 2023-07-21 7:50 ` Russell King (Oracle) 0 siblings, 0 replies; 4+ messages in thread From: Russell King (Oracle) @ 2023-07-21 7:50 UTC (permalink / raw) To: Raju Lakkaraju; +Cc: netdev, davem, kuba, linux-kernel, andrew, UNGLinuxDriver On Fri, Jul 21, 2023 at 11:30:57AM +0530, Raju Lakkaraju wrote: > Add a quirk for a DAC10G SFP that identifies itself as "FS" "SFPP-PC01". > Add a quirk to enable the SGMII interface, modes 2500base-T, 1000base-T, > 100base-T/Full and 100base-T/Half support. > > Signed-off-by: Raju Lakkaraju <Raju.Lakkaraju@microchip.com> > --- > drivers/net/phy/sfp.c | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > > diff --git a/drivers/net/phy/sfp.c b/drivers/net/phy/sfp.c > index ee049efdf71b..80d2680f08ab 100644 > --- a/drivers/net/phy/sfp.c > +++ b/drivers/net/phy/sfp.c > @@ -421,6 +421,18 @@ static void sfp_quirk_oem_2_5g(const struct sfp_eeprom_id *id, > sfp_quirk_disable_autoneg(id, modes, interfaces); > } > > +static void sfp_quirk_fs_dac(const struct sfp_eeprom_id *id, > + unsigned long *modes, > + unsigned long *interfaces) > +{ > + /* Fiberstore(FS)'s DAC SFP (SFPP-PC01) */ > + linkmode_set_bit(ETHTOOL_LINK_MODE_2500baseT_Full_BIT, modes); > + linkmode_set_bit(ETHTOOL_LINK_MODE_1000baseT_Full_BIT, modes); > + linkmode_set_bit(ETHTOOL_LINK_MODE_100baseT_Full_BIT, modes); > + linkmode_set_bit(ETHTOOL_LINK_MODE_100baseT_Half_BIT, modes); No. A DAC cable does _not_ give you twisted-pair ethernet which is what baseT linkmodes are. The description on fs.com states: "The 10G SFP+ Passive Direct Attach Copper Twinax Cable is designed for use in 10GBASE Ethernet." That means it supports 10GBASE-CR, which is the link mode for 10 Gigabit ethernet over a direct attach cable. If it does work at 2.5G speeds, then the protocol that will be used for that will be 2500base-X. If it does work at 1G speeds, then the protocol that will be used for that will be 1000base-X (which is the "standard" protocol for the host connection for 1G SFPs.) Going below that isn't technically possible, but can be done with SGMII by forcing the link settings, but is there really any need to support slower speeds? What possible valid reason could there be? A host not supporting 1G speeds with a SFP cage would be utterly insane. > + __set_bit(PHY_INTERFACE_MODE_SGMII, interfaces); I also disagree with this. Unless there is a PHY present, you can _not_ connect two hosts together that are using the SGMII protocol. The SGMII "negotiation" protocol is _asymetric_, and it relies upon a PHY telling the host what the link speed and duplex settings are. A host never sends that information, so this will not "negotiate". -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last! ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-07-21 7:50 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2023-07-21 6:00 [PATCH net-next 0/2] Add support to Fiberstore SFP quirks Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 1/2] net: sfp: add quirk for FS's 2.5G copper SFP Raju Lakkaraju 2023-07-21 6:00 ` [PATCH net-next 2/2] net: sfp: add quirk for FS's DAC10G SFP (SFPP-PC01) Raju Lakkaraju 2023-07-21 7:50 ` Russell King (Oracle)
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).