summaryrefslogtreecommitdiff
path: root/sys/dev/usb
AgeCommit message (Collapse)Author
2023-06-05- Fix clearing of EINT and other transient flags.mlelstv
Patches from sc.dying in kern/56115: - Set proper Max ESIT Payload value for interrupt/isoc endpoint context. - Set proper Average TRB Length value. - Not tested on superspeed/superspeedplus isochronous device. - Add handling of some error paths for isochronous transfers.
2023-05-14fix typqpgoyette
2023-05-14Regenpgoyette
2023-05-14Add a Lenovo mouse so we can set the ALWAYS_ON quirk.pgoyette
2023-05-10uts(4): Use config_detach_children.riastradh
2023-05-10udsbr(4): Use config_detach_children.riastradh
2023-05-10irmce(4): Use config_detach_children.riastradh
2023-05-07RISC-V support that works on QEMU with a single hart.skrll
Thanks for Simon Burge for plic(4).
2023-04-30xhci doesn't like 80 packets per USB interval, but 40 seems to be finemlelstv
for xhci (and ehci).
2023-04-27Remove an unnecessary cast in a KASSERTMSGskrll
2023-04-23Weed out duplicate sample rates and add comment about UAC2 clocks.mlelstv
2023-04-16Handle packet scheduling for high/super speed.mlelstv
More UAC2 handling for input/output/feature/selector units. Setting sample rate for UAC2 now works, still no support for clock selectors and multipliers. Added sysctl to set debug level. Minor fixes.
2023-04-11usb(9): Assert ud_ifaces is null before we clobber it.riastradh
2023-04-10Reduce excessive settle delay.mlelstv
2023-04-10Better descriptor parsing.mlelstv
Add sanity check if no default format is found.
2023-04-10Handle more UAC2 descriptors and add debug output.mlelstv
Fix handling of clock sources (mix.wIndex wasn't set). UAC2 can use separate clock sources (and thus sample rates) for each terminal. That doesn't match the audio(4) model where sample rates are part of an audio format and global. For now, try to match clocks for input and output terminals separately.
2023-04-09xhci(4): Avoid crash in suspend/resume/resume if first resume fails.riastradh
Rather than try to recover from this, just make new commands fail so at least we don't deadlock. XXX pullup-9 XXX pullup-10
2023-04-07xhci(4): Defer root intr xfers while polling.riastradh
Root intr xfers require taking adaptive locks, which is forbidden while polling. This is not great -- any USB transfer completion callbacks might try to take adaptive locks, not just uhub_intr, and that will always causes trouble. We get lucky with ukbd_intr because it's not MP-safe, so it relies only on the kernel lock (a spin lock) anyway. But this change brings xhci in line with ehci. PR kern/57326 XXX pullup-8 XXX pullup-9 XXX pullup-10
2023-04-03Remove unconditional UAUDIO_DEBUG again.mlelstv
2023-04-03Fix UAUDIO_DEBUG build.mlelstv
2023-04-02Add support for USB Audio Class 2.0.mlelstv
2023-04-02Add code for USB Audio Class 2.0.mlelstv
This is only half of the game as UAC2 devices tend to use 24bit or 32bit samples. This requires more support in audio(4).
2023-03-28s/interrput/interrupt/ and s/accesss/access/ in comments.andvar
2023-03-05ucom(4): Simplify logic fixing PR kern/57259.riastradh
cv_timedwait only ever returns 0 or EWOULDBLOCK, so this would always return ERESTART anyway. No functional change intended.
2023-03-05In the HUP-wait path in ucomopen():thorpej
- Use cv_timedwait() rather than cv_timedwait_sig(); the wait here is bounded (and fairly short besides) and seems appropriate to treat like other uninterruptible waits. The behavior is now consistent with com(4) in this regard. - Map EWOULDBLOCK return from cv_timedwait() to 0, as the successful passage of time is not an error in this case. - If the HUP-wait time has passed, clear the HUP-wait timestamp. kern/57259 (although insufficient -- another change to vfs_syscalls.c is required)
2023-02-17ucom(4): Missed a spot in previous -- nix now-unused local.riastradh
2023-02-17ucom(4): Nix broken error branch.riastradh
This error branch was introduced to make the system act, when a USB serial adapter is yanked, as if the other end had spat out a line feed in an attempt to wake any sleeping readers so they will stop using the USB serial port. This is no longer necessary, because ttycancel will wake them anyway, and it is actually harmful because it puts stuff in the output queue (CR LF) that will never be processed, causing subsequent users to hang trying to open the device. Problem found and patch tested by tih@.
2023-02-13Add support for ZTE MF112 and D-Link DWM222 3G USB modemsmanu
2023-02-11urndis(4): Add OnePlus 5T to the quirky devices list. This allows it tonia
be attached as an urndis instead of ugen, and to transmit this commit message across the tubes.
2023-02-11regennia
2023-02-11Add my phone to usbdevsnia
2023-01-21fix typos in comment and log message.andvar
2023-01-10ukbd(4): remember how much of attach worked so detach works.mrg
if ukbd_attach() fails it means it has only really done the pmf setup, nothing else, so avoid trying to remove callouts, child devices, or console setup, usb task and uhidev operations. fixes the crash (but not the underlying ukbd doesn't work issue) seen in PR#57149.
2022-12-13fix grammar in commentjakllsch
2022-12-13ehci_device_isoc_init() returns errno not usbd_error; remove blank linejakllsch
in ehci_device_fs_isoc_init() to match ehci_device_isoc_init()
2022-12-13"periodic frame list", not "period frame list" in commentsjakllsch
2022-12-13Add missing whitespace in error message.jakllsch
2022-11-04Back out r1.82 ("Do not explicitly set the HID Report Protocol upon attach")jmcneill
due to the regression reported in PR# 57031
2022-11-01s/faild/failed/ in comments and messages.andvar
2022-10-31fix various typos in comments and one output message.andvar
2022-10-26uhso(4): Convert locking comments to locking assertions.riastradh
2022-10-26ucycom(4): Convert to ttylock/ttyunlock.riastradh
2022-10-26ucom(4): Convert to ttylock/ttyunlock.riastradh
2022-10-23ugen(4): Make sure opened is initialized in ugenopen.riastradh
Otherwise the error branch is based on garbage.
2022-10-23Fix USBDEBUG build on ILP32skrll
2022-10-21ugen(4): convert to USBHIST style debugging.mrg
2022-10-11KNF a bit. No functional change.msaitoh
2022-10-11"Add" number of ports because the same speed's ECR may appear multiple times.msaitoh
2022-10-11There is an xHCI device which has USB 2 port only. Support it.msaitoh
- Example: xhci4 at pci17 dev 0 function 0: AMD product 15b8 (rev. 0x00) xhci4: 64-bit DMA allocated pic msix10 type edge pin 0 level 6 to cpu0 slot 32 idt entry 107 xhci4: interrupting at msix10 vec 0 xhci4: xHCI version 1.20 xhci4: hcs1=1000840 hcs2=140000f1 hcs3=7000a xhci4: hcc=0x110ffc5<XECP=0x110,MAXPSA=0xf,CFC,SEC,SPC,PAE,NSS,LTC,CSZ,AC64> xhci4: xECP 440 xhci4: hcc2=0x3f<CIC,LEC,CTC,FSC,CMC,U3C> xhci4: ECR: 0x00000401 xhci4: ECR: 0x02000402 xhci4: SP: 0x02000402 0x20425355 0x00180101 0x00000000 xhci4: hs ports 1 - 1 xhci4: ECR: 0x000f000a xhci4: PAGESIZE 0x00000001 xhci4: sc_pgsz 0x00001000 xhci4: sc_maxslots 0x00000040 xhci4: sc_maxports 1 xhci4: sc_maxspbuf 2 xhci4: eventst: 0x000000013ee60fc0 0xffffb08826f5afc0 1000 xhci4: dcbaa: 0x000000013ee63000 0xffffb08826f5b000 1000 xhci4: current IMOD 0 (snip) usb8 at xhci4: USB revision 3.1 usb9 at xhci4: USB revision 2.0 uhub8 at usb8: NetBSD (0x0000) xHCI root hub (0x0000), class 9/0, rev 3.00/1.00, addr 0 uhub8: 0 ports with 0 removable, self powered uhub8: no ports, hub ignored uhub8: WARNING: power management not supported autoconfiguration error: usb8: root device is not a hub usb8: WARNING: power management not supported uhub9 at usb9: NetBSD (0x0000) xHCI root hub (0x0000), class 9/0, rev 2.00/1.00, addr 0 uhub9: 1 port with 1 removable, self powered - To resolve this problem, keep number of ports of SS and HS and use it to attach child device(s). - Tested on ASUS TUF GAMING X670E-PLUS. - OK'd by skrll@.
2022-10-10ETHERCAP_VLAN_MTU does not go into ifp->if_capabilities but ethercommartin
ec_capabilities instead.