1
0
Fork 0

Revert "media: v4l2-ioctl: clear fields in s_parm"

This reverts commit 8a7c5594c0.
5.4-rM2-2.2.x-imx-squashed
Robby Cai 2019-11-16 16:21:31 +08:00 committed by Dong Aisheng
parent 6e652a1d50
commit 11c8df0cde
1 changed files with 1 additions and 16 deletions

View File

@ -2066,22 +2066,7 @@ static int v4l_s_parm(const struct v4l2_ioctl_ops *ops,
struct v4l2_streamparm *p = arg;
int ret = check_fmt(file, p->type);
if (ret)
return ret;
/* Note: extendedmode is never used in drivers */
if (V4L2_TYPE_IS_OUTPUT(p->type)) {
memset(p->parm.output.reserved, 0,
sizeof(p->parm.output.reserved));
p->parm.output.extendedmode = 0;
p->parm.output.outputmode &= V4L2_MODE_HIGHQUALITY;
} else {
memset(p->parm.capture.reserved, 0,
sizeof(p->parm.capture.reserved));
p->parm.capture.extendedmode = 0;
p->parm.capture.capturemode &= V4L2_MODE_HIGHQUALITY;
}
return ops->vidioc_s_parm(file, fh, p);
return ret ? ret : ops->vidioc_s_parm(file, fh, p);
}
static int v4l_queryctrl(const struct v4l2_ioctl_ops *ops,