]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: add I2C mdio bus
authorRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 25 Jul 2017 14:03:08 +0000 (15:03 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Aug 2017 03:55:28 +0000 (20:55 -0700)
commit105629de1ae4cce1b4622522589726b77c2cb169
tree399004eb51b90393cd31c2ab03474bbb63a5bc24
parent5ce53701cd18a75055a2ca7e13784a74e0788b15
net: phy: add I2C mdio bus

Add an I2C MDIO bus bridge library, to allow phylib to access PHYs which
are connected to an I2C bus instead of the more conventional MDIO bus.
Such PHYs can be found in SFP adapters and SFF modules.

Since PHYs appear at I2C bus address 0x40..0x5f, and 0x50/0x51 are
reserved for SFP EEPROMs/diagnostics, we must not allow the MDIO bus
to access these I2C addresses.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/Kconfig
drivers/net/phy/Makefile
drivers/net/phy/mdio-i2c.c [new file with mode: 0644]
drivers/net/phy/mdio-i2c.h [new file with mode: 0644]