media: coda: fix unset field and fail on invalid field in buf_prepare
authorPhilipp Zabel <p.zabel@pengutronix.de>
Fri, 12 Apr 2019 15:51:35 +0000 (11:51 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Wed, 8 May 2019 17:58:20 +0000 (13:58 -0400)
commit583958cba72ffd092e9e3c8a8a284cb154c34b1c
tree42f766db0a0da58a01963f1a79c0109333af4333
parent1e4e25c4959c10728fbfcc6a286f9503d32dfe02
media: coda: fix unset field and fail on invalid field in buf_prepare

v4l2-compliance likes to queue a buffer with field set to V4L2_FIELD_ANY
and expects it to be returned corrected to a valid field.

Follow vicodec in handling this in the buf_prepare callback.

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/platform/coda/coda-common.c