提交 24465b44 编写于 作者: S Steven Toth 提交者: Mauro Carvalho Chehab

[media] cx23885: ensure video is streaming before allowing vbi to stream

Signed-off-by: NSteven Toth <stoth@kernellabs.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 af76e9f6
......@@ -1100,6 +1100,14 @@ static int vidioc_streamon(struct file *file, void *priv,
if (unlikely(!res_get(dev, fh, get_resource(fh))))
return -EBUSY;
/* Don't start VBI streaming unless vida streaming
* has already started.
*/
if ((fh->type == V4L2_BUF_TYPE_VBI_CAPTURE) &&
((cx_read(VID_A_DMA_CTL) & 0x11) == 0))
return -EINVAL;
return videobuf_streamon(get_queue(fh));
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册