diff options
author | David S. Miller <davem@davemloft.net> | 2013-12-09 20:39:05 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-12-09 20:39:05 -0500 |
commit | 65be6291c856bee0308c535287f813418402d8b3 (patch) | |
tree | bc291d4587494cd5419e672eaeb3e9682239c608 /drivers/net/ethernet/renesas/sh_eth.c | |
parent | 73713357ab58aacda1af715bb5a623528dbbfd79 (diff) | |
parent | 0c9eb5b931c3da3a79faa889b903dc7bd318203c (diff) |
Merge branch 'phy_reset'
Florian Fainelli says:
====================
net: phy: consolidate PHY reset
This patchset consolidates the PHY reset through the MII BMCR
register by using a central place were this is done.
This patchset resumes the work Kyle Moffett started here:
https://lkml.org/lkml/2011/10/20/301
Note that at this point, drivers doing funky things after issuing
a PHY reset using phy_init_hw() will still suffer from PHY state
machine problems, this will be taken care of later on.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/renesas/sh_eth.c')
-rw-r--r-- | drivers/net/ethernet/renesas/sh_eth.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/ethernet/renesas/sh_eth.c b/drivers/net/ethernet/renesas/sh_eth.c index d256ce19d4d..6761dde7007 100644 --- a/drivers/net/ethernet/renesas/sh_eth.c +++ b/drivers/net/ethernet/renesas/sh_eth.c @@ -1704,7 +1704,10 @@ static int sh_eth_phy_start(struct net_device *ndev) return ret; /* reset phy - this also wakes it from PDOWN */ - phy_write(mdp->phydev, MII_BMCR, BMCR_RESET); + ret = phy_init_hw(mdp->phydev); + if (ret) + return ret; + phy_start(mdp->phydev); return 0; |