V4L/DVB: ivtv: switch to new vbi subdev ops
authorHans Verkuil <hverkuil@xs4all.nl>
Sun, 14 Mar 2010 15:18:18 +0000 (12:18 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Wed, 19 May 2010 15:58:49 +0000 (12:58 -0300)
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/ivtv/ivtv-ioctl.c
drivers/media/video/ivtv/ivtv-streams.c

index e95ebdeaa72f8e2e93f3d7bbcac9756ffdb71fc1..a17c659e6327d10a52b88a113ec02d7a2992a839 100644 (file)
@@ -392,7 +392,7 @@ static int ivtv_g_fmt_sliced_vbi_cap(struct file *file, void *fh, struct v4l2_fo
                return 0;
        }
 
-       v4l2_subdev_call(itv->sd_video, video, g_fmt, fmt);
+       v4l2_subdev_call(itv->sd_video, vbi, g_sliced_fmt, vbifmt);
        vbifmt->service_set = ivtv_get_service_set(vbifmt);
        return 0;
 }
@@ -598,7 +598,7 @@ static int ivtv_s_fmt_vbi_cap(struct file *file, void *fh, struct v4l2_format *f
                return -EBUSY;
        itv->vbi.sliced_in->service_set = 0;
        itv->vbi.in.type = V4L2_BUF_TYPE_VBI_CAPTURE;
-       v4l2_subdev_call(itv->sd_video, video, s_fmt, fmt);
+       v4l2_subdev_call(itv->sd_video, vbi, s_raw_fmt, &fmt->fmt.vbi);
        return ivtv_g_fmt_vbi_cap(file, fh, fmt);
 }
 
@@ -616,7 +616,7 @@ static int ivtv_s_fmt_sliced_vbi_cap(struct file *file, void *fh, struct v4l2_fo
        if (ivtv_raw_vbi(itv) && atomic_read(&itv->capturing) > 0)
                return -EBUSY;
        itv->vbi.in.type = V4L2_BUF_TYPE_SLICED_VBI_CAPTURE;
-       v4l2_subdev_call(itv->sd_video, video, s_fmt, fmt);
+       v4l2_subdev_call(itv->sd_video, vbi, s_sliced_fmt, vbifmt);
        memcpy(itv->vbi.sliced_in, vbifmt, sizeof(*itv->vbi.sliced_in));
        return 0;
 }
index def507ee106ad3ce666bd923cc52cfebf508930a..de4288cc188933d6e4100fb162dcab9099a14238 100644 (file)
@@ -344,7 +344,10 @@ static void ivtv_vbi_setup(struct ivtv *itv)
        ivtv_vapi(itv, CX2341X_ENC_SET_VBI_LINE, 5, 0xffff , 0, 0, 0, 0);
 
        /* setup VBI registers */
-       v4l2_subdev_call(itv->sd_video, video, s_fmt, &itv->vbi.in);
+       if (raw)
+               v4l2_subdev_call(itv->sd_video, vbi, s_raw_fmt, &itv->vbi.in.fmt.vbi);
+       else
+               v4l2_subdev_call(itv->sd_video, vbi, s_sliced_fmt, &itv->vbi.in.fmt.sliced);
 
        /* determine number of lines and total number of VBI bytes.
           A raw line takes 1443 bytes: 2 * 720 + 4 byte frame header - 1