Call yield() while waiting for USB control transfers to complete.
authorKevin O'Connor <kevin@koconnor.net>
Sat, 31 Oct 2009 17:55:59 +0000 (13:55 -0400)
committerKevin O'Connor <kevin@koconnor.net>
Sat, 31 Oct 2009 17:55:59 +0000 (13:55 -0400)
src/usb-ohci.c
src/usb-uhci.c

index 15841dc208c4cd2a6b84684f8e9ada8df38d007a..b62090f5f8cd8756635ce8d4651763b81e888830 100644 (file)
@@ -185,7 +185,7 @@ wait_ed(struct ohci_ed *ed)
             dprintf(1, "Timeout on wait_ed %p\n", ed);
             return -1;
         }
-        cpu_relax();
+        yield();
     }
 }
 
index cc01234ec50382f4333633836dc7a34f38781d91..64531a920c806e8275a486517d41ced24f62fcfe 100644 (file)
@@ -166,7 +166,7 @@ wait_qh(struct usb_s *cntl, struct uhci_qh *qh)
                     , inw(cntl->uhci.iobase + USBSTS));
             return -1;
         }
-        cpu_relax();
+        yield();
     }
 }