aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cpmac.c
diff options
context:
space:
mode:
authorFlorian Fainelli <florian@openwrt.org>2009-08-04 06:52:57 -0400
committerDavid S. Miller <davem@davemloft.net>2009-08-05 15:22:11 -0400
commite4540aa94f9b3e75528d9091524e7d82a0650f10 (patch)
tree8bbd1832e019022ffdd1d1d0380981e7997ec347 /drivers/net/cpmac.c
parent76e61eaa55e33ea51205fad633393d1ae10311c5 (diff)
cpmac: wait longer after MDIO reset
This patch slows down the MDIO_ALIVE busy waiting to let switches and PHY come up after reset. Previous loop was too quick for IC+175C and ADM6996C/L switches to come up. Signed-off-by: Florian Fainelli <florian@openwrt.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cpmac.c')
-rw-r--r--drivers/net/cpmac.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/cpmac.c b/drivers/net/cpmac.c
index 7b311c6d14ab..645e6442dc48 100644
--- a/drivers/net/cpmac.c
+++ b/drivers/net/cpmac.c
@@ -1245,11 +1245,11 @@ int __devinit cpmac_init(void)
1245 1245
1246 cpmac_mii->reset(cpmac_mii); 1246 cpmac_mii->reset(cpmac_mii);
1247 1247
1248 for (i = 0; i < 300000; i++) 1248 for (i = 0; i < 300; i++)
1249 if ((mask = cpmac_read(cpmac_mii->priv, CPMAC_MDIO_ALIVE))) 1249 if ((mask = cpmac_read(cpmac_mii->priv, CPMAC_MDIO_ALIVE)))
1250 break; 1250 break;
1251 else 1251 else
1252 cpu_relax(); 1252 msleep(10);
1253 1253
1254 mask &= 0x7fffffff; 1254 mask &= 0x7fffffff;
1255 if (mask & (mask - 1)) { 1255 if (mask & (mask - 1)) {