projects
/
oweals
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4ed4aa2
)
net: axi_emac: Check if phy was correctly detected
author
Michal Simek
<michal.simek@xilinx.com>
Thu, 21 Nov 2013 15:15:51 +0000
(16:15 +0100)
committer
Michal Simek
<michal.simek@xilinx.com>
Tue, 4 Feb 2014 15:42:45 +0000
(16:42 +0100)
As tsec and fm drivers checking phydev->link
ensure that u-boot don't try access device if link is not ready.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drivers/net/xilinx_axi_emac.c
patch
|
blob
|
history
diff --git
a/drivers/net/xilinx_axi_emac.c
b/drivers/net/xilinx_axi_emac.c
index bb5044b31f5ed68b0947fa8b68af4ce4db3a193a..262b67b6cf9d00181e83633752fd21e312f65901 100644
(file)
--- a/
drivers/net/xilinx_axi_emac.c
+++ b/
drivers/net/xilinx_axi_emac.c
@@
-261,6
+261,10
@@
static int setup_phy(struct eth_device *dev)
phydev->dev->name);
return 0;
}
+ if (!phydev->link) {
+ printf("%s: No link.\n", phydev->dev->name);
+ return 0;
+ }
switch (phydev->speed) {
case 1000: