Em Fri, 25 Jan 2013 14:42:59 +0100 Hans Verkuil <hverkuil@xxxxxxxxx> escreveu: > On Fri January 25 2013 14:40:45 Hans de Goede wrote: > > Hi, > > > > On 01/25/2013 11:40 AM, Hans Verkuil wrote: > > > > <snip> > > > > >> What I did notice is that pwc_vidioc_try_fmt returns EINVAL when > > >> an unsupported pixelformat is requested. IIRC we agreed that the > > >> correct behavior in this case is to instead just change the > > >> pixelformat to a default format, so I'll write a patch fixing > > >> this. > > > > > > There are issues with that idea in the case of TV capture cards, since > > > some important apps (tvtime and mythtv to a lesser extent) assume -EINVAL > > > in the case of unsupported pixelformats. > > > > Oh, I thought we agreed on never returning EINVAL accept for on invalid > > buffer types in Barcelona ? > > We did, but then it was discovered that apps like tvtime *rely* on such an > error code. Yes. Basically, tvtime and MythTV rely on receiving an error when the format is not supported (I think they accept if the driver changes resolution and interleaving mode, though). Xawtv (and likely the other apps that use its code as a reference) will accept if the driver would change the video format to one that it is actually supported. > > All TV capture drivers that do stream I/O return EINVAL for unsupported > formats today. There are exceptions (cx18/ivtv/pvrusb2 (?)), but those > have a read() API only. > > Very annoying... > > Regards, > > Hans -- Cheers, Mauro -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html