Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 73970055 authored by Russell King's avatar Russell King Committed by David S. Miller
Browse files

sfp: add SFP module support



Add support for SFP hotpluggable modules via sfp-bus and phylink.
This supports both copper and optical SFP modules, which require
different Serdes modes in order to properly negotiate the link.

Optical SFP modules typically require the Serdes link to be talking
1000BaseX mode - this is the gigabit ethernet mode defined by the
802.3 standard.

Copper SFP modules typically integrate a PHY in the module to convert
from Serdes to copper, and the PHY will be configured by the vendor
to either present a 1000BaseX Serdes link (for fixed 1000BaseT) or a
SGMII Serdes link.  However, this is vendor defined, so we instead
detect the PHY, switch the link to SGMII mode, and use traditional
PHY based negotiation.

Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent da7c1862
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -200,6 +200,11 @@ config LED_TRIGGER_PHY

comment "MII PHY device drivers"

config SFP
	tristate "SFP cage support"
	depends on I2C && PHYLINK
	select MDIO_I2C

config AMD_PHY
	tristate "AMD PHYs"
	---help---
+1 −0
Original line number Diff line number Diff line
@@ -38,6 +38,7 @@ obj-$(CONFIG_MDIO_SUN4I) += mdio-sun4i.o
obj-$(CONFIG_MDIO_THUNDER)	+= mdio-thunder.o
obj-$(CONFIG_MDIO_XGENE)	+= mdio-xgene.o

obj-$(CONFIG_SFP)		+= sfp.o
sfp-obj-$(CONFIG_SFP)		+= sfp-bus.o
obj-y				+= $(sfp-obj-y) $(sfp-obj-m)

drivers/net/phy/sfp.c

0 → 100644
+915 −0

File added.

Preview size limit exceeded, changes collapsed.