Hi Moritz,

On Monday 24 March 2008, Moritz Barsnick wrote:
> Hi Laurent, UVCers,
>
> the quirks parameter was recently introduced to the linux-uvc module,
> and is very practical to knowingly force certain behavior.
>
> While I was and am fighting with the ยง%&#! behavior of the SPCA525 ASIC
> in my Logitech QuickCam Fusion 046d:08c1, I luckily came across the
> "reset" patches, kindly linked from the QC Team site[*]. And the
> patches seem to have helped me, but I'll follow up with more info once
> I'm sure whether it works.
>
> I understand why you don't want to make the hacked fixes default in the
> code (it has been stressed many times on the list), but while Logitech
> try to come up with a solution, perhaps a quirks based integration
> would allow many users not to have to patch the driver. The code would
> only become active if explicitly selected with a module parameter. I
> believe that this is what the quirks parameter is perfectly made for,
> and I consider it non-intrusive for the unknowing user.
>
> I have ported the two relevant patches:
> a) the reset patch as found in
>    http://lists.berlios.de/pipermail/linux-uvc-devel/2007-March/001476.html
>
> b) the reset + resubmit urb patch, probably by Evgeny, found in
>   
> https://lists.berlios.de/pipermail/linux-uvc-devel/2008-January/002830.html
> which adds a second mechanism to the first patch.

Resubmitting URBs should hopefully not be necessary anymore (and it didn't 
work most of the time anyway). Alan Stern wrote a patch for the EHCI 
scheduler that I posted to the list a bit earlier. Please test it if you run 
into -EN2LSYNC (-45) issues.

> Instead of making the code changes "absolute"/"final" or #ifdef'd, I
> made the sections depend on a corresponding quirks mask setting. (Note:
> these are new quirks only defined by module parameter, not the kind
> defined by default by the device model.)
>
> The patch is attached. It introduces two new quirks UVC_QUIRK_RESET
> (0x20, I would write it (1<<5)), and UVC_QUIRK_RESUBMIT_URB (0x40,
> better (1<<6)). The functionality is separated.
>
> The parameter quirks=32 has consistantly helped the initialization of
> my Logitech QuickCam (incl. safe behavior through plug/unplug,
> load/unload, start/stop of apps) on both my machines, and quirks=96 has
> helped on my laptop through consistent failures (to be confirmed). I'm
> not sure the reset urb section is needed on my desktop, I think that
> machine has always behaved fine once the UVC device could init itself.
> But activating the reset urb code via the quirk has not hurt either, as
> far as I can tell. Sorry, I don't want to sound like I want this code
> as default behavior - the opposite is the case! :-)
>
> Your opinion is welcomed.
>
> Patch is against SVN r195.
> I've tested with Logitech QuickCam Fusion on two machines, both USB 1.1
> and USB 2.0.
>
> Kind regards,
> and many thanks, especially to Laurent, Evgeny, and Michel,
> Moritz
>
> [*]
> http://www.quickcamteam.net/documentation/faq/logitech-webcam-linux-usb-inc
>ompatibilities

Harold Wheaton posted a patch similar to yours to the mailing list on March 
the 19th. Search the archives for a thread named "UVC patch update and 
results".

Could you please have a look at Harold's patch and at his latest message in 
the thread ? He proposed a simpler approach that seems to work for him. Could 
you test it on your systems ?

Best regards,

Laurent Pinchart
_______________________________________________
Linux-uvc-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/linux-uvc-devel

Reply via email to