qemu-e2k/hw/usb
Sebastian Bauer 7c48b95df4 ohci: Clear the interrupt counter for erroneous transfers
This is mandated by the ohci specification. It tells at 6.4.4 on page 104
that for transfer descriptors that are retired with an error the done
queue interrupt counter is cleared as if the interrupt delay field of the
descriptions were zero.

Before this change, error conditions were handled similarly to the
successful condition which is especially troublesome for control transfers.
Some drivers (e.g., the AmigaOS-one) as well as the example code in the
spec, set the setup stage with an interrupt delay of seven (which means no
interrupt). This is fine under normal conditions, because one usually
doesn't want to be notified about the completion of this stage. However, if
an error occurs in this stage, these drivers will not get notified with the
current implementation. The fix addresses this by following the spec more
closely. Also, otherwise, the ability to set interrupt delay to seven would
be useless.

Note that Linux drivers that I looked at don't seem to be affected as they
set six as the interrupt delay presumably for the reason that they won't
get notified otherwise.

Signed-off-by: Sebastian Bauer <mail@sebastianbauer.info>
Message-id: 20180729191928.11254-1-mail@sebastianbauer.info
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-08-21 10:25:22 +02:00
..
Makefile.objs usb: Add basic code to emulate Chipidea USB IP 2018-02-09 10:40:30 +00:00
bus.c hmp-commands: Remove the deprecated usb_add and usb_del 2017-12-14 10:16:52 +00:00
ccid-card-emulated.c ccid-card: include libcacard.h only 2018-04-27 10:57:09 +02:00
ccid-card-passthru.c hw/usb: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
ccid.h usb-ccid: convert CCIDCardClass::exitfn() -> unrealize() 2018-01-26 07:59:33 +01:00
chipidea.c usb: Add basic code to emulate Chipidea USB IP 2018-02-09 10:40:30 +00:00
combined-packet.c hw/usb: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
core.c usb: don't wakeup during coldplug 2017-05-29 14:18:09 +02:00
desc-msos.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
desc.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
desc.h all: Clean up includes 2016-02-23 12:43:05 +00:00
dev-audio.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-bluetooth.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-hid.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-hub.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-mtp.c usb-mtp: Return error on suspicious TYPE_DATA packet from initiator 2018-06-12 12:08:12 +02:00
dev-network.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-serial.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
dev-smartcard-reader.c hw/usb: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
dev-storage.c block: Remove deprecated -drive option serial 2018-08-15 12:50:39 +02:00
dev-uas.c Revert "usb: release the created buses" 2018-06-18 09:15:51 +02:00
dev-wacom.c usb: use local path for local headers 2018-06-01 19:20:38 +03:00
hcd-ehci-pci.c pci: Add INTERFACE_CONVENTIONAL_PCI_DEVICE to Conventional PCI devices 2017-10-15 05:54:43 +03:00
hcd-ehci-sysbus.c ehci: Add ppc4xx-ehci for the USB 2.0 controller in embedded PPC SoCs 2017-09-27 13:05:41 +10:00
hcd-ehci.c ehci: Don't fetch a NULL current qtd but advance the queue instead. 2018-07-03 09:49:44 +02:00
hcd-ehci.h ehci: Add ppc4xx-ehci for the USB 2.0 controller in embedded PPC SoCs 2017-09-27 13:05:41 +10:00
hcd-musb.c Replace all occurances of __FUNCTION__ with __func__ 2018-01-22 09:46:18 +01:00
hcd-ohci.c ohci: Clear the interrupt counter for erroneous transfers 2018-08-21 10:25:22 +02:00
hcd-uhci.c pci: Add INTERFACE_CONVENTIONAL_PCI_DEVICE to Conventional PCI devices 2017-10-15 05:54:43 +03:00
hcd-xhci-nec.c xhci: split into multiple files 2017-05-29 14:03:35 +02:00
hcd-xhci.c xhci: fix guest-triggerable assert 2018-07-03 09:50:39 +02:00
hcd-xhci.h xhci: split into multiple files 2017-05-29 14:03:35 +02:00
host-libusb.c usb-host: skip open on pending postload bh 2018-05-07 11:10:42 +02:00
host-stub.c usb: Remove legacy -usbdevice options (host, serial, disk and net) 2018-01-26 07:15:08 +01:00
host.h usb-host: move legacy cmd line bits 2013-02-19 12:30:05 +01:00
libhw.c usb: Clean up includes 2016-01-29 15:07:23 +00:00
quirks-ftdi-ids.h usbredir: Add support for buffered bulk input (v2) 2013-01-08 10:56:58 +01:00
quirks-pl2303-ids.h usbredir: Add support for buffered bulk input (v2) 2013-01-08 10:56:58 +01:00
quirks.c usb: Clean up includes 2016-01-29 15:07:23 +00:00
quirks.h usbredir: Add support for buffered bulk input (v2) 2013-01-08 10:56:58 +01:00
redirect.c hw/usb: Use the IEC binary prefix definitions 2018-07-02 15:41:16 +02:00
trace-events trace-events: fix code style: print 0x before hex numbers 2017-08-01 12:13:07 +01:00
tusb6010.c hw/usb/tusb6010: Convert away from old_mmio 2018-05-04 18:05:50 +01:00
xen-usb.c xen: remove other open-coded use of libxengnttab 2018-05-22 11:43:21 -07:00