aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/isp116x-hcd.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2007-08-21 15:39:21 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-10-12 17:55:19 -0400
commitb0d9efba3ec53468984aecef8eeaf079089f2e5a (patch)
treea372d053daddc5ff041949b80bab347317a76938 /drivers/usb/host/isp116x-hcd.c
parentee7d1f3f0c32d8abe9627aa73dc62ee5bf2daf7f (diff)
USB: centralize -EREMOTEIO handling
This patch (as969) continues the ongoing changes to the way HCDs report URB statuses. The programming interface has been simplified by making usbcore responsible for clearing urb->hcpriv and for setting -EREMOTEIO status when an URB with the URB_SHORT_NOT_OK flag ends up as a short transfer. By moving the work out of the HCDs, this removes a fair amount of repeated code. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> CC: David Brownell <david-b@pacbell.net> CC: Olav Kongas <ok@artecdesign.ee> CC: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com> CC: Tony Olech <tony.olech@elandigitalsystems.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/isp116x-hcd.c')
-rw-r--r--drivers/usb/host/isp116x-hcd.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/usb/host/isp116x-hcd.c b/drivers/usb/host/isp116x-hcd.c
index f2b5d6281c5d..c2919dbc3f54 100644
--- a/drivers/usb/host/isp116x-hcd.c
+++ b/drivers/usb/host/isp116x-hcd.c
@@ -282,7 +282,6 @@ __releases(isp116x->lock) __acquires(isp116x->lock)
282{ 282{
283 unsigned i; 283 unsigned i;
284 284
285 urb->hcpriv = NULL;
286 ep->error_count = 0; 285 ep->error_count = 0;
287 286
288 if (usb_pipecontrol(urb->pipe)) 287 if (usb_pipecontrol(urb->pipe))
@@ -446,12 +445,7 @@ static void postproc_atl_queue(struct isp116x *isp116x)
446 if (PTD_GET_ACTIVE(ptd) 445 if (PTD_GET_ACTIVE(ptd)
447 || (cc != TD_CC_NOERROR && cc < 0x0E)) 446 || (cc != TD_CC_NOERROR && cc < 0x0E))
448 break; 447 break;
449 if ((urb->transfer_flags & URB_SHORT_NOT_OK) && 448 status = 0;
450 urb->actual_length <
451 urb->transfer_buffer_length)
452 status = -EREMOTEIO;
453 else
454 status = 0;
455 ep->nextpid = 0; 449 ep->nextpid = 0;
456 break; 450 break;
457 default: 451 default: