aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/phy
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2018-11-10 23:43:37 +0100
committerDavid S. Miller <davem@davemloft.net>2018-11-11 10:10:02 -0800
commitcb6402fe26358a33e32fb71054b248c76dcfe491 (patch)
treed452e2123b8aedec0af918b1d6cf5c990496db38 /drivers/net/phy
parentnet: phy: Add more link modes to the settings table (diff)
downloadlinux-dev-cb6402fe26358a33e32fb71054b248c76dcfe491.tar.xz
linux-dev-cb6402fe26358a33e32fb71054b248c76dcfe491.zip
net: phy: Add support for resolving 5G and 2.5G autoneg
Now that 2.5G and 5G can be represented in phydev->advertising and phydev->lp_advertising, add these two links modes as possible resolutions to auto negotiation. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy')
-rw-r--r--drivers/net/phy/phy-core.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/net/phy/phy-core.c b/drivers/net/phy/phy-core.c
index 6d274cdc2796..20fbd5eb56fd 100644
--- a/drivers/net/phy/phy-core.c
+++ b/drivers/net/phy/phy-core.c
@@ -359,6 +359,14 @@ void phy_resolve_aneg_linkmode(struct phy_device *phydev)
if (linkmode_test_bit(ETHTOOL_LINK_MODE_10000baseT_Full_BIT, common)) {
phydev->speed = SPEED_10000;
phydev->duplex = DUPLEX_FULL;
+ } else if (linkmode_test_bit(ETHTOOL_LINK_MODE_5000baseT_Full_BIT,
+ common)) {
+ phydev->speed = SPEED_5000;
+ phydev->duplex = DUPLEX_FULL;
+ } else if (linkmode_test_bit(ETHTOOL_LINK_MODE_2500baseT_Full_BIT,
+ common)) {
+ phydev->speed = SPEED_2500;
+ phydev->duplex = DUPLEX_FULL;
} else if (linkmode_test_bit(ETHTOOL_LINK_MODE_1000baseT_Full_BIT,
common)) {
phydev->speed = SPEED_1000;