From: Siva Durga Prasad Paladugu Date: Wed, 30 Mar 2016 06:59:49 +0000 (+0530) Subject: net: zynq_gem: Return error incase of invalid phy address X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=df886fd337b7d3329fb6bece42f83dfc10a6b375;p=thirdparty%2Fu-boot.git net: zynq_gem: Return error incase of invalid phy address Return error from probe in case of invalid phy address. This fixes the issue of uboot crash if phy is not detected. Signed-off-by: Siva Durga Prasad Paladugu Signed-off-by: Michal Simek --- diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c index 1c377c03bfe..0f46bd029f2 100644 --- a/drivers/net/zynq_gem.c +++ b/drivers/net/zynq_gem.c @@ -661,9 +661,7 @@ static int zynq_gem_probe(struct udevice *dev) if (ret) return ret; - zynq_phy_init(dev); - - return 0; + return zynq_phy_init(dev); } static int zynq_gem_remove(struct udevice *dev)