On Mon, 11 Dec 2006, Ilyes Gouta wrote:

> Hi!
> 
> Thank you very much, Alan, for your answers!
> 
> I'm going to carry out more experiments on the 256 ISOC packets issue
> tonight and I'll keep you updated. However, I'm pretty sure that
> Linux's USB stack

You shouldn't talk about "Linux's USB stack".  The fact is, different 
drivers are involved depending on whether you use ehci-hcd, ohci-hcd, or 
uhci-hcd.  Each has its own limitations.

> can't handle ISOC URBs that would point on a large
> data buffer, for example an URB w/ ISOC 256 packets, 3072 bytes each
> (so that makes 3072 * 256 bytes, which Windows can handle).

Wrong.  The size of the data buffer doesn't matter at all.  However there
_are_ scheduling restrictions in each of the drivers, like how far into
the future the driver can schedule ISO transactions.

Of course, here you're talking about a 768 KB data buffer.  In general you
shouldn't count on being able to allocate such a large amount of kernel
memory as a single contiguous buffer.  But if you can do it, the sheer
size won't affect anything -- it will work just as well as an URB
containing 256 4-byte packets.

> And yes, I'm using usb_set_interface to select an alternate setting
> for the interface that's supposed to enable the ISOC transfers.
> 
> I got another question! :)
> 
> Is it possible that a USB 2.0 device (my webcam) won't able to return
> any data because the host is submitting too many ISOC URBs in a fast
> pace?

You're making the same mistake as before.  The device doesn't know
anything about URBs; all it knows about are packets.  It doesn't know or
care how fast URBs are submitted; it cares only how fast it is asked to 
send a packet.  If you schedule ISO transactions at the speed given in the 
endpoint's descriptor then the device should be able to handle the 
transfers.

>  Is it possible that the device would stall or reply partially to
> the request (for example, won't send/dump the entire picture and would
> restart from the beginning)?

A device can do anything it wants.  But if you use it as it was designed 
to be used, then it should function properly.

Alan Stern


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to