public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
* [patch] [media] v4l: xilinx: missing error code
@ 2015-06-24 14:28 Dan Carpenter
  2015-06-24 16:14 ` Hyun Kwon
  2015-06-25 21:36 ` Laurent Pinchart
  0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2015-06-24 14:28 UTC (permalink / raw)
  To: Hyun Kwon
  Cc: Laurent Pinchart, Mauro Carvalho Chehab, Michal Simek,
	Sören Brinkmann, linux-media, kernel-janitors

We should set "ret" on this error path instead of returning success.

Fixes: df3305156f98 ('[media] v4l: xilinx: Add Xilinx Video IP core')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/drivers/media/platform/xilinx/xilinx-dma.c b/drivers/media/platform/xilinx/xilinx-dma.c
index 98e50e4..e779c93 100644
--- a/drivers/media/platform/xilinx/xilinx-dma.c
+++ b/drivers/media/platform/xilinx/xilinx-dma.c
@@ -699,8 +699,10 @@ int xvip_dma_init(struct xvip_composite_device *xdev, struct xvip_dma *dma,
 
 	/* ... and the buffers queue... */
 	dma->alloc_ctx = vb2_dma_contig_init_ctx(dma->xdev->dev);
-	if (IS_ERR(dma->alloc_ctx))
+	if (IS_ERR(dma->alloc_ctx)) {
+		ret = PTR_ERR(dma->alloc_ctx);
 		goto error;
+	}
 
 	/* Don't enable VB2_READ and VB2_WRITE, as using the read() and write()
 	 * V4L2 APIs would be inefficient. Testing on the command line with a

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

end of thread, other threads:[~2015-06-25 21:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-24 14:28 [patch] [media] v4l: xilinx: missing error code Dan Carpenter
2015-06-24 16:14 ` Hyun Kwon
2015-06-25 21:36 ` Laurent Pinchart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox