1
0
Fork 0

media: v4l2-ioctl.c: OR flags in v4l_fill_fmtdesc(), not don't overwrite

If a driver sets a FMT flag in the enum_fmt op, then that will be
ignored since v4l_fill_fmtdesc() overwrites it again.

v4l_fill_fmtdesc() should OR its flag, not overwrite it.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
alistair/sunxi64-5.4-dsi
Hans Verkuil 2019-07-24 07:27:03 -04:00 committed by Mauro Carvalho Chehab
parent 3ac52d0d21
commit 7c490e2561
1 changed files with 1 additions and 1 deletions

View File

@ -1395,7 +1395,7 @@ static void v4l_fill_fmtdesc(struct v4l2_fmtdesc *fmt)
if (descr)
WARN_ON(strscpy(fmt->description, descr, sz) < 0);
fmt->flags = flags;
fmt->flags |= flags;
}
static int v4l_enum_fmt(const struct v4l2_ioctl_ops *ops,