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>
This commit is contained in:
parent
4ed4aa20de
commit
6f9b93723a
@ -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…
Reference in New Issue
Block a user