On Tuesday 04 February 2003 22:53, David Brownell wrote:
> Duncan Sands wrote:
> > (1) is there any speed advantage to submitting multiple urbs to
> > a bulk endpoint, as compared to using a single urb which is
> > resubmitted in its completion handler?
>
> Yes, most noticeably at high speed where the time to report
> the completion and resubmit the urb can easily be enough time
> to transfer tens of kbytes.  For full speed devices, that same
> delay would cost maybe 256 bytes of wasted throughput.

Hi Dave, thanks for your reply.  This is a full speed device
(speedtouch modem).  Hmmm, 256 bytes is about 4% for
me.  Is the above wastage estimate based on a completion
handler that does nothing but resubmit (i.e. zero wasted
cycles)?  If there are other usb devices competing for
bandwidth, this will only get worse, right?

> Example:  in 2.5 usb-storage uses new usb_sg_*() primitives,
> and a simple "hdparm -tT /dev/sda1" easily shows transfer
> rates doubling (or more, depending on the hardware).

I will look into it, thanks.

> > (2) is there a noticeable speed difference if you send a buffer
> > in many small pieces (-> many urb submissions) as compared
> > to sending it in one big piece (-> one urb submission)?
>
> Passing N times through the code, rather than one, will take
> more CPU time ... likely not not significant on its own, but
> other factors may come into play.  Like queueing, the costs
> of DMA mapping buffers (talk to IOMMU?), the costs of merging
> into a single buffer, and so on.

I was thinking of the costs of setting up the DMA etc, i.e. USB subsystem
costs - are they significant?

> You may need to merge buffers to make sure packet boundaries
> appear only in places it's OK for your protocol, though.

It's OK, I already did all that.

Ciao, Duncan.


-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to