History log of /openbsd/sys/dev/usb/uhub.c (Results 1 – 25 of 98)
Revision Date Author Comments
# 81508fe3 23-May-2024 jsg <jsg@openbsd.org>

remove unneeded includes; ok mpi@


# a9beb1ed 04-Sep-2022 mglocker <mglocker@openbsd.org>

Improve periodic USB transfers (device intr, isoc) used for input
devices, audio, and video. It's still not perfect, and will need
further improvements.

High level, the diff contains following chan

Improve periodic USB transfers (device intr, isoc) used for input
devices, audio, and video. It's still not perfect, and will need
further improvements.

High level, the diff contains following changes:

* Sync up with the Linux code base, which did re-work the periodic
scheduling code path.
* Run the driver in IPL_VM instead of IPL_USB to prioritize us before
lower/equal interrupts (same what NetBSD does).
* Add two new flags to our USB stack required by the updated driver
code:
- 'multi' flag in the usbd_hub structure to keep track whether
a hub has one Transaction Translator for all ports (single TT)
or one Transaction Translator per port (multi TT).
- 'hcpriv' pointer in the usbd_tt structure for the HC driver to
allocate memory for the scheduling depending on single or multi TT.

"go for it" kettenis@

show more ...


# 0d317fc3 10-Jul-2022 mlarkin <mlarkin@openbsd.org>

Remove trailing whitespace. No code change.


# f88cb03e 31-Jul-2020 mglocker <mglocker@openbsd.org>

Nuke all occurrences of usbd_abort_pipe() if it gets called right
before usbd_close_pipe(), since usbd_close_pipe() already takes care
about aborting non-empty pipes.

As investigated by gerhard@ usb

Nuke all occurrences of usbd_abort_pipe() if it gets called right
before usbd_close_pipe(), since usbd_close_pipe() already takes care
about aborting non-empty pipes.

As investigated by gerhard@ usbdi.c rev. 1.57 did add usbd_abort_pipe()
to usbd_close_pipe(), but the drivers didn't get cleaned up afterwards.

ok gerhard@

show more ...


# f9a1d300 16-Mar-2020 mpi <mpi@openbsd.org>

Remove unused function argument.

CID 1453335.


# f74c7769 22-Feb-2020 jasper <jasper@openbsd.org>

use the UE_GET_XFERTYPE macro where applicable

ok mpi@


# 0c4bf27a 07-Jan-2019 mpi <mpi@openbsd.org>

