-
David Brownell authored
This USB patch updates the OHCI driver: - converts to relying on td_list shadowing the hardware's schedule; only collecting the donelist needs dma_to_td(), and td list handling works much like EHCI or UHCI. - leaves faulted endpoint queues (bulk/intr) disabled until the relevant drivers had a chance to clean up. - fixes minor bugs (unreported) in the affected code: * byteswap problem when unlinking urbs ... symptom would be data toggle confusion (since 2.4.2x) on big-endian cpus * latent bug if folk unlinked queue in LIFO order, not FIFO - removes unnecessary debug code; mostly de-BUG()ged The interesting fix is the "leave queues halted" one. As discussed on email a while back, this HCD fault handling policy (also followed by EHCI) is sufficient to let device drivers implement the two key fault handling policies that seem to be necessary: (a) Datagram style, where issues on one I/O won't affect the next unless the device halted the endpoint. The device driver can ignore most errors other than -EPIPE. (b) Stream style, where for example it'd be wrong to ever let block N+1 overwrite block N on the disk. Once the first URB fails, the rest would just be unlinked in the completion handler. As a consequence of using the td_list, you can now see urb queuing in action in the driverfs 'async' file. At least, if you look at the right time, or use drivers (networking, etc) that queue (bulk) reads for a long time.
65e2da7e