diff options
author | Michal Sojka | 2014-09-24 22:43:19 +0200 |
---|---|---|
committer | Greg Kroah-Hartman | 2014-09-25 16:58:50 +0200 |
commit | 304f7e5e1d08fa2f5674c1323bd0ebd806c86b81 (patch) | |
tree | 0d69327f14a23a66061fc9d39dee1ec7c6b56932 /drivers/usb/chipidea | |
parent | 3fc2aa5522ab958374d93ef5d2e12df7ee233c91 (diff) |
usb: gadget: Refactor request completion
Use the recently introduced usb_gadget_giveback_request() in favor of
direct invocation of the completion routine.
All places in drivers/usb/ matching "[-.]complete(" were replaced with a
call to usb_gadget_giveback_request(). This was compile-tested with all
ARM drivers enabled and runtime-tested for musb.
Signed-off-by: Michal Sojka <sojka@merica.cz>
Acked-by: Felipe Balbi <balbi@ti.com>
Tested-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/chipidea')
-rw-r--r-- | drivers/usb/chipidea/udc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c index b8125aa64ad8..0444d3f8971a 100644 --- a/drivers/usb/chipidea/udc.c +++ b/drivers/usb/chipidea/udc.c @@ -627,7 +627,7 @@ __acquires(hwep->lock) if (hwreq->req.complete != NULL) { spin_unlock(hwep->lock); - hwreq->req.complete(&hwep->ep, &hwreq->req); + usb_gadget_giveback_request(&hwep->ep, &hwreq->req); spin_lock(hwep->lock); } } @@ -922,7 +922,7 @@ __acquires(hwep->lock) if ((hwep->type == USB_ENDPOINT_XFER_CONTROL) && hwreq->req.length) hweptemp = hwep->ci->ep0in; - hwreq->req.complete(&hweptemp->ep, &hwreq->req); + usb_gadget_giveback_request(&hweptemp->ep, &hwreq->req); spin_lock(hwep->lock); } } @@ -1347,7 +1347,7 @@ static int ep_dequeue(struct usb_ep *ep, struct usb_request *req) if (hwreq->req.complete != NULL) { spin_unlock(hwep->lock); - hwreq->req.complete(&hwep->ep, &hwreq->req); + usb_gadget_giveback_request(&hwep->ep, &hwreq->req); spin_lock(hwep->lock); } |