linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] ibmvnic: fix error return code in ibmvnic_probe()
@ 2016-08-24 13:47 Wei Yongjun
  2016-08-25 23:41 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2016-08-24 13:47 UTC (permalink / raw)
  To: Benjamin Herrenschmidt, Paul Mackerras, Michael Ellerman,
	Thomas Falcon, John Allen
  Cc: Wei Yongjun, linuxppc-dev, netdev

From: Wei Yongjun <weiyongjun1@huawei.com>

Fix to return error code -ENOMEM from the dma_map_single error
handling case instead of 0, as done elsewhere in this function.

Fixes: 032c5e82847a ("Driver for IBM System i/p VNIC protocol")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/net/ethernet/ibm/ibmvnic.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
index b942108..59245d0 100644
--- a/drivers/net/ethernet/ibm/ibmvnic.c
+++ b/drivers/net/ethernet/ibm/ibmvnic.c
@@ -3751,6 +3751,7 @@ static int ibmvnic_probe(struct vio_dev *dev, const struct vio_device_id *id)
 	if (dma_mapping_error(&dev->dev, adapter->stats_token)) {
 		if (!firmware_has_feature(FW_FEATURE_CMO))
 			dev_err(&dev->dev, "Couldn't map stats buffer\n");
+		rc = -ENOMEM;
 		goto free_crq;
 	}

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

* Re: [PATCH -next] ibmvnic: fix error return code in ibmvnic_probe()
  2016-08-24 13:47 [PATCH -next] ibmvnic: fix error return code in ibmvnic_probe() Wei Yongjun
@ 2016-08-25 23:41 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2016-08-25 23:41 UTC (permalink / raw)
  To: weiyj.lk
  Cc: benh, paulus, mpe, tlfalcon, jallen, weiyongjun1, linuxppc-dev,
	netdev

From: Wei Yongjun <weiyj.lk@gmail.com>
Date: Wed, 24 Aug 2016 13:47:58 +0000

> From: Wei Yongjun <weiyongjun1@huawei.com>
> 
> Fix to return error code -ENOMEM from the dma_map_single error
> handling case instead of 0, as done elsewhere in this function.
> 
> Fixes: 032c5e82847a ("Driver for IBM System i/p VNIC protocol")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>

Applied.

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

end of thread, other threads:[~2016-08-25 23:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-24 13:47 [PATCH -next] ibmvnic: fix error return code in ibmvnic_probe() Wei Yongjun
2016-08-25 23:41 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).