diff options
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/host/xhci-ring.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index 436332aa341b..70cacbbe7fb9 100644 --- a/drivers/usb/host/xhci-ring.c +++ b/drivers/usb/host/xhci-ring.c | |||
@@ -1768,9 +1768,6 @@ static int process_isoc_td(struct xhci_hcd *xhci, struct xhci_td *td, | |||
1768 | } | 1768 | } |
1769 | } | 1769 | } |
1770 | 1770 | ||
1771 | if ((idx == urb_priv->length - 1) && *status == -EINPROGRESS) | ||
1772 | *status = 0; | ||
1773 | |||
1774 | return finish_td(xhci, td, event_trb, event, ep, status, false); | 1771 | return finish_td(xhci, td, event_trb, event, ep, status, false); |
1775 | } | 1772 | } |
1776 | 1773 | ||
@@ -1788,8 +1785,7 @@ static int skip_isoc_td(struct xhci_hcd *xhci, struct xhci_td *td, | |||
1788 | idx = urb_priv->td_cnt; | 1785 | idx = urb_priv->td_cnt; |
1789 | frame = &td->urb->iso_frame_desc[idx]; | 1786 | frame = &td->urb->iso_frame_desc[idx]; |
1790 | 1787 | ||
1791 | /* The transfer is partly done */ | 1788 | /* The transfer is partly done. */ |
1792 | *status = -EXDEV; | ||
1793 | frame->status = -EXDEV; | 1789 | frame->status = -EXDEV; |
1794 | 1790 | ||
1795 | /* calc actual length */ | 1791 | /* calc actual length */ |
@@ -2177,6 +2173,11 @@ cleanup: | |||
2177 | urb->transfer_buffer_length, | 2173 | urb->transfer_buffer_length, |
2178 | status); | 2174 | status); |
2179 | spin_unlock(&xhci->lock); | 2175 | spin_unlock(&xhci->lock); |
2176 | /* EHCI, UHCI, and OHCI always unconditionally set the | ||
2177 | * urb->status of an isochronous endpoint to 0. | ||
2178 | */ | ||
2179 | if (usb_pipetype(urb->pipe) == PIPE_ISOCHRONOUS) | ||
2180 | status = 0; | ||
2180 | usb_hcd_giveback_urb(bus_to_hcd(urb->dev->bus), urb, status); | 2181 | usb_hcd_giveback_urb(bus_to_hcd(urb->dev->bus), urb, status); |
2181 | spin_lock(&xhci->lock); | 2182 | spin_lock(&xhci->lock); |
2182 | } | 2183 | } |