V4L/DVB (11661): v4l2-ioctl: Check buffer types using g_fmt instead of try_fmt
authorTrent Piepho <xyzzy@speakeasy.org>
Fri, 1 May 2009 00:03:34 +0000 (21:03 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Sat, 9 May 2009 21:51:18 +0000 (18:51 -0300)
commit1175d6131f7a89c163227169325ca77a22b18cb2
tree27ddfa5c0925747267df57c3fca465e7fd969a75
parent171f48e254339548a910867c7a77c4a4d16e7e16
V4L/DVB (11661): v4l2-ioctl: Check buffer types using g_fmt instead of try_fmt

For a number of different ioctls, the v4l2-ioctl code checks that the
passed buffer type is supported by the driver.  It did this by checking
that the driver defined a method for the try_fmt handler for that buffer
type.  However, try_fmt is optional and a driver might not provide it even
though it does support that type.  So use g_fmt instead, since that isn't
optional.

This should fix a problem with VBI capture with saa7146.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/v4l2-ioctl.c