lkml.org 
[lkml]   [2015]   [Nov]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/3] usb: dwc2: host: Giveback URB in tasklet context
On Wed, 4 Nov 2015, Doug Anderson wrote:

> In the ChromeOS gerrit
> <https://chromium-review.googlesource.com/#/c/310583/> Julius Werner
> points out that for EHCI it was good to take the optimization from
> commit 9118f9eb4f1e ("USB: EHCI: improve interrupt qh unlink") before
> this one. I'm still trying to learn USB / dwc2 so it's unclear to me
> whether we also need a similar change before landing.
>
> I'll see if I can do some investigation about this and also some
> benchmarking before and after. Certainly profiling the interrupt
> handler itself showed a huge improvement, but I'd hate to see a
> regression elsewhere.
>
> If anyone else knows better than I, please speak up! :)

This is a matter of both efficiency and correctness. Giving back URBs
in a tasklet is not a simple change.

Have you read the kerneldoc for usb_submit_urb() in
drivers/usb/core/urb.c? The portion about "Reserved Bandwidth
Transfers" is highly relevant. I don't know how dwc2 goes about
reserving bandwidth for periodic transfers, but if it relies on the
endpoint queue being non-empty to maintain a reservation then it will
be affected by this change.

Alan Stern



\
 
 \ /
  Last update: 2015-11-05 16:41    [W:0.077 / U:0.136 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site