summaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2014-04-21 01:59:03 +0200
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-05-25 16:34:03 +0200
commit08344492b350870db4499c7b90220030f07a5d4b (patch)
tree58366da15a3c81bad3af117321efc4e806e53cb7 /drivers/media
parent[media] omap3isp: Move buffer irqlist to isp_buffer structure (diff)
downloadlinux-08344492b350870db4499c7b90220030f07a5d4b.tar.xz
linux-08344492b350870db4499c7b90220030f07a5d4b.zip
[media] omap3isp: Cancel all queued buffers when stopping the video stream
When stopping a video stream the driver waits for ongoing DMA opeations to complete for the currently active buffer, but doesn't release the non-active queued buffers. This isn't a problem in most cases as the video device is usually closed after the stream is stopped, which will release all the buffers. However the problem would generate a warning when switching to videobuf2. Fix it by cancelling all buffers after DMA operations have completed. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Sakari Ailus <sakari.ailus@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/platform/omap3isp/ispvideo.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/media/platform/omap3isp/ispvideo.c b/drivers/media/platform/omap3isp/ispvideo.c
index e1f998366ba4..ffe56ad4726a 100644
--- a/drivers/media/platform/omap3isp/ispvideo.c
+++ b/drivers/media/platform/omap3isp/ispvideo.c
@@ -1115,6 +1115,8 @@ isp_video_streamoff(struct file *file, void *fh, enum v4l2_buf_type type)
/* Stop the stream. */
omap3isp_pipeline_set_stream(pipe, ISP_PIPELINE_STREAM_STOPPED);
+ omap3isp_video_cancel_stream(video);
+
mutex_lock(&video->queue_lock);
omap3isp_video_queue_streamoff(&vfh->queue);
mutex_unlock(&video->queue_lock);