From: Hans Verkuil Date: Fri, 5 Jun 2015 08:11:14 +0000 (-0300) Subject: [media] v4l2-ioctl: clear the reserved field of v4l2_create_buffers X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5d3512514ae7e21e869ea306f902b6be428e2578;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [media] v4l2-ioctl: clear the reserved field of v4l2_create_buffers This field was never cleared by the kernel making future extensions hard to implement. Clear it now. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c index 691295984225..bbeb9ffd5e92 100644 --- a/drivers/media/v4l2-core/v4l2-ioctl.c +++ b/drivers/media/v4l2-core/v4l2-ioctl.c @@ -1805,6 +1805,8 @@ static int v4l_create_bufs(const struct v4l2_ioctl_ops *ops, if (ret) return ret; + CLEAR_AFTER_FIELD(create, format); + v4l_sanitize_format(&create->format); ret = ops->vidioc_create_bufs(file, fh, create);