diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2009-11-29 15:08:55 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-11-29 17:23:53 -0800 |
commit | c1c4f453b61463df4df16f7aa5782fc0cfe05b9e (patch) | |
tree | a72b533294500e7f19ab1f67142b732471df53cb /drivers/net/sfc/qt202x_phy.c | |
parent | e58f69f4082f60076885798fae8f3a17ea713bf6 (diff) |
sfc: Remove static PHY data and enumerations
New NICs have firmware managing the PHY, and we will discover the PHY
capabilities at run-time. Replace the static data with probe() and
test_name() operations.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/qt202x_phy.c')
-rw-r--r-- | drivers/net/sfc/qt202x_phy.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/net/sfc/qt202x_phy.c b/drivers/net/sfc/qt202x_phy.c index 49a5ab5efb9..22b0e89ba8f 100644 --- a/drivers/net/sfc/qt202x_phy.c +++ b/drivers/net/sfc/qt202x_phy.c @@ -135,6 +135,14 @@ static int qt202x_reset_phy(struct efx_nic *efx) return rc; } +static int qt202x_phy_probe(struct efx_nic *efx) +{ + efx->mdio.mmds = QT202X_REQUIRED_DEVS; + efx->mdio.mode_support = MDIO_SUPPORTS_C45 | MDIO_EMULATE_C22; + efx->loopback_modes = QT202X_LOOPBACKS | FALCON_XMAC_LOOPBACKS; + return 0; +} + static int qt202x_phy_init(struct efx_nic *efx) { struct qt202x_phy_data *phy_data; @@ -224,13 +232,11 @@ static void qt202x_phy_fini(struct efx_nic *efx) } struct efx_phy_operations falcon_qt202x_phy_ops = { - .macs = EFX_XMAC, + .probe = qt202x_phy_probe, .init = qt202x_phy_init, .reconfigure = qt202x_phy_reconfigure, .poll = qt202x_phy_poll, .fini = qt202x_phy_fini, .get_settings = qt202x_phy_get_settings, .set_settings = efx_mdio_set_settings, - .mmds = QT202X_REQUIRED_DEVS, - .loopbacks = QT202X_LOOPBACKS, }; |