]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[media] cx25821: remove cropping ioctls
authorHans Verkuil <hans.verkuil@cisco.com>
Sat, 13 Apr 2013 10:47:12 +0000 (07:47 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 16 Apr 2013 21:03:09 +0000 (18:03 -0300)
This driver does not implement cropping, so remove the cropping ioctls.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/pci/cx25821/cx25821-video.c

index 9e948eff6b88f2763580dd6dff723ede35b380c6..9919a0e93f4df7cfa5008759c7ba7993141e515d 100644 (file)
@@ -1396,47 +1396,6 @@ static void cx25821_init_controls(struct cx25821_dev *dev, int chan_num)
        }
 }
 
-static int cx25821_vidioc_cropcap(struct file *file, void *priv,
-                          struct v4l2_cropcap *cropcap)
-{
-       struct cx25821_dev *dev = ((struct cx25821_fh *)priv)->dev;
-
-       if (cropcap->type != V4L2_BUF_TYPE_VIDEO_CAPTURE)
-               return -EINVAL;
-       cropcap->bounds.top = 0;
-       cropcap->bounds.left = 0;
-       cropcap->bounds.width = 720;
-       cropcap->bounds.height = dev->tvnorm == V4L2_STD_PAL_BG ? 576 : 480;
-       cropcap->pixelaspect.numerator =
-               dev->tvnorm == V4L2_STD_PAL_BG ? 59 : 10;
-       cropcap->pixelaspect.denominator =
-               dev->tvnorm == V4L2_STD_PAL_BG ? 54 : 11;
-       cropcap->defrect = cropcap->bounds;
-       return 0;
-}
-
-static int cx25821_vidioc_s_crop(struct file *file, void *priv, const struct v4l2_crop *crop)
-{
-       struct cx25821_dev *dev = ((struct cx25821_fh *)priv)->dev;
-       struct cx25821_fh *fh = priv;
-       int err;
-
-       if (fh) {
-               err = v4l2_prio_check(&dev->channels[fh->channel_id].prio,
-                                     fh->prio);
-               if (0 != err)
-                       return err;
-       }
-       /* cx25821_vidioc_s_crop not supported */
-       return -EINVAL;
-}
-
-static int cx25821_vidioc_g_crop(struct file *file, void *priv, struct v4l2_crop *crop)
-{
-       /* cx25821_vidioc_g_crop not supported */
-       return -EINVAL;
-}
-
 static long video_ioctl_upstream9(struct file *file, unsigned int cmd,
                                 unsigned long arg)
 {
@@ -1713,9 +1672,6 @@ static const struct v4l2_ioctl_ops video_ioctl_ops = {
        .vidioc_dqbuf = vidioc_dqbuf,
        .vidioc_g_std = cx25821_vidioc_g_std,
        .vidioc_s_std = cx25821_vidioc_s_std,
-       .vidioc_cropcap = cx25821_vidioc_cropcap,
-       .vidioc_s_crop = cx25821_vidioc_s_crop,
-       .vidioc_g_crop = cx25821_vidioc_g_crop,
        .vidioc_enum_input = cx25821_vidioc_enum_input,
        .vidioc_g_input = cx25821_vidioc_g_input,
        .vidioc_s_input = cx25821_vidioc_s_input,