net: axi_emac: Check if phy was correctly detected

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>
master
Michal Simek 12 years ago
parent 4ed4aa20de
commit 6f9b93723a
  1. 4
      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:

Loading…
Cancel
Save