isp116x-hcd: prepare for urb->status
authorAlan Stern <stern@rowland.harvard.edu>
Thu, 12 Jul 2007 21:03:01 +0000 (17:03 -0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 20 Jul 2007 00:46:04 +0000 (17:46 -0700)
commit1b4cd43bd3f9aa7a794e29b80b0d984a8e144df4
tree668dab10c66128f107447612188e889716b4d5e2
parent10e485221edd2799dc495e4cde98fe74aeb292b1
isp116x-hcd: prepare for urb->status

This patch (as931b), adapted from a patch by Olav Kongas, makes a small
set of conservative changes to the isp116x-hcd driver in preparation
for the removal of urb->status.

finish_request() is moved up in the source and is called
as soon as the URB is known to have completed, rather than
after all the active endpoints have been scanned.

The status of a completed URB is kept in a local variable
and copied to urb->status only when the URB is about to be
given back.

-EREMOTEIO error status for control transfers is set after
the status stage rather than when the short packet arrives.

Some unnecessary uses of urb->lock are removed.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Cc: Olav Kongas <ok@artecdesign.ee>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/host/isp116x-hcd.c