diff options
author | Nicolas Ferre <nicolas.ferre@atmel.com> | 2013-04-14 22:04:33 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-04-15 14:09:37 -0400 |
commit | 72ca820bdb06bd1fef56aad07e0e045260bddb4e (patch) | |
tree | 49c91b520338a5467288bb74f405fb7d793d4e88 | |
parent | ab09a6d0d38fc0da11e4cd57ec7f9fcfd16d335d (diff) | |
download | op-kernel-dev-72ca820bdb06bd1fef56aad07e0e045260bddb4e.zip op-kernel-dev-72ca820bdb06bd1fef56aad07e0e045260bddb4e.tar.gz |
net/macb: fix error return code in macb_probe()
Fix to return a negative error code from the error handling
case instead of 0, as returned elsewhere in this function.
Original-idea-by: <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/cadence/macb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c index 7fd0e3e..6be513d 100644 --- a/drivers/net/ethernet/cadence/macb.c +++ b/drivers/net/ethernet/cadence/macb.c @@ -1602,9 +1602,9 @@ static int __init macb_probe(struct platform_device *pdev) goto err_out_free_irq; } - if (macb_mii_init(bp) != 0) { + err = macb_mii_init(bp); + if (err) goto err_out_unregister_netdev; - } platform_set_drvdata(pdev, dev); |