[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 <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
This commit is contained in:
Hans Verkuil 2015-06-05 05:11:14 -03:00 committed by Mauro Carvalho Chehab
parent afeef4ee23
commit 5d3512514a
1 changed files with 2 additions and 0 deletions

View File

@ -1805,6 +1805,8 @@ static int v4l_create_bufs(const struct v4l2_ioctl_ops *ops,
if (ret) if (ret)
return ret; return ret;
CLEAR_AFTER_FIELD(create, format);
v4l_sanitize_format(&create->format); v4l_sanitize_format(&create->format);
ret = ops->vidioc_create_bufs(file, fh, create); ret = ops->vidioc_create_bufs(file, fh, create);