aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/platform/s5p-mfc/s5p_mfc.c
diff options
context:
space:
mode:
authorKamil Debski <k.debski@samsung.com>2013-01-11 12:29:33 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-04-12 12:38:56 -0300
commita34026e75bd1e6fdfbe8b59c320bb7d31c84b3da (patch)
treef41f223c059238337befc5145456a7310d3f623d /drivers/media/platform/s5p-mfc/s5p_mfc.c
parent81e096c8ac6a064854c2157e0bf802dc4906678c (diff)
downloadlinaro-lsk-a34026e75bd1e6fdfbe8b59c320bb7d31c84b3da.tar.gz
[media] s5p-mfc: Add support for EOS command and EOS event in video decoder
Add support for V4L2_DEC_CMD_STOP command which will instruct MFC device to finish decoding and release all remaining frames kept for reference to the user. After dequeueing last decoded frame the driver will generate an V4L2_EVENT_EOS event. Signed-off-by: Kamil Debski <k.debski@samsung.com> Signed-off-by: Kyngmin Park <kyungmin.park@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/platform/s5p-mfc/s5p_mfc.c')
-rw-r--r--drivers/media/platform/s5p-mfc/s5p_mfc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c b/drivers/media/platform/s5p-mfc/s5p_mfc.c
index 7379dc6dbeb..f608b7761be 100644
--- a/drivers/media/platform/s5p-mfc/s5p_mfc.c
+++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c
@@ -386,6 +386,8 @@ static void s5p_mfc_handle_frame(struct s5p_mfc_ctx *ctx,
} else {
mfc_debug(2, "MFC needs next buffer\n");
ctx->consumed_stream = 0;
+ if (src_buf->flags & MFC_BUF_FLAG_EOS)
+ ctx->state = MFCINST_FINISHING;
list_del(&src_buf->list);
ctx->src_queue_cnt--;
if (s5p_mfc_hw_call(dev->mfc_ops, err_dec, err) > 0)