summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Treat non-0 value as true for boolean indicators.mpi2020-02-281-2/+5
| | | | | | Makes sensorsd(8) happy with UPS reporting a value of "-1" for true. Reported by and initial diff from Boudewijn Dijkstra.
* Allow devices with incomplete feature unit descriptor to attach.ratchov2020-02-281-1/+9
| | | | | | | | Certain devices (like the AudioQuest DragonFly Red) don't provide the per-channel control bitmaps in the feature unit descriptor. Make this part of the descriptor as optional. With help from Claus <claus at mailbox.org>, thanks.
* Make bwfm(4) call if_input() only once per interrupt.patrick2020-02-251-2/+5
| | | | | | | This reduces drops caused by the ifq pressure drop mechanism and hence increases throughput. ok tobhe@
* Prevent buffer overflows by not assuming the report length, given bympi2020-02-253-13/+22
| | | | | | | the hardware, is necessarily smaller than the length of the on-stack buffer. Original fix from Maxime Villard in NetBSD via deraadt@.
* regenjasper2020-02-232-4/+28
|
* - add an AMD hub found on APU2jasper2020-02-231-1/+9
| | | | | | - add Synaptics vendor id and two fingerprint readers feedback and ok jsg@
* use the UE_GET_XFERTYPE macro where applicablejasper2020-02-2215-48/+48
| | | | ok mpi@
* Replace field f_isfd with field f_flags in struct filterops to allowvisa2020-02-202-7/+7
| | | | | | adding more filter properties without cluttering the struct. OK mpi@, anton@
* Add IPv6 support to umb(4).gerhard2020-02-182-38/+247
| | | | | | | ok job@ bluhm@ claudio@ job@ tested with 'telnet -6 towel.blinkenlights.nl' on Fibocom L831-EAU on IIJ MIO's network (Japan), with 'inet6 autoconf' in /etc/hostname.umb0.
* missing rcs idjasper2020-02-171-0/+2
|
* Prevent buffer overflows by not assuming the report length, given bympi2020-02-141-11/+16
| | | | | | | | | the hardware, is necessarily smaller than the length of the on-stack buffer. Original fix from Maxime Villard in NetBSD via deraadt@. Tested by matthieu@
* replace incorrect function name in error message with __func__jasper2020-02-131-2/+2
|
* Nuke *_minphys() functions that either simply apply MAXPHYS or dokrw2020-02-131-10/+2
| | | | | | | | nothing at all. MAXPHYS will be applied in minphys() and nothing at all, well, doesn't do anything. Also remove any '#define <blah> MAXPHYS' statements used solely to disguise MAXPHYS in said functions.
* Very old firmware umsm devices don't work as umb(4), so I made them workderaadt2020-02-051-2/+1
| | | | | | as umsm(4). But the discrimination in the driver match functions is obviously weak in some way, so skip this for now. We need to figure out how to identify the retrogrades better.
* Fix confusion between minimum and maximum samples-per-frame.ratchov2020-02-051-2/+2
| | | | | This may fix rare stuttering caused by underruns in case device clock drifts with respect to the bus clock.
* Make urtwn(4) attach to tp-link tl-wn823n (RTL8192EU).stsp2020-01-271-2/+3
| | | | Tested by me; Hardware provided by Titus Richartz and Theo Richartz, thanks!
* regenstsp2020-01-272-4/+9
|
* add USB device ID for tp-link tl-wn823nstsp2020-01-271-1/+2
|
* Shuffle some names around to make reading the code less headachekrw2020-01-261-4/+4
| | | | | | | | inducing. Rename scsi_adapter member 'scsi_minphys' to 'dev_minphys' to reflect what it is supposed to do. Use consistent naming convention (<dev>_minphys) for the actual device functions. No functional change.
* Drivers that implement their own *minphys() don't need to call thekrw2020-01-251-3/+1
| | | | | | | system minphys(). scsi_minphys() will do that and cd/sd/st will call scsi_minphys(). ok jmatthew@ as part of larger diff
* cleanup unused headers generated by configjsg2020-01-241-3/+3
| | | | ok tedu@ krw@ deraadt@
* Use a consistant idiom/format when declaring scsi_adapter structureskrw2020-01-231-4/+2
| | | | | | | | | | | in drivers. Terse one liners, NULLs instead of 0's, explicitly specify all members, etc. Nuke #ifdef notyet blocks related to the scsi_adapter in aic. No intentional functional change. ok tedu@
* Some devices do not update the TRB transfer residual information askrw2020-01-221-7/+9
| | | | | | | | | | | | | | | STALL'ing. So use the standard's recommended csw.dCSWDataResidue and copy data only on successful completion of the request. Fixes issue where N bytes are requested, M bytes are returned, and the device STALL's because it has no more data to give. Thus resulting in no data is copied to the user buffer but the claim being made that said buffer now contains M new bytes of valid data. e.g. when cdio(1) asks for 4096 bytes of media data and only 96 bytes are provided by the CDRW device. Feeback, cluebats, fixes and ok patrick@
* Add a zero length TD, rather than adding a zero length TRB to thekrw2020-01-221-11/+32
| | | | | | | | | | | | | | | original TD, when a transfer is a multiple of the max packet size. The zero length TD will have a NULL xfer pointer. As a result "NULL xfer pointer" situations become perfectly normal. So change the log_warnx() that issues that verbiage to a log_debug(). Note that the original transfer will complete and report its result up the USB stack before the zero length transfer is executed. Fixes (at least) urtwn(4) interfaces. Feeback, cluebats, fixes and ok patrick@
* regenjsg2020-01-202-4/+9
|
* add another Intel Bluetooth devicejsg2020-01-201-1/+2
|
* Invalidate knote list of uhid(4) after device detach. This preventsvisa2020-01-181-1/+5
| | | | | | | | | | | | a crash that can happen if a uhid(4) device is detached while kqueue still holds references to knotes that point to the device. The invalidation has to be done after vdevgone(). This order ensures that the file descriptors return an error or EOF when kevent(2) returns the EOF events. Crash reported and fix tested by Greg Steuck OK mpi@
* Free data structures after closing the pseudo-device with vdevgone(9).mpi2020-01-161-3/+3
| | | | | | | | | | | | Pseudo-drivers exposing a userland interface generally start & stop I/O in *_open() and *_close() respectively. So it isn't safe to detach such device while it is still open, because I/O might still be in flight. A more generic fix would be to detach children devices before the parents. Fix a race reported by Kevin Chadwick on bugs@. Discussed with Peter Stuge, tested by and ok zhuk@
* Ensure XHCI_SCTX_DCI() always contains a valid number, i.e. the DCI ofkrw2020-01-131-10/+21
| | | | | | | | | | | | | the highest active endpoint context. Don't zap other fields when setting XHCI_SCTX_DCI(). Fixes (at least) Etron EJ168 USB 3.0 Host Controllers vs USB 2 devices. Inspired by hselasky FreeBSD revision 243780. Feedback from kn@, ok beck@ (previous iteration) patrick@
* Convert to tsleep_nsec(9).mpi2020-01-131-3/+5
| | | | ok kettenis@
* MC7700 works as umsmderaadt2020-01-111-1/+2
|
* syncderaadt2020-01-112-4/+9
|
* add SIERRA MC7700deraadt2020-01-111-1/+2
|
* usbd_request_async() already frees 'xfer' in case of an errorgerhard2020-01-101-2/+1
| | | | ok patrick@
* Rename udl_mode field to not shadow global `hz' variable.mpi2020-01-092-11/+11
| | | | ok mglocker@
* Kill unused defines referencing `hz'.mpi2020-01-081-4/+1
|
* ZYD_INTR_TIMEOUT is expressed in msecs not in ticks, fixes that by callingmpi2020-01-071-2/+3
| | | | | | tsleep_nsec(9). Tested by and ok stsp@
* Convert to tsleep_nsec(9).mpi2020-01-051-2/+2
| | | | ok mglocker@
* regenjsg2020-01-052-64/+64
|
* sort list of vendor ids by vendor idjsg2020-01-051-13/+13
|
* regenjsg2020-01-052-26/+6
|
* remove duplicate device idsjsg2020-01-055-15/+6
|
* regenjsg2020-01-052-1336/+1335
|
* sort by vendor define and device idjsg2020-01-051-370/+369
|
* regenjsg2020-01-052-18/+18
|
* consistently lowercase hex digits in device idsjsg2020-01-051-15/+15
|
* regenjsg2020-01-052-18/+18
|
* consistently uppercase usb product definesjsg2020-01-055-18/+18
| | | | ok mpi@
* Prevent use-after-free in uhidev_close().mpi2020-01-041-14/+14
| | | | | | | Close pipes before freeing transfers, otherwise accessing elements in pipe->queue, like in usbd_abort_pipe(), will result in a crash. Problem reported by reyk@, ok visa@
* Convert sleep to tsleep_nsec(9) and use unique sleeping identifiers.mpi2020-01-041-5/+5
| | | | ok bluhm@