diff options
author | Ashwini Rao <ashwinik@codeaurora.org> | 2015-12-11 16:45:01 -0800 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 21:17:01 -0700 |
commit | 7c59712b2f338f129ac97d388a3f6cf6472829aa (patch) | |
tree | b0343b1831a855c2df06cb0db2cdfc12f2833051 /drivers/media | |
parent | 043d337047f6e266465b6ed1c1fdf0c4a6c9b3a6 (diff) |
msm: fd: Do buffer done on all buffers in vb2 queue on streamoff
On v4l2 stop_streaming, a vb2_buffer_done needs to be done to
ensure that the driver gives back all the buffers it got from
the buf_queue() callback.
Change-Id: I1ba8776381efb41820ed44a8bdf70c99574b09ac
Signed-off-by: Ashwini Rao <ashwinik@codeaurora.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/platform/msm/camera_v2/fd/msm_fd_hw.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/media/platform/msm/camera_v2/fd/msm_fd_hw.c b/drivers/media/platform/msm/camera_v2/fd/msm_fd_hw.c index 36836d7ab535..732b64d76cb2 100644 --- a/drivers/media/platform/msm/camera_v2/fd/msm_fd_hw.c +++ b/drivers/media/platform/msm/camera_v2/fd/msm_fd_hw.c @@ -1503,9 +1503,12 @@ void msm_fd_hw_remove_buffers_from_queue(struct msm_fd_device *fd, if (atomic_read(&curr_buff->active)) active_buffer = curr_buff; - else + else { + /* Do a Buffer done on all the other buffers */ + vb2_buffer_done(&curr_buff->vb_v4l2_buf.vb2_buf, + VB2_BUF_STATE_DONE); list_del(&curr_buff->list); - + } } } spin_unlock(&fd->slock); |