On Wed, 15 Sep 2004, Nigel Metheringham wrote:

> For a long time now I have had real problems with USB bulk transfer
> stuff (anything that moves reasonable amounts of data to mass storage
> devices and gnomad2 - an interface to a Creative Zen mp3 player, not
> using a mass storage interface - has never worked right for me).
> 
> Finally a comment on a mailing list lead me to suspect the gnome-pilot
> daemon as the culprit.  Further testing has shown that if something is
> looping performing the following operations:-
>       * open /proc/bus/usb/devices
>       * stat the fh from above
>       * read fh
>       * close fh
>       * poll() on any filehandles (do not need to be USB related
>         - /dev/null works fine)
> then USB operations frequently fail with "control timeout on ep0in" - as
> has been reported on the linux-usb-users list:-
>   http://www.mail-archive.com/[EMAIL PROTECTED]/msg11221.html
> 
> I've attached a little bit of perl which is the smallest bit of code I
> have got that reproduces this effect (it does a deliberate stat() on the
> filehandle - that appears to be needed.  I did think about removing the
> stat() from the gnome-pilot code as a workround, but the stat() is
> implicit as part of the internals of fopen() apparently).  Obviously you
> need to do some USB data transfer operation whilst the perl code is
> running.
> 
> I have seen this problem previously with 2.4.x kernels, I currently see
> it with 2.6.8 (Fedora 2 build - kernel-2.6.8-1.521 i686 arch) and have
> in hindsight never seen bulk USB transfers work on a box where gnome-
> pilot (or rather gpilotd) is running.
> 
> Its going to be a real fun bug to pin down....
> 
>         Nigel.

Not at all, we already know exactly what the problem is.  It's a bug in 
the storage device -- the device can't handle a standard request (of the 
sort send by the /proc/bus/usb/devices driver when reading a device string 
for the Vendor, Product, or Serial number) while the device is in the 
middle of a mass storage data transfer.  Devices are supposed to be able 
to do this; it's the equivalent of walking and chewing gum at the same 
time.  But some can't, and when asked to they simply fail.

So far nobody has come up with a really good solution.  There's nothing 
illegal about making these other requests during a data transfer, and 
plenty of devices can handle them just fine.  So we don't want to rule 
them out.  But in the end maybe we'll have to.

Alan Stern




-------------------------------------------------------
This SF.Net email is sponsored by: thawte's Crypto Challenge Vl
Crack the code and win a Sony DCRHC40 MiniDV Digital Handycam
Camcorder. More prizes in the weekly Lunch Hour Challenge.
Sign up NOW http://ad.doubleclick.net/clk;10740251;10262165;m
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to