diff options
author | Florian Fainelli <f.fainelli@gmail.com> | 2015-03-23 15:09:54 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-03-23 22:10:42 -0400 |
commit | 0c81a8ee61cf4ad29371d7454f65bd8769ba4395 (patch) | |
tree | 8f1482fce49e4d4bf529557fbd9a9ef62c2e6d18 | |
parent | 8212c98358f44a1c54941c2c01d54ea4a7ddb6dd (diff) | |
download | op-kernel-dev-0c81a8ee61cf4ad29371d7454f65bd8769ba4395.zip op-kernel-dev-0c81a8ee61cf4ad29371d7454f65bd8769ba4395.tar.gz |
net: bcmgenet: fix GPHY power-up sequence
We were missing a number of extra steps and delays to power-up the GPHY, update
the sequence to reflect the proper procedure here.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/broadcom/genet/bcmmii.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/net/ethernet/broadcom/genet/bcmmii.c b/drivers/net/ethernet/broadcom/genet/bcmmii.c index 3fdbf57..c26c075 100644 --- a/drivers/net/ethernet/broadcom/genet/bcmmii.c +++ b/drivers/net/ethernet/broadcom/genet/bcmmii.c @@ -179,14 +179,18 @@ static void bcmgenet_phy_power_set(struct net_device *dev, bool enable) if (enable) { reg = bcmgenet_ext_readl(priv, EXT_GPHY_CTRL); - reg &= ~(EXT_CFG_IDDQ_BIAS | EXT_CFG_PWR_DOWN | EXT_CK25_DIS); + reg &= ~EXT_CK25_DIS; + bcmgenet_ext_writel(priv, reg, EXT_GPHY_CTRL); + mdelay(1); + + reg &= ~(EXT_CFG_IDDQ_BIAS | EXT_CFG_PWR_DOWN); reg |= EXT_GPHY_RESET; bcmgenet_ext_writel(priv, reg, EXT_GPHY_CTRL); - mdelay(2); + mdelay(1); reg &= ~EXT_GPHY_RESET; bcmgenet_ext_writel(priv, reg, EXT_GPHY_CTRL); - udelay(20); + udelay(60); } } |