Oliver Neukum wrote:
Hi David,

as you might remember we discussed moving memory allocations from
the usb_submit_urb() path to usb_alloc_urb() to speed up the former
codepath.

Yes, there can be both controller-specific (urb->hcpriv) allocations and transfer-specific ones (a TD, sometimes more than one).


Should an URB be bound to a specific device, or to an endpoint at
allocation time?

The gadget API successfully moved all such allocations out of the submit path into usb_ep_alloc_request().

That binds to an endpoint at allocation time, and none of the
current controller drivers need additional allocations on the
submit path.  Plus, usb_ep_queue() is lighter weight than the
usb_submit_urb() call in other ways too:  much less dispatch
overhead, and less work in completion paths too.

By design, most of that same API should be usable on the host side,
given changes like having each usb_interface expose the "usb_ep"
structures associated with a current altsetting.  For example,
with OHCI it'd be natural to associate an ED with a "usb_ep"; and
with EHCI that would work well for a QH ... the "usb_request" could
pre-allocate one or (for control, or UHCI) more TDs.

I've not thought much about how to make URB calls get similar
improvements; they carry lots of excess baggage.

- Dave





Regards Oliver








-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to