]> asedeno.scripts.mit.edu Git - linux.git/commit
media: ti-vpe: vpe: fix a v4l2-compliance warning about invalid pixel format
authorBenoit Parrot <bparrot@ti.com>
Mon, 7 Oct 2019 15:09:57 +0000 (12:09 -0300)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Thu, 10 Oct 2019 16:48:18 +0000 (13:48 -0300)
commit06bec72b250b2cb3ba96fa45c2b8e0fb83745517
treeb86356b5e5fad1406604eb052359c2bad3ff7319
parenta37980ac5be29b83da67bf7d571c6bd9f90f8e45
media: ti-vpe: vpe: fix a v4l2-compliance warning about invalid pixel format

v4l2-compliance warns with this message:

   warn: v4l2-test-formats.cpp(717): \
  TRY_FMT cannot handle an invalid pixelformat.
   warn: v4l2-test-formats.cpp(718): \
  This may or may not be a problem. For more information see:
   warn: v4l2-test-formats.cpp(719): \
  http://www.mail-archive.com/linux-media@vger.kernel.org/msg56550.html
...
   test VIDIOC_TRY_FMT: FAIL

We need to make sure that the returns a valid pixel format in all
instance. Based on the v4l2 framework convention drivers must return a
valid pixel format when the requested pixel format is either invalid or
not supported.

Signed-off-by: Benoit Parrot <bparrot@ti.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/platform/ti-vpe/vpe.c