Queued list was not reset on REQBUFS(0) call. This caused enqueuing
a freed buffer to the driver.

Reported-by: Angela Wan <[email protected]>
Signed-off-by: Marek Szyprowski <[email protected]>
Signed-off-by: Kyungmin Park <[email protected]>
---
 drivers/media/video/videobuf2-core.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/media/video/videobuf2-core.c b/drivers/media/video/videobuf2-core.c
index 3015e60..5722b81 100644
--- a/drivers/media/video/videobuf2-core.c
+++ b/drivers/media/video/videobuf2-core.c
@@ -254,6 +254,7 @@ static void __vb2_queue_free(struct vb2_queue *q)

        q->num_buffers = 0;
        q->memory = 0;
+       INIT_LIST_HEAD(&q->queued_list);
 }

 /**
--
1.7.1


--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to