Use the `iface' argument from the *attach() function instead of calling
usbd_device2interface_handle().

ok visa@


# bd50d633 10-Nov-2018 mpi <mpi@openbsd.org>

Pass free(9) sizes for port arrays.

ok tedu@, visa@


# 234dfda1 08-Apr-2017 deraadt <deraadt@openbsd.org>

A pile of sizes to free(9). In test for a few days in snapshots.
Errors will result in nice clean panic messages so we know what's wrong.
Reviewed by dhill visa natano jsg.


# c0d38480 02-Sep-2016 mpi <mpi@openbsd.org>

Avoid calling usbd_set_config_index() in *_attach() and let the stack
do it instead.

If anything bad happen due to a malformed descriptor it makes no sense
to try to attach a driver, and bail before

Avoid calling usbd_set_config_index() in *_attach() and let the stack
do it instead.

If anything bad happen due to a malformed descriptor it makes no sense
to try to attach a driver, and bail before probing.

show more ...


# 0d8ef6c1 29-Nov-2015 kettenis <kettenis@openbsd.org>

Unconnected xhci(4) super speed ports may come up with the XHCI_PS_WRC,
indicating a warm reset has happened. Communicate this as UPS_C_BH_PORT_RESET
to the upper layers and make uhub(4) clear this

Unconnected xhci(4) super speed ports may come up with the XHCI_PS_WRC,
indicating a warm reset has happened. Communicate this as UPS_C_BH_PORT_RESET
to the upper layers and make uhub(4) clear this bit such that we receive
further connection status change notifications. Make sure we only do this
for super speed (USB 3.0) hubs as high speed (USB 2.0) hubs use the same bit
for UPS_C_PORT_L1.

Make hotplugging USB 3.0 devices work on my MacBookPro12,1.

ok mpi@

show more ...


# a4e90a86 29-Nov-2015 kettenis <kettenis@openbsd.org>

Clear the UPS_C_PORT_RESET feature when exploring. Apparently xhci(4) super
speed ports may have the XHCI_PS_PRC bit set after xhci(4) attaches. Just
clearing this bit isn't enough though, since th

Clear the UPS_C_PORT_RESET feature when exploring. Apparently xhci(4) super
speed ports may have the XHCI_PS_PRC bit set after xhci(4) attaches. Just
clearing this bit isn't enough though, since the device is already connected
and no further connection status change is signalled. So fake one.

This makes the integrated SD card reader in the MacBookPro12,1 attach.

ok mpi@

show more ...


# 17d3a5a1 29-Jun-2015 mpi <mpi@openbsd.org>

Move the logic to handle a "connect status change" from uhub_explore()
into its own functions.

Needed for upcoming "port link state" change handling.

Tested by sobrado@


# fb72199c 22-Jun-2015 mpi <mpi@openbsd.org>

Make xhci(4)'s root hub report the same status bits as physical USB3 hubs.

There's not bit to indicate the speed of a USB3.0 device attached to a hub
port so do not abuse the PORT_TEST bit. Instead

Make xhci(4)'s root hub report the same status bits as physical USB3 hubs.

There's not bit to indicate the speed of a USB3.0 device attached to a hub
port so do not abuse the PORT_TEST bit. Instead make the xhci(4) root hub
report the PORT_POWER_SS bit when appropriate and use it to determin the
speed of a new device.

While here make the root hub report the link state and config error, from
FreeBSD.

show more ...


# f210de21 15-Jun-2015 mpi <mpi@openbsd.org>

Bring back r1.78 and r1.79, now that ajactouto@'s regression has
been found: it was a hardware failure.

When a bus is explored, do not probe the ports which status hasn't
changed. This saves a lot

Bring back r1.78 and r1.79, now that ajactouto@'s regression has
been found: it was a hardware failure.

When a bus is explored, do not probe the ports which status hasn't
changed. This saves a lot of I/O when attaching/detaching devices
and might help with some timing related problems.

show more ...


# dc7a18f5 12-Feb-2015 uebayasi <uebayasi@openbsd.org>

KNF.


# b8036196 02-Jan-2015 mpi <mpi@openbsd.org>

Report the TT Think Time of USB2.0 Hubs.


# 0f0d0f95 09-Dec-2014 doug <doug@openbsd.org>

More malloc() -> mallocarray() in the kernel.

ok deraadt@ tedu@


# 791f0ea8 23-Nov-2014 mpi <mpi@openbsd.org>

Revert the logic to skip ports which status hasn't changed, it introduces
a regression reported by ajacoutot@.


# 6205477f 20-Nov-2014 mpi <mpi@openbsd.org>

Force a status check of all the ports of a newly attached hub. In the
interrupt routine properly initialize a variable. Finally stop talking
about the "bus event handler thread". Our USB stack has

Force a status check of all the ports of a newly attached hub. In the
interrupt routine properly initialize a variable. Finally stop talking
about the "bus event handler thread". Our USB stack has only one thread
doing discovery for all buses.

Prompted by a report from Patrick Wildt.

show more ...


# 761ebc24 11-Nov-2014 mpi <mpi@openbsd.org>

When a bus is explored, do not probe the ports which status hasn't
changed. This saves a lot of I/O when attaching/detaching devices
and might help with some timing related problems.

Has been in sn

When a bus is explored, do not probe the ports which status hasn't
changed. This saves a lot of I/O when attaching/detaching devices
and might help with some timing related problems.

Has been in snap for ten days, committing now so that people testing
xhci(4) test the same thing w/ snapshots and their own kernel.

show more ...


# 8bfbe910 10-Nov-2014 mpi <mpi@openbsd.org>

Add some fields needed for TT support.


# 7af21e63 07-Nov-2014 mpi <mpi@openbsd.org>

Give Super-Speed hubs a chance to route USB 3.0 transfers.

Without knowing their depth, hubs couldn't find the bits correspdonding
to their downstream port in the route-string. Now USB 3.0 devices

Give Super-Speed hubs a chance to route USB 3.0 transfers.

Without knowing their depth, hubs couldn't find the bits correspdonding
to their downstream port in the route-string. Now USB 3.0 devices just
work(tm) anywhere in your hub chain.

This commit would not have been possible without the cheese provided by
miod@ at #HAMoween.

show more ...


# 41651d1a 01-Nov-2014 mpi <mpi@openbsd.org>

Remove the port status argument from usbd_reset_port(). We don't do
anything with it and it simplifies this mess in order to implement
warm reset.


# a7a5b35d 01-Oct-2014 mpi <mpi@openbsd.org>

Check that the speed of a new device does not exceed its parent's speed
prior to calling usbd_new_device().

This will let us set the specified default Max Packet Size before opening
the control pipe

Check that the speed of a new device does not exceed its parent's speed
prior to calling usbd_new_device().

This will let us set the specified default Max Packet Size before opening
the control pipe and reduces spaghetti!

ok stsp@

show more ...


1234