diff options
author | Philipp Zabel <p.zabel@pengutronix.de> | 2019-06-18 19:45:24 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2019-06-24 21:36:14 +0300 |
commit | 1b438b454085238b44875ac6cd508fc1106f07d1 (patch) | |
tree | 39f943cfd014e4b4b5875438fe3530db9170ad34 /drivers/media/platform/coda/coda-bit.c | |
parent | aa3972a358b6f13b482975152e3fa449b7a32974 (diff) | |
download | linux-1b438b454085238b44875ac6cd508fc1106f07d1.tar.xz |
media: coda: mark the last output buffer on decoder stop command
Mark the last output buffer to be decoded and only copy pending queued
output buffers into the bitstream ring buffer in the BIT processor
decoder case.
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/platform/coda/coda-bit.c')
-rw-r--r-- | drivers/media/platform/coda/coda-bit.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/platform/coda/coda-bit.c b/drivers/media/platform/coda/coda-bit.c index bfe6019e68a8..cbcec571a014 100644 --- a/drivers/media/platform/coda/coda-bit.c +++ b/drivers/media/platform/coda/coda-bit.c @@ -312,6 +312,9 @@ static bool coda_bitstream_try_queue(struct coda_ctx *ctx, if (ctx == v4l2_m2m_get_curr_priv(ctx->dev->m2m_dev)) coda_kfifo_sync_to_device_write(ctx); + /* Set the stream-end flag after the last buffer is queued */ + if (src_buf->flags & V4L2_BUF_FLAG_LAST) + coda_bit_stream_end_flag(ctx); ctx->hold = false; return true; |