summaryrefslogtreecommitdiffstats
path: root/include/linux/phy.h
diff options
context:
space:
mode:
authorRussell King2017-06-05 13:23:00 +0200
committerDavid S. Miller2017-06-07 03:14:13 +0200
commit002ba7058a7f141cf22d37967a4ef78239c50e9e (patch)
tree8a72dbee1f940693c4087f196f4fe8f0399d7855 /include/linux/phy.h
parentnet: phy: avoid genphy_aneg_done() for PHYs without clause 22 support (diff)
downloadkernel-qcow2-linux-002ba7058a7f141cf22d37967a4ef78239c50e9e.tar.gz
kernel-qcow2-linux-002ba7058a7f141cf22d37967a4ef78239c50e9e.tar.xz
kernel-qcow2-linux-002ba7058a7f141cf22d37967a4ef78239c50e9e.zip
net: phy: hook up clause 45 autonegotiation restart
genphy_restart_aneg() can only restart autonegotiation on clause 22 PHYs. Add a phy_restart_aneg() function which selects between the clause 22 and clause 45 restart functionality depending on the PHY type and whether the Clause 45 PHY supports the Clause 22 register set. Signed-off-by: Russell King <rmk+kernel@armlinux.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>
Diffstat (limited to 'include/linux/phy.h')
-rw-r--r--include/linux/phy.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/phy.h b/include/linux/phy.h
index a47eb5e841d2..b24de9ddc886 100644
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -804,6 +804,7 @@ int phy_start_aneg(struct phy_device *phydev);
int phy_aneg_done(struct phy_device *phydev);
int phy_stop_interrupts(struct phy_device *phydev);
+int phy_restart_aneg(struct phy_device *phydev);
static inline int phy_read_status(struct phy_device *phydev)
{