| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Avoids a NULL dereference encountered with a device I have.
ok mpi@
|
|
|
|
|
|
| |
Otherwise we might leave a port in an unwanted state.
Found while investigating timeout issues on xhci(4).
|
|
|
|
| |
ok tedu@ deraadt@
|
|
|
|
| |
ok deraadt@ tedu@
|
|
|
|
| |
to the way USB buses are discovered.
|
|
|
|
|
| |
anything with it and it simplifies this mess in order to implement
warm reset.
|
| |
|
|
|
|
|
|
| |
this hack in the drivers that need it.
Tested by many, thanks! ok pirofti@, kettenis@
|
|
|
|
|
|
|
|
|
| |
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@
|
|
|
|
| |
a pointer, found by clang.
|
|
|
|
| |
to help integrating super speed hubs that use a different descriptor.
|
|
|
|
| |
after discussions with beck deraadt kettenis.
|
|
|
|
|
| |
that usbd_detach() should only be called by the thread doing USB
bus exploration to prevent attach/detach races.
|
|
|
|
|
|
|
| |
by guenther@.
While here set the dying flag of the disconnected device so that most of
the DVACT_ACTIVATE handlers can go.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
does not match the hardware address.
This change only matters for xHCI buses where the controller assigns
device addresses. But it is the simplest way to comply with the stack
requirement of assigning the first `logical' address to the root hub
device.
Device addresses are not much used anyway and a cleanup will follow to
avoid possible confusions.
This makes usbdevs(8) correctly report devices connected to xhci(4).
|
|
|
|
|
|
|
|
|
| |
even knows your children! So let him handle the seperation correctly.
Do not rewrite your own custom config_detach_children(9) and as a bonus
start removing the usbd_port tentacles from the stack.
ok pirofti@, yuo@, miod@, deraadt@
|
|
|
|
|
|
|
|
|
| |
explicitly set it when required.
Right now xhci(4) does not need such function because it assigns
addresses when the first pipe of a device is opened.
ok yuo@, pirofti@
|
|
|
|
|
|
| |
initialize the per-controller part.
ok deraadt@, kettenis@
|
|
|
|
| |
for USB2 devices.
|
|
|
|
|
| |
to update the address and packet length, fixes a memory leak introduced
in revision 1.96.
|
|
|
|
|
|
|
|
| |
number 0, leaving its descriptors pointing to NULL. There's a lot
of code in our stack that assumes that the various descriptors are
always valid and changing this would be too much work for the moment.
Fix an issue reported by Thomas Pfaff, thanks!
|
|
|
|
|
|
|
|
|
| |
request and instead re-open the default pipe with updated values when
attaching a new device, adapted from FreeBSD r162977.
This fixes a problem where the controller could have cached the previous
values and would fail to get the device descriptor, leaving the device
unrecognized with a message like: "device problem, disabling port n".
|
|
|
|
|
|
| |
Allows us to move forward on cleaning.
Okay mpi@
|
| |
|
| |
|
|
|
|
|
|
|
| |
memory leaks and abort the pipe if requests are still pending because
most of our drivers don't do anything if usbd_close_pipe() fails.
ok miod@
|
|
|
|
| |
them.
|
|
|
|
|
| |
as for every other pipes instead of having another function calling the
host controller method.
|
|
|
|
|
|
|
|
|
| |
definitions instead. We don't change usb.h for now to stay compatible
with userland.
Tested by mpi@ on macppc and myself on i386.
ok mpi@
|
|
|
|
| |
ok mglocker@
|
|
|
|
|
|
| |
them.
ok ratchov@, mglocker@
|
|
|
|
|
|
|
| |
directly this also makes it easier to understand which function actually
generates IO.
ok mglocker@
|
|
|
|
|
|
| |
and move it to usb_subr.c.
OK mpi@
|
| |
|
| |
|
|
|
|
|
|
|
| |
conflict where machines with two controllers with the same unit
number (i.e. ehci0 and uhci0) would have reported to buses 0.
ok miod@
|
|
|
|
| |
leftover from the "usb event" stuff removal. Diff from Tobias Ulmer.
|
|
|
|
|
|
| |
them from userland, and nothing in the kernel uses them.
ok krw@, miod@
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
interfaces as being claimed in the usbd_device's copy of the interface
descriptors
* allow ugen(4) to be attached if there are unused interfaces in a
configuration that has had drivers attached
* make ugen(4) aware that it may be sharing a device with (an)other
driver(s), and if so:
* do not let ugen(4) change the configuration
* do not let ugen(4) access the already claimed interfaces
discussed with deraadt and miod
|
|
|
|
|
|
|
| |
* fill 'udi_serial' with the serial number in usbd_fill_deviceinfo().
* add compatability ioctl/struct so old binaries continue to work.
discussed with deraadt and miod
|
|
|
|
| |
ok jakemsr@
|
|
|
|
| |
ok krw@
|
| |
|
|
|
|
|
|
|
| |
woken up by a wakeup, but only by the actual timeout expiry. On
architectures which share a kva upage area between processes, we would
not want an accidental wakeup (too short).
discussed with various
|
|
|
|
| |
krw@ miod@ ok.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some device could not handle the device descriptor request
with short bLength (less than the device descriptor size(18 byte)).
To handle such kind of devices, add complemental request loop to
current logic.
(memo: and I also found a device which can not response to any device
descriptor request. It always returns only 8 byte-length head of the
descriptor for 1st query. This is the reason why the device descriptor
loop of this usb subsystem start with 8-byte length query.)
|
|
|
|
| |
to cause issues as per netbsd pr/39023. deraadt@ yuo@ ok.
|
|
|
|
|
|
|
|
| |
and then the whole string based on the returned size, not just one byte.
The Lexar card reader kindly loaned by
Denis Doroshenko (denis dot doroshenko at gmail.com) it's happy now, and
after further inspection it's what other OSs do.
Discussed with yuo@. krw@ yuo@ ok.
|
|
|
|
|
|
|
|
|
|
|
| |
add new quirk entry for uvideo which is required isoc transfer.
Some usb2.0 devices use isochronous transfer but current usb
subsystem does not support isoc transfer in ehci(usb2.0) bus.
This patch introduce new psuedo usb hub request UHF_PORT_DISOWN_TO_1_1
to handover the device to ehci to usb1.1 bus(ohci or uhci).
ok mglocker@ deraadt@ fgsch@
|
|
|
|
|
|
|
|
|
| |
Not sure what's more surprising: how long it took for NetBSD to
catch up to the rest of the BSDs (including UCB), or the amount of
code that NetBSD has claimed for itself without attributing to the
actual authors.
OK deraadt@
|