aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/usb
Commit message (Collapse)AuthorAgeFilesLines
* uhid(4): Don't read-ahead from the USB IN endpoint.Hans Petter Selasky38 hours1-0/+6
| | | | | | | | | This avoids an issue where IN endpoint data received from the device right before the file handle is closed, gets lost. PR: 263995 MFC after: 1 week Sponsored by: NVIDIA Networking
* XHCI: clear warm and port resetBjoern A. Zeeb9 days1-0/+15
| | | | | | | | | | It seems we do not clear UPS_C_BH_PORT_RESET and UPS_C_PORT_RESET conditions after warm or port reset. Add that code. Obtained from: an old patch mainly debugging other problems MFC after: 2 weeks Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D35483
* USB: add quirks to XHCIBjoern A. Zeeb9 days2-1/+9
| | | | | | | | | | | | | While XHCI is very generic some revisions of chipsets have problems. On dwc3 <= 3.00a Port Disable does not seem to work so we need to not enable it. For that introduce quirks to xhci so that controllers can steer certain features. I would hope that this is and remains the only one. Obtained from: an old patch mainly debugging other problems MFC after: 2 weeks Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D35482
* uchcom(4): Add new USB ID.Hans Petter Selasky13 days1-0/+1
| | | | | | | PR: 260783 PR: 264634 MFC after: 1 week Sponsored by: NVIDIA Networking
* upgt(4): Adjust all pause calls to use milliseconds instead of ticks.Hans Petter Selasky2022-06-091-2/+2
| | | | | MFC after: 1 week Sponsored by: NVIDIA Networking
* urtw(4): Adjust all pause calls to use milliseconds instead of ticks.Hans Petter Selasky2022-06-091-55/+61
| | | | | MFC after: 1 week Sponsored by: NVIDIA Networking
* usb: Remove unused devclass arguments to DRIVER_MODULE.John Baldwin2022-05-0689-287/+103
|
* Remove unused hidraw_devclass.John Baldwin2022-05-061-1/+1
|
* Remove unused miibus_devclass and miibus_fdt_devclass.John Baldwin2022-05-069-9/+9
|
* xhci(4): Tweak USB port speed checks to allow newer super speed generations.Hans Petter Selasky2022-05-041-2/+2
| | | | | | | This allows setting the U1 and U2 port timeout values. MFC after: 1 week Sponsored by: NVIDIA Networking
* xhci(4): Properly define all basic USB port speeds.Hans Petter Selasky2022-05-042-4/+8
| | | | | MFC after: 1 week Sponsored by: NVIDIA Networking
* xhci(4): Always add and evaluate the slot context.Hans Petter Selasky2022-05-031-1/+5
| | | | | | | | | Because the maximum number of endpoint contexts is stored there. Tested by: ehaupt@ PR: 262882 MFC after: 3 hours Sponsored by: NVIDIA Networking
* xhci(4): Only drop BULK and INTERRUPT endpoints to reset data toggle.Hans Petter Selasky2022-05-031-2/+9
| | | | | | | | | | Only drop BULK and INTERRUPT endpoints, to reset the data toggle, because for other endpoint types this is not critical. Tested by: ehaupt@ PR: 262882 MFC after: 3 hours Sponsored by: NVIDIA Networking
* uath(4): Fix incorrect byte-swapping and a buffer length check.Hans Petter Selasky2022-04-301-4/+3
| | | | | | | PR: 263638 Reported by: Jeff Gibbons <jgibbons@protogate.com> MFC after: 1 week Sponsored by: NVIDIA Networking
* Add USB ID and quirks for Huawei E3372Kornel Duleba2022-04-282-0/+3
| | | | | | | | | | | | | | | | Set UQ_MSC_NO_INQUIRY and UQ_MSC_NO_GETMAXLUN quirks for mass storage, which is the initial mode of this dongle. The modem is shipped with at least two firmware versions: 10.X and 11.X, without ability to update to the newer one. The 11.X version works more or less fine, but the 10.X one resets after receiving either an SCSI INQUIRY, or a get_max_lun command. Since both of those are used for automatic quirk detection, this leads to a reset cycle making the device somewhat unusable. Sponsored by: Stormshield Obtained from: Semihalf Reviewed by: hps, wma Differential Revision: https://reviews.freebsd.org/D35076
* usb: Respect NO_INQUIRY quirk during device enumerationKornel Duleba2022-04-281-2/+4
| | | | | | | | | | | | | Both usb_iface_is_cdrom and usb_msc_auto_quirk functions use SCSI INQUIRY command to probe various properties of usb mass storage devices. The problem here is that some very broken devices don't like this command. Check if UQ_MSC_NO_INQUIRY quirk is set and skip cdrom and quirk autodetection in that case. Sponsored by: Stormshield Obtained from: Semihalf Reviewed by: hps, wma Differential Revision: https://reviews.freebsd.org/D35075
* xhci(4): Ensure the so-called data toggle gets properly reset.Hans Petter Selasky2022-04-211-4/+23
| | | | | | | | | | | | | | | Use the drop and enable endpoint context commands to force a reset of the data toggle for USB 2.0 and USB 3.0 after: - clear endpoint halt command (when the driver wishes). - set config command (when the kernel or user-space wants). - set alternate setting command (only affected endpoints). Some XHCI HW implementations may not allow the endpoint reset command when the endpoint context is not in the halted state. Reported by: Juniper and Gary Jennejohn MFC after: 1 week Sponsored by: NVIDIA Networking
* uhid_snes: Remove USB_ST_TRANSFERRED handling for the status request.John Baldwin2022-04-181-9/+0
| | | | | | | | | | | | | | | | The result of the request computed in new_status was never returned to the caller leaving new_status as a set-but-unused variable. Removing new_status leaves sc->previous_status as a write-only variable. Removing sc->previous_status leaves current_status as a write-only variable, so it collapses down to removing the entire USB_ST_TRANSFERRED case. Arguably, all of the support for UHID_SNES_STATUS_DT_RD should be removed as it doesn't return anything to the caller. If the request should be fixed instead then this commit should be reverted and new_status should be returned to whoever submitted the request. Differential Revision: https://reviews.freebsd.org/D34840
* usb: Add a __usbdebug_used for variables only used under #ifdef USB_DEBUG.John Baldwin2022-04-135-4/+6
| | | | | Use it for various variables only used in DPRINTF debug traces conditional on USB_DEBUG.
* usb: Use __diagused for variables only used in KASSERT().John Baldwin2022-04-131-3/+3
|
* usb(4): Remove a double word in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/for for/for/ MFC after: 3 days
* usb: Remove some double words in source code commentsGordon Bergling2022-04-091-4/+4
| | | | | | - s/for for/for/ MFC after: 3 days
* usb(4): Fix two typos in source code commentsGordon Bergling2022-04-092-2/+2
| | | | | | - s/negotation/negotiation/ MFC after: 3 days
* ehci_imx: Remove unused variable.John Baldwin2022-04-091-2/+1
|
* atp: Remove unused variable.John Baldwin2022-04-081-2/+0
|
* if_urtw: Remove unused variables.John Baldwin2022-04-081-8/+6
|
* if_upgt: Remove unused variables.John Baldwin2022-04-081-6/+2
|
* uhci: Remove write-only variable.John Baldwin2022-04-061-2/+0
|
* ustorage_fs_verify: eliminate write only variables file_offset and file_offsetWarner Losh2022-04-051-8/+0
| | | | Sponsored by: Netflix
* mgue: eliminate write only variables ret, err and errorWarner Losh2022-04-051-13/+9
| | | | Sponsored by: Netflix
* cp2112iic_intr_write_callback: eliminate write only variable pscWarner Losh2022-04-051-2/+0
| | | | Sponsored by: Netflix
* wsp_intr_callback: eliminate write only variable hWarner Losh2022-04-051-3/+0
| | | | Sponsored by: Netflix
* uss820dci: eliminate unused variables sc, ep_noWarner Losh2022-04-051-7/+0
| | | | Sponsored by: Netflix
* uhci_xfer_setup: eliminate write only variable scWarner Losh2022-04-051-2/+0
| | | | Sponsored by: Netflix
* musb: eliminate write only variable scWarner Losh2022-04-051-5/+0
| | | | Sponsored by: Netflix
* atmegadci: eliminate unused variables sc, ep_noWarner Losh2022-04-051-7/+0
| | | | Sponsored by: Netflix
* usb(3): Fix a few typos in source code commentsGordon Bergling2022-04-021-1/+1
| | | | | | - s/paniced/panicked/ MFC after: 3 days
* ulpt(4): Add support for Epson TM-U220B.Hans Petter Selasky2022-04-022-2/+12
| | | | | | Submitted by: Archimedes Gaviola <archimedes.gaviola@gmail.com> MFC after: 1 week Sponsored by: NVIDIA Networking
* Add devices and quirks for some Olympus cameras.Greg Lehey2022-03-232-1/+48
| | | | | | Reviewed by: hps@ Fixes: Problems attaching Olympus cameras. MFC after: 2 weeks
* usb(4): Check return value from bus_generic_get_device_path().Hans Petter Selasky2022-03-171-0/+2
| | | | | MFC after: 1 week Sponsored by: NVIDIA Networking
* usb(4): Use the global BUS topology lock where appropriate.Hans Petter Selasky2022-03-172-8/+8
| | | | | MFC after: 1 week Sponsored by: NVIDIA Networking
* xhci(4): Add quirk for "Fresco Logic FL1009 USB3.0 xHCI Controller".Hans Petter Selasky2022-03-161-0/+1
| | | | | | Submitted by: John F Carr <jfc@mit.edu> MFC after: 1 week Sponsored by: NVIDIA Networking
* usb(4): Don't skip calling uhub_explore_sub() even on HUB port errors.Hans Petter Selasky2022-03-081-23/+15
| | | | | | | | This should fix an issue where the "udev->re_enumerate_wait" field never gets processed and reset. In this case usbconfig will wait forever and never return. MFC after: 1 week Sponsored by: NVIDIA Networking
* u3g(4): Add new USB IDs.Hans Petter Selasky2022-03-082-0/+4
| | | | | | Submitted by: Matthew Luckie <mjl@luckie.org.nz> MFC after: 1 week Sponsored by: NVIDIA Networking
* xhci(4): Add quirk for "TUSB73x0 USB3.0 xHCI Controller".Hans Petter Selasky2022-03-033-4/+19
| | | | | | Tested by: br@ MFC after: 1 week Sponsored by: NVIDIA Networking
* usbhid(4): Be more restrictive about what requests are allowed from user-space.Hans Petter Selasky2022-03-031-1/+4
| | | | | MFC after: 1 month Sponsored by: NVIDIA Networking
* usb(4): Factor out the usb_check_request() function.Hans Petter Selasky2022-03-033-52/+57
| | | | | | | No functional change. MFC after: 1 week Sponsored by: NVIDIA Networking
* usbhid(4): Implement USB_REQUEST command in hid_ioctl methodVladimir Kondratyev2022-03-021-0/+31
| | | | | | | | This command is intended to be compatible with USB_REQUEST ioctl. It is required to perform arbitrary control endpoint requests by device drivers which can switch between HID and native non-HID modes. MFC after: 2 month
* Add USB UEFI locator supportWarner Losh2022-03-013-2/+35
| | | | | | Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D32788
* bus: Add ACPI locator supportWarner Losh2022-03-011-0/+12
| | | | | | | | | | | Add support for printing ACPI paths. This is a bit of a degenerate case for this interface since it's always just the device handle if the device has one. But it is illustrtive of how to do this for a few nodes in the tree. Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D32748