Commit d67005b7 authored by Ming Qian's avatar Ming Qian Committed by Mauro Carvalho Chehab

media: amphion: G/S_PARM only for encoder's output queue

G/S_PARM doesn't make sense for the capture queue of a stateful encoder,
unless V4L2_FMT_FLAG_ENC_CAP_FRAME_INTERVAL is set to reserve hardware
resources.

Otherwise it will fail the v4l2-compliance
Signed-off-by: default avatarMing Qian <ming.qian@nxp.com>
Signed-off-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
parent 81cad440
......@@ -283,6 +283,9 @@ static int venc_g_parm(struct file *file, void *fh, struct v4l2_streamparm *parm
if (!parm)
return -EINVAL;
if (!V4L2_TYPE_IS_OUTPUT(parm->type))
return -EINVAL;
if (!vpu_helper_check_type(inst, parm->type))
return -EINVAL;
......@@ -304,6 +307,9 @@ static int venc_s_parm(struct file *file, void *fh, struct v4l2_streamparm *parm
if (!parm)
return -EINVAL;
if (!V4L2_TYPE_IS_OUTPUT(parm->type))
return -EINVAL;
if (!vpu_helper_check_type(inst, parm->type))
return -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment