Commit b058e3f3 authored by Rafael Diniz's avatar Rafael Diniz Committed by Mauro Carvalho Chehab

V4L/DVB (9368): VBI fix for cx88 cards

The attached patch fix VBI support cx88 card.
I'm running a capture for hours, getting the closed caption from it[1], and
it's working perfect - the output is the same of a bttv card.
Please apply this patch as soon as possible.

[1] - using zvbi-ntsc-cc of zvbi project.
Signed-off-by: default avatarRafael Diniz <diniz@wimobilis.com.br>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent e8deeae2
......@@ -1216,8 +1216,12 @@ static int vidioc_streamon(struct file *file, void *priv, enum v4l2_buf_type i)
struct cx8800_fh *fh = priv;
struct cx8800_dev *dev = fh->dev;
if (unlikely(fh->type != V4L2_BUF_TYPE_VIDEO_CAPTURE))
/* We should remember that this driver also supports teletext, */
/* so we have to test if the v4l2_buf_type is VBI capture data. */
if (unlikely((fh->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) &&
(fh->type != V4L2_BUF_TYPE_VBI_CAPTURE)))
return -EINVAL;
if (unlikely(i != fh->type))
return -EINVAL;
......@@ -1232,8 +1236,10 @@ static int vidioc_streamoff(struct file *file, void *priv, enum v4l2_buf_type i)
struct cx8800_dev *dev = fh->dev;
int err, res;
if (fh->type != V4L2_BUF_TYPE_VIDEO_CAPTURE)
if ((fh->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) &&
(fh->type != V4L2_BUF_TYPE_VBI_CAPTURE))
return -EINVAL;
if (i != fh->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