From: Trent Piepho Date: Sun, 29 Mar 2009 01:25:36 +0000 (-0300) Subject: V4L/DVB (11264): omap24xxcam: Remove buffer type check from vidioc_s/g_parm X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=020b882b1d34e8787658a15e00f2ea0d4651605b;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git V4L/DVB (11264): omap24xxcam: Remove buffer type check from vidioc_s/g_parm The v4l2-ioctl core now only allows buffer types for which the corresponding ->vidioc_try_fmt_xxx() methods are defined to be used in vidioc_(g|s)_parm. This driver only defines ->vidioc_try_fmt_vid_cap() so only VIDEO_CAPTURE buffers are allowed to be used with vidioc_s_parm() and vidioc_g_parm(). Cc: Sakari Ailus Signed-off-by: Trent Piepho Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/omap24xxcam.c b/drivers/media/video/omap24xxcam.c index 2cea7fee9b51..5fc4ac0d88f0 100644 --- a/drivers/media/video/omap24xxcam.c +++ b/drivers/media/video/omap24xxcam.c @@ -1285,9 +1285,6 @@ static int vidioc_g_parm(struct file *file, void *fh, struct omap24xxcam_device *cam = ofh->cam; int rval; - if (a->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) - return -EINVAL; - mutex_lock(&cam->mutex); rval = vidioc_int_g_parm(cam->sdev, a); mutex_unlock(&cam->mutex); @@ -1303,9 +1300,6 @@ static int vidioc_s_parm(struct file *file, void *fh, struct v4l2_streamparm old_streamparm; int rval; - if (a->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) - return -EINVAL; - mutex_lock(&cam->mutex); if (cam->streaming) { rval = -EBUSY;