All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe()
@ 2016-09-15  3:25 Wei Yongjun
  2016-09-15  6:24 ` Johannes Thumshirn
  2016-09-15 13:57 ` Martin K. Petersen
  0 siblings, 2 replies; 3+ messages in thread
From: Wei Yongjun @ 2016-09-15  3:25 UTC (permalink / raw)
  To: Bryant G . Ly, Michael Cyr, James E.J. Bottomley, Martin K. Petersen
  Cc: Wei Yongjun, linux-scsi, target-devel

From: Wei Yongjun <weiyongjun1@huawei.com>

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

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
 drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c b/drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c
index 4dd8e5e..38b086e 100644
--- a/drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c
+++ b/drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c
@@ -3449,6 +3449,7 @@ static int ibmvscsis_probe(struct vio_dev *vdev,
 	vscsi->map_ioba = dma_map_single(&vdev->dev, vscsi->map_buf, PAGE_SIZE,
 					 DMA_BIDIRECTIONAL);
 	if (dma_mapping_error(&vdev->dev, vscsi->map_ioba)) {
+		rc = -ENOMEM;
 		dev_err(&vscsi->dev, "probe: error mapping command buffer\n");
 		goto free_buf;
 	}


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

* Re: [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe()
  2016-09-15  3:25 [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe() Wei Yongjun
@ 2016-09-15  6:24 ` Johannes Thumshirn
  2016-09-15 13:57 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Johannes Thumshirn @ 2016-09-15  6:24 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Bryant G . Ly, Michael Cyr, James E.J. Bottomley,
	Martin K. Petersen, Wei Yongjun, linux-scsi, target-devel

On Thu, Sep 15, 2016 at 03:25:23AM +0000, Wei Yongjun wrote:
> From: Wei Yongjun <weiyongjun1@huawei.com>
> 
> Fix to return error code -ENOMEM from the dma mapping error handling
> case instead of 0, as done elsewhere in this function.
> 
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---

Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>

-- 
Johannes Thumshirn                                          Storage
jthumshirn@suse.de                                +49 911 74053 689
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)
Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850

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

* Re: [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe()
  2016-09-15  3:25 [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe() Wei Yongjun
  2016-09-15  6:24 ` Johannes Thumshirn
@ 2016-09-15 13:57 ` Martin K. Petersen
  1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2016-09-15 13:57 UTC (permalink / raw)
  To: Wei Yongjun
  Cc: Bryant G . Ly, Michael Cyr, James E.J. Bottomley,
	Martin K. Petersen, Wei Yongjun, linux-scsi, target-devel

>>>>> "Wei" == Wei Yongjun <weiyj.lk@gmail.com> writes:

Wei> From: Wei Yongjun <weiyongjun1@huawei.com> Fix to return error code
Wei> -ENOMEM from the dma mapping error handling case instead of 0, as
Wei> done elsewhere in this function.

Applied to 4.9/scsi-queue.

-- 
Martin K. Petersen	Oracle Linux Engineering

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

end of thread, other threads:[~2016-09-15 13:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-15  3:25 [PATCH -next] scsi: ibmvscsis: Fix error return code in ibmvscsis_probe() Wei Yongjun
2016-09-15  6:24 ` Johannes Thumshirn
2016-09-15 13:57 ` Martin K. Petersen

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.