All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] s6gmac: fix error return code in s6gmac_probe()
@ 2013-03-22 13:17 Wei Yongjun
  2013-03-22 14:24 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2013-03-22 13:17 UTC (permalink / raw)
  To: davem, jim.cromie, gregkh, jkosina, oskar; +Cc: yongjun_wei, netdev

From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

Fix to return a negative error code from the error handling
case instead of 0, as returned elsewhere in this function.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
 drivers/net/ethernet/s6gmac.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/s6gmac.c b/drivers/net/ethernet/s6gmac.c
index cd5f4e2..b6739af 100644
--- a/drivers/net/ethernet/s6gmac.c
+++ b/drivers/net/ethernet/s6gmac.c
@@ -998,6 +998,7 @@ static int s6gmac_probe(struct platform_device *pdev)
 	mb = mdiobus_alloc();
 	if (!mb) {
 		printk(KERN_ERR DRV_PRMT "error allocating mii bus\n");
+		res = -ENOMEM;
 		goto errmii;
 	}
 	mb->name = "s6gmac_mii";

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH -next] s6gmac: fix error return code in s6gmac_probe()
  2013-03-22 13:17 [PATCH -next] s6gmac: fix error return code in s6gmac_probe() Wei Yongjun
@ 2013-03-22 14:24 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2013-03-22 14:24 UTC (permalink / raw)
  To: weiyj.lk; +Cc: jim.cromie, gregkh, jkosina, oskar, yongjun_wei, netdev

From: Wei Yongjun <weiyj.lk@gmail.com>
Date: Fri, 22 Mar 2013 21:17:47 +0800

> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> 
> Fix to return a negative error code from the error handling
> case instead of 0, as returned elsewhere in this function.
> 
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

Applied.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-03-22 14:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-22 13:17 [PATCH -next] s6gmac: fix error return code in s6gmac_probe() Wei Yongjun
2013-03-22 14:24 ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.