]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/usb/host/ehci-q.c
USB: centralize -EREMOTEIO handling
[mv-sheeva.git] / drivers / usb / host / ehci-q.c
index 1da2de4d34edce8d4efee12626a0a1499ebab492..e80b5c417d743d59b358a51a9e7f6c7df4279c8a 100644 (file)
@@ -232,7 +232,6 @@ __acquires(ehci->lock)
        }
 
        spin_lock (&urb->lock);
-       urb->hcpriv = NULL;
        switch (urb->status) {
        case -EINPROGRESS:              /* success */
                urb->status = 0;
@@ -395,8 +394,10 @@ halt:
                /* remove it from the queue */
                spin_lock (&urb->lock);
                qtd_copy_status (ehci, urb, qtd->length, token);
-               do_status = (urb->status == -EREMOTEIO)
-                               && usb_pipecontrol (urb->pipe);
+               if (unlikely(urb->status == -EREMOTEIO)) {
+                       do_status = usb_pipecontrol(urb->pipe);
+                       urb->status = 0;
+               }
                spin_unlock (&urb->lock);
 
                if (stopped && qtd->qtd_list.prev != &qh->qtd_list) {