Source-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: src/sys
Module Name: src
Committed By: riastradh
Date: Wed Feb 12 16:01:00 UTC 2020
Modified Files:
src/sys/arch/mips/adm5120/dev: ahci.c
src/sys/dev/usb: ehci.c motg.c ohci.c uhci.c usbdi.c usbdi.h usbdivar.h
xhci.c
src/sys/external/bsd/dwc2: dwc2.c dwc2var.h
Log Message:
Factor out HCI-independent xfer completion logic.
New API for HCI drivers to synchronize hardware completion
interrupts, synchronous aborts, and asynchronous timeouts:
- When submitting an xfer to hardware, call
usbd_xfer_schedule_timeout(xfer).
- On HCI completion interrupt for xfer completion:
if (!usbd_xfer_trycomplete(xfer))
return; /* timed out or aborted, ignore it */
- In upm_abort methods, call usbd_xfer_abort(xfer).
For HCI drivers that use this API (not needed in drivers that don't,
or for xfers like root intr xfers that don't use it):
- New ubm_abortx method serves role of former *hci_abort_xfer, but
without any logic for wrangling timeouts/callouts/tasks -- caller
in usbd_xfer_abort has already handled them.
- New ubm_dying method, returns true if the device is in the process
of detaching, used by the timeout logic.
Converted and tested:
- ehci
- ohci
Converted and compile-tested:
- ahci (XXX did this ever work?)
- dwc2
- motg (XXX missing usbd_xfer_schedule_timeout in motg_*_start?)
- uhci
- xhci
Not changed:
- slhci (sys/dev/ic/sl811hs.c) -- doesn't use a separate per-xfer
callout for timeouts (XXX but maybe should?)
- ugenhc (sys/rump/dev/lib/libugenhc/ugenhc.c) -- doesn't manage its
own transfer timeouts
- vhci -- times transfers out only on detach; could be adapted easily
if we wanted to use the xfer->ux_callout
To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/mips/adm5120/dev/ahci.c
cvs rdiff -u -r1.270 -r1.271 src/sys/dev/usb/ehci.c
cvs rdiff -u -r1.25 -r1.26 src/sys/dev/usb/motg.c
cvs rdiff -u -r1.292 -r1.293 src/sys/dev/usb/ohci.c
cvs rdiff -u -r1.288 -r1.289 src/sys/dev/usb/uhci.c
cvs rdiff -u -r1.191 -r1.192 src/sys/dev/usb/usbdi.c
cvs rdiff -u -r1.100 -r1.101 src/sys/dev/usb/usbdi.h
cvs rdiff -u -r1.121 -r1.122 src/sys/dev/usb/usbdivar.h
cvs rdiff -u -r1.115 -r1.116 src/sys/dev/usb/xhci.c
cvs rdiff -u -r1.66 -r1.67 src/sys/external/bsd/dwc2/dwc2.c
cvs rdiff -u -r1.6 -r1.7 src/sys/external/bsd/dwc2/dwc2var.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Home |
Main Index |
Thread Index |
Old Index