diff options
author | Marek BehĂșn <kabel@kernel.org> | 2022-09-30 17:21:08 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-10-03 13:08:33 +0300 |
commit | e85b1347ace677c3822c12d9332dfaaffe594da6 (patch) | |
tree | 393079f23e9d9b2ee7bfd3b83eefbc36a814b1de /drivers/net/mdio/mdio-i2c.c | |
parent | 13c8adcf221f1ff407115d3269e0fb57e8cecf82 (diff) | |
download | linux-e85b1347ace677c3822c12d9332dfaaffe594da6.tar.xz |
net: sfp: create/destroy I2C mdiobus before PHY probe/after PHY release
Instead of configuring the I2C mdiobus when SFP driver is probed,
create/destroy the mdiobus before the PHY is probed for/after it is
released.
This way we can tell the mdio-i2c code which protocol to use for each
SFP transceiver.
Move the code that determines MDIO I2C protocol from
sfp_sm_probe_for_phy() to sfp_sm_mod_probe(), where most of the SFP ID
parsing is done. Don't allocate I2C bus if no PHY is expected.
Signed-off-by: Marek BehĂșn <kabel@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/mdio/mdio-i2c.c')
0 files changed, 0 insertions, 0 deletions