diff options
author | Heiner Kallweit <hkallweit1@gmail.com> | 2019-04-07 13:55:01 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-04-08 16:24:05 -0700 |
commit | 22b56e827093dd1af2379d294aba7d629b3f3436 (patch) | |
tree | 7ac7c645989e143c593e6121bf80eb5edd57147b /drivers/net/phy/phy-c45.c | |
parent | 5af82f5205f156977fed1c8d2f214f1c58fb263b (diff) | |
download | linux-stable-22b56e827093dd1af2379d294aba7d629b3f3436.tar.gz linux-stable-22b56e827093dd1af2379d294aba7d629b3f3436.tar.bz2 linux-stable-22b56e827093dd1af2379d294aba7d629b3f3436.zip |
net: phy: replace genphy_10g_driver with genphy_c45_driver
Recently a number of generic functions for Clause 45 PHY's has been
added. So let's replace the old very limited genphy_10g_driver with a
genphy_c45_driver. This driver isn't limited to 10G, however it's worth
to be noted that Clause 45 doesn't cover 1000Base-T. For using
1000Base-T with a Clause 45 PHY a dedicated PHY driver using vendor
registers is needed.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy/phy-c45.c')
-rw-r--r-- | drivers/net/phy/phy-c45.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/drivers/net/phy/phy-c45.c b/drivers/net/phy/phy-c45.c index 05c3e87ffc2d..abe13dfe50ad 100644 --- a/drivers/net/phy/phy-c45.c +++ b/drivers/net/phy/phy-c45.c @@ -516,21 +516,10 @@ int gen10g_config_aneg(struct phy_device *phydev) } EXPORT_SYMBOL_GPL(gen10g_config_aneg); -static int gen10g_read_status(struct phy_device *phydev) -{ - /* For now just lie and say it's 10G all the time */ - phydev->speed = SPEED_10000; - phydev->duplex = DUPLEX_FULL; - - return genphy_c45_read_link(phydev); -} - -struct phy_driver genphy_10g_driver = { +struct phy_driver genphy_c45_driver = { .phy_id = 0xffffffff, .phy_id_mask = 0xffffffff, - .name = "Generic 10G PHY", + .name = "Generic Clause 45 PHY", .soft_reset = genphy_no_soft_reset, - .features = PHY_10GBIT_FEATURES, - .config_aneg = gen10g_config_aneg, - .read_status = gen10g_read_status, + .read_status = genphy_c45_read_status, }; |