diff mbox series

[08/14] vicodec: fix vicodec_buf_queue()

Message ID 20190330204311.107417-9-dafna3@gmail.com (mailing list archive)
State New, archived
Headers show
Series add support for stateless encoder | expand

Commit Message

Dafna Hirschfeld March 30, 2019, 8:43 p.m. UTC
From: Hans Verkuil <hverkuil-cisco@xs4all.nl>

Only set first_source_change_sent for decoders.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
---
 drivers/media/platform/vicodec/vicodec-core.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/media/platform/vicodec/vicodec-core.c b/drivers/media/platform/vicodec/vicodec-core.c
index 7e4ac412cc38..ba327512e085 100644
--- a/drivers/media/platform/vicodec/vicodec-core.c
+++ b/drivers/media/platform/vicodec/vicodec-core.c
@@ -1521,7 +1521,8 @@  static void vicodec_buf_queue(struct vb2_buffer *vb)
 	 * handled in job_ready
 	 */
 	if (vb2_is_streaming(vq_cap) && vb2_is_streaming(vq_out)) {
-		ctx->first_source_change_sent = true;
+		if (!ctx->is_enc)
+			ctx->first_source_change_sent = true;
 		v4l2_m2m_buf_queue(ctx->fh.m2m_ctx, vbuf);
 		return;
 	}