projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b7081d9
)
UEC: Don't udelay needlessly
author
Joakim Tjernlund
<
[email protected]
>
Wed, 11 Aug 2010 09:44:21 +0000
(11:44 +0200)
committer
Ben Warren
<
[email protected]
>
Tue, 12 Oct 2010 05:47:48 +0000
(22:47 -0700)
uec_init() adds an udelay(100000) even though
the PHY status read went well, don't do that.
Signed-off-by: Joakim Tjernlund <
[email protected]
>
Acked-by: Kim Phillips <
[email protected]
>
Signed-off-by: Ben Warren <
[email protected]
>
drivers/qe/uec.c
patch
|
blob
|
history
diff --git
a/drivers/qe/uec.c
b/drivers/qe/uec.c
index e10c0f328c4ae8e94976b2b3ce743b9226f1da91..48033d750c3cee5eb649ee67889e37a0405220c0 100644
(file)
--- a/
drivers/qe/uec.c
+++ b/
drivers/qe/uec.c
@@
-1223,8
+1223,10
@@
static int uec_init(struct eth_device* dev, bd_t *bd)
i = 50;
do {
err = curphy->read_status(uec->mii_info);
+ if (!(((i-- > 0) && !uec->mii_info->link) || err))
+ break;
udelay(100000);
- } while (
((i-- > 0) && !uec->mii_info->link) || err
);
+ } while (
1
);
if (err || i <= 0)
printf("warning: %s: timeout on PHY link\n", dev->name);