提交 fc391714 编写于 作者: B Benoit Parrot 提交者: Yang Yingliang

media: am437x-vpfe: Setting STD to current value is not an error

[ Upstream commit 13aa21cfe92ce9ebb51824029d89f19c33f81419 ]

VIDIOC_S_STD should not return an error if the value is identical
to the current one.
This error was highlighted by the v4l2-compliance test.
Signed-off-by: NBenoit Parrot <bparrot@ti.com>
Acked-by: NLad Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: NHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: NMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
上级 da592587
...@@ -1848,6 +1848,10 @@ static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id std_id) ...@@ -1848,6 +1848,10 @@ static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id std_id)
if (!(sdinfo->inputs[0].capabilities & V4L2_IN_CAP_STD)) if (!(sdinfo->inputs[0].capabilities & V4L2_IN_CAP_STD))
return -ENODATA; return -ENODATA;
/* if trying to set the same std then nothing to do */
if (vpfe_standards[vpfe->std_index].std_id == std_id)
return 0;
/* If streaming is started, return error */ /* If streaming is started, return error */
if (vb2_is_busy(&vpfe->buffer_queue)) { if (vb2_is_busy(&vpfe->buffer_queue)) {
vpfe_err(vpfe, "%s device busy\n", __func__); vpfe_err(vpfe, "%s device busy\n", __func__);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册