summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/aurora
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2016-11-15 10:06:31 -0800
committerDavid S. Miller <davem@davemloft.net>2016-11-15 16:33:35 -0500
commitb3de7f36de1d5693cf481051cf72e0e8a5cfe7e6 (patch)
treef5900e9431dd0a317cf23a8251dbf87c54b71eff /drivers/net/ethernet/aurora
parente86a8987e458a1826f509c41494b0b29a61144a7 (diff)
downloadlinux-b3de7f36de1d5693cf481051cf72e0e8a5cfe7e6.tar.bz2
net: nb8800: Utilize phy_ethtool_nway_reset
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/aurora')
-rw-r--r--drivers/net/ethernet/aurora/nb8800.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/net/ethernet/aurora/nb8800.c b/drivers/net/ethernet/aurora/nb8800.c
index b59aa3541270..07ff6492402a 100644
--- a/drivers/net/ethernet/aurora/nb8800.c
+++ b/drivers/net/ethernet/aurora/nb8800.c
@@ -1037,16 +1037,6 @@ static const struct net_device_ops nb8800_netdev_ops = {
.ndo_validate_addr = eth_validate_addr,
};
-static int nb8800_nway_reset(struct net_device *dev)
-{
- struct phy_device *phydev = dev->phydev;
-
- if (!phydev)
- return -ENODEV;
-
- return genphy_restart_aneg(phydev);
-}
-
static void nb8800_get_pauseparam(struct net_device *dev,
struct ethtool_pauseparam *pp)
{
@@ -1165,7 +1155,7 @@ static void nb8800_get_ethtool_stats(struct net_device *dev,
}
static const struct ethtool_ops nb8800_ethtool_ops = {
- .nway_reset = nb8800_nway_reset,
+ .nway_reset = phy_ethtool_nway_reset,
.get_link = ethtool_op_get_link,
.get_pauseparam = nb8800_get_pauseparam,
.set_pauseparam = nb8800_set_pauseparam,