Home | History | Annotate | Download | only in usb
History log of /src/sys/dev/usb/ucycom.c
RevisionDateAuthorComments
 1.57  17-Mar-2024  jakllsch Prevent errant ucycom-presenting device from causing up to 225
bytes of kernel memory following input buffer to leak to tty
application.

Probably not practically expolitable, but you never know.
 1.56  26-Oct-2022  riastradh branches: 1.56.2;
ucycom(4): Convert to ttylock/ttyunlock.
 1.55  28-Mar-2022  riastradh uhidev(9): Make uhidev state opaque.

This makes the API simpler and clearer and gives us more latitude to
fix bugs in the state management without breaking the ABI.

XXX kernel ABI change to signature of uhidev_get_report_desc and
uhidev_open, and to struct uhidev_attach_arg, requires bump for
uhidev driver modules
 1.54  28-Mar-2022  riastradh ucycom(4): Defer uhidev_write_async to taskq.

Can't submit USB transfers while holding tty_lock, a spin lock.
 1.53  28-Mar-2022  riastradh uhidev(9): New uhidev_write_async.

Like uhidev_write but issues the transfer asynchronously with a
callback.

Use it in ucycom(4).

Also, clear endpoint stalls asynchronously -- can't do them
synchronously in xfer callbacks which run at softint and therefore
can't wait in cv_wait as usbd_do_request does.
 1.52  28-Mar-2022  riastradh uhidev(9): Partially fix uhidev_write aborting.

In my previous change, I intended to make uhidev_stop abort any
pending write -- but I forgot to initialize sc->sc_writereportid, so
it never did anything.

This changes the API and ABI of uhidev_write so it takes the struct
uhidev pointer, rather than the struct uhidev_softc pointer; this way
uhidev_write knows what the report id of the client is, so it can
arrange to have uhidev_stop abort only this one.

XXX Except it still doesn't actually work because we do this
unlocked, ugh, so the write might complete before we abort anything.
To be fixed some more in a later change.

XXX kernel ABI change to uhidev_write signature, used by uhidev
driver modules, requires bump
 1.51  14-Mar-2020  christos revert the 0x% -> %# change for fixed width formats pointed out by uwe.
 1.50  13-Mar-2020  christos PR/55068: sc.dying: Fix printf formats:
- no %s/%p for kernel log
- 0x% -> %#
- always %j for kernel log
 1.49  01-Jan-2020  maxv Fix buffer overflows: validate the lengths at attach time, given that they
are apparently not supposed to be variable. Drop sc_ilen since it is
unused.
 1.48  01-Dec-2019  maxv localify
 1.47  05-May-2019  mrg branches: 1.47.2;
remove explicit 'extern struct cfdriver <my>_cd;' and use ioconf.h
 1.46  10-Dec-2017  bouyer branches: 1.46.4;
Factor out bus-independant HID code so that it can be shared by USB, bluetooth
and i2c.
dev/usb/ukbdmap.c is renamed to dev/hid/hidkbdmap.c
dev/usb/hid.[ch] moved to dev/hid/
usage pages moved from dev/usb/usbhid.h moved to dev/hid/hid.h,
and updated with OpenBSD entries.
bus-independant code moved from dev/usb/ums.c to dev/hid/hidms.c
(the same should be done for keyboard and touchpad drivers)

Needed for the upcoming HID over I2C support, proposed on tech-kern@
on Dec, 1.
 1.45  25-Nov-2016  skrll branches: 1.45.8;
+#include "opt_usb.h"
 1.44  07-Jul-2016  msaitoh branches: 1.44.2;
KNF. Remove extra spaces. No functional change.
 1.43  23-Apr-2016  skrll Merge nick-nhusb

- API / infrastructure changes to support memory management changes.
- Memory management improvements and bug fixes.
- HCDs should now be MP safe
- conversion to KERNHIST based debug
- FS/LS isoc support on ehci(4).
- conversion to kmem(9)
- Some USB 3 support - mostly from Takahiro HAYASHI (t-hash).
- interrupt transfers now get proper DMA operations
- general bug fixes
- kern/48308
- uhub status notification improvements
- umass(4) probe fix (applied to HEAD already)
- ohci(4) short transfer fix
 1.42  07-Mar-2015  mrg properly protect uhid's sc_q member with sc_lock. should fix PR#49728.
while here, remove D_MPSAFE from uhid* and all uhid users, as it really
needs all the callers to be safe and they're not.

XXX: pullup-7
 1.41  15-Nov-2014  christos branches: 1.41.2;
fix macro names
 1.40  15-Nov-2014  christos centralize the dialout/call unit macros.
 1.39  25-Jul-2014  dholland branches: 1.39.2;
Add d_discard to all struct cdevsw instances I could find.

All have been set to "nodiscard"; some should get a real implementation.
 1.38  16-Mar-2014  dholland branches: 1.38.2;
Change (mostly mechanically) every cdevsw/bdevsw I can find to use
designated initializers.

I have not built every extant kernel so I have probably broken at
least one build; however I've also found and fixed some wrong
cdevsw/bdevsw entries so even if so I think we come out ahead.
 1.37  14-Oct-2013  skrll Handle an error from uhidev_get_report in ucycom_get_cfg
 1.36  15-Sep-2013  martin Mark a potentially unused variable
 1.35  09-Jan-2013  skrll branches: 1.35.2;
Add usmsc(4) - a driver for the SMSC95XX USB ethernet devices.

This is a port of the OpenBSD driver which itself was a port of the
FreeBSD driver.

sorry mrg. jared made me do it.
 1.34  06-Mar-2012  mrg branches: 1.34.2;
pull down from usbmp branch:

- rename usb_detach_{wake,waitup}() to usb_detach_{wake,waitup}old()
- use some c99 struct .initialisers
 1.33  24-Apr-2011  rmind branches: 1.33.4; 1.33.8;
Rename ttymalloc() to tty_alloc(), and ttyfree() to tty_free() for
consistency. Remove some unnecessary malloc.h inclusions as well.
 1.32  15-Nov-2010  uebayasi branches: 1.32.2;
Dereferencing struct lwp * needs sys/lwp.h.
 1.31  03-Nov-2010  dyoung Stop using the compatibility macros USB_ATTACH(), USB_DETACH(),
USB_MATCH(), et cetera. These files produce the same assembly
(according to objdump -d) before and after the change
 1.30  06-Dec-2009  dyoung branches: 1.30.2; 1.30.4;
Simplify device-activation hooks.
 1.29  06-Aug-2009  skrll Make ucycomstart use usbd_setup_xfer and a callback so that it doesn't
(attempt to) sleep in interrupt context.

From David Howland in PR 36276 with changes from me.

XXX Still losing data on input.
 1.28  24-Jul-2009  skrll spaces to tab.
 1.27  24-Jul-2009  skrll Remove trailing whitespace
 1.26  24-Jul-2009  skrll Wrap some long lines.

Whitespace.
 1.25  20-Jan-2009  drochner Change major()/minor() to return 32-bit types again, called
devmajor_t/devminor_t, as proposed on tech-kern.
This avoids 64-bit arithmetics and 64-bit printf formats in parts
of the kernel where it is not really useful, and helps clarity.
 1.24  11-Jan-2009  cegger make this compile
 1.23  24-May-2008  cube branches: 1.23.6;
Split device_t and softc for all USB device drivers, and related cosmetic
changes.

Matthias Drochner kindly reviewed this patch, and tested ums, ubt, uaudio
and ral. I tested umass myself.
 1.22  28-Apr-2008  martin branches: 1.22.2;
Remove clause 3 and 4 from TNF licenses
 1.21  05-Apr-2008  cegger branches: 1.21.2; 1.21.4;
use aprint_*_dev and device_xname
 1.20  11-Dec-2007  lukem branches: 1.20.8;
use __KERNEL_RCSID() instead of __RCSID()
 1.19  19-Nov-2007  ad branches: 1.19.2; 1.19.4; 1.19.6;
- Factor out too many copies of the same bit of tty code.
- Fix another tty signalling/wakeup problem.
 1.18  10-Nov-2007  ad Call ttyflush() with tty_lock held.
 1.17  04-Mar-2007  christos branches: 1.17.14; 1.17.16; 1.17.20; 1.17.22;
Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.
 1.16  16-Nov-2006  christos branches: 1.16.4; 1.16.10;
__unused removal on arguments; approved by core.
 1.15  12-Oct-2006  christos - sprinkle __unused on function decls.
- fix a couple of unused bugs
- no more -Wno-unused for i386
 1.14  04-Oct-2006  christos fix empty if
 1.13  01-Oct-2006  elad More from Matt Fleming:

Adapt to KAUTH_DEVICE_TTY_PRIVSET and KAUTH_DEVICE_TTY_OPEN.
 1.12  01-Oct-2006  elad Adapt MD code to KAUTH_DEVICE_TTY_OPEN, batch #2 from Matt Fleming, thanks!

Also, add forgotten splx() calls in some places.
 1.11  21-Jul-2006  ad branches: 1.11.4; 1.11.6;
- Use the LWP cached credentials where sane.
- Minor cosmetic changes.
 1.10  14-May-2006  elad branches: 1.10.6;
integrate kauth.
 1.9  28-Mar-2006  thorpej Use device_unit().
 1.8  05-Mar-2006  christos branches: 1.8.2; 1.8.4;
cleanup more SET/CLR/ISSET lossage
 1.7  20-Feb-2006  thorpej branches: 1.7.2;
Use device_is_active() rather than testing dv_flags for DVF_ACTIVE
directly.
 1.6  11-Dec-2005  christos branches: 1.6.2; 1.6.4; 1.6.6;
merge ktrace-lwp.
 1.5  06-Sep-2005  kleink branches: 1.5.6;
Change the driver open function's conditional for overriding exclusive tty
use from checking the proc's uid to suser(9), and account for the use of
privileges. Noted by David Holland in PR kern/31126.
 1.4  01-Sep-2005  skrll Complete the attach message - there is nothing interesting to report.

Remove some debug stuff.
 1.3  05-Aug-2005  skrll +#include <sys/device.h>
 1.2  01-Aug-2005  skrll Debug code tidy up.
 1.1  30-Jul-2005  skrll Add a driver for Cypress microcontroller based USB serial adapters.

XXX hw flow control is not supported.
 1.5.6.2  10-Nov-2005  skrll Sync with HEAD. Here we go again...
 1.5.6.1  06-Sep-2005  skrll file ucycom.c was added on branch ktrace-lwp on 2005-11-10 14:08:05 +0000
 1.6.6.2  01-Jun-2006  kardel Sync with head.
 1.6.6.1  22-Apr-2006  simonb Sync with head.
 1.6.4.1  09-Sep-2006  rpaulo sync with head
 1.6.2.1  01-Mar-2006  yamt sync with head.
 1.7.2.4  11-Aug-2006  yamt sync with head
 1.7.2.3  24-May-2006  yamt sync with head.
 1.7.2.2  01-Apr-2006  yamt sync with head.
 1.7.2.1  13-Mar-2006  yamt sync with head.
 1.8.4.2  24-May-2006  tron Merge 2006-05-24 NetBSD-current into the "peter-altq" branch.
 1.8.4.1  31-Mar-2006  tron Merge 2006-03-31 NetBSD-current into the "peter-altq" branch.
 1.8.2.4  06-May-2006  christos - Move kauth_cred_t declaration to <sys/types.h>
- Cleanup struct ucred; forward declarations that are unused.
- Don't include <sys/kauth.h> in any header, but include it in the c files
that need it.

Approved by core.
 1.8.2.3  19-Apr-2006  elad sync with head.
 1.8.2.2  10-Mar-2006  elad generic_authorize() -> kauth_authorize_generic().
 1.8.2.1  08-Mar-2006  elad Adapt to kernel authorization KPI.
 1.10.6.7  21-Jan-2008  yamt sync with head
 1.10.6.6  07-Dec-2007  yamt sync with head
 1.10.6.5  15-Nov-2007  yamt sync with head.
 1.10.6.4  03-Sep-2007  yamt sync with head.
 1.10.6.3  30-Dec-2006  yamt sync with head.
 1.10.6.2  21-Jun-2006  yamt sync with head.
 1.10.6.1  14-May-2006  yamt file ucycom.c was added on branch yamt-lazymbuf on 2006-06-21 15:07:44 +0000
 1.11.6.2  10-Dec-2006  yamt sync with head.
 1.11.6.1  22-Oct-2006  yamt sync with head
 1.11.4.1  18-Nov-2006  ad Sync with head.
 1.16.10.2  28-Jun-2007  itohy New device from OpenBSD:
- DeLorme Earthmate LT-20 GPS
 1.16.10.1  17-Jun-2007  itohy - Pullup 1.17 in a different way.
- struct lwp *l -> usb_proc_ptr p
 1.16.4.1  12-Mar-2007  rmind Sync with HEAD.
 1.17.22.3  27-Dec-2007  mjf Sync with HEAD.
 1.17.22.2  08-Dec-2007  mjf Sync with HEAD.
 1.17.22.1  19-Nov-2007  mjf Sync with HEAD.
 1.17.20.2  21-Nov-2007  bouyer Sync with HEAD
 1.17.20.1  13-Nov-2007  bouyer Sync with HEAD
 1.17.16.1  09-Jan-2008  matt sync with HEAD
 1.17.14.2  21-Nov-2007  joerg Sync with HEAD.
 1.17.14.1  11-Nov-2007  joerg Sync with HEAD.
 1.19.6.1  13-Dec-2007  bouyer Sync with HEAD
 1.19.4.1  11-Dec-2007  yamt sync with head.
 1.19.2.1  26-Dec-2007  ad Sync with head.
 1.20.8.2  17-Jan-2009  mjf Sync with HEAD.
 1.20.8.1  02-Jun-2008  mjf Sync with HEAD.
 1.21.4.4  11-Mar-2010  yamt sync with head
 1.21.4.3  19-Aug-2009  yamt sync with head.
 1.21.4.2  04-May-2009  yamt sync with head.
 1.21.4.1  16-May-2008  yamt sync with head.
 1.21.2.2  04-Jun-2008  yamt sync with head
 1.21.2.1  18-May-2008  yamt sync with head.
 1.22.2.1  23-Jun-2008  wrstuden Sync w/ -current. 34 merge conflicts to follow.
 1.23.6.2  03-Mar-2009  skrll Sync with HEAD.
 1.23.6.1  19-Jan-2009  skrll Sync with HEAD.
 1.30.4.2  31-May-2011  rmind sync with head
 1.30.4.1  05-Mar-2011  rmind sync with head
 1.30.2.1  06-Nov-2010  uebayasi Sync with HEAD.
 1.32.2.1  06-Jun-2011  jruoho Sync with HEAD.
 1.33.8.1  26-Feb-2012  mrg rename old usb_detach_wakeup/wait to usb_detach_{wake,wakeup}old().
 1.33.4.3  22-May-2014  yamt sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs. ("Protocol error: too many arguments")
 1.33.4.2  23-Jan-2013  yamt sync with head
 1.33.4.1  17-Apr-2012  yamt sync with head
 1.34.2.3  03-Dec-2017  jdolecek update from HEAD
 1.34.2.2  20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.34.2.1  25-Feb-2013  tls resync with head
 1.35.2.1  18-May-2014  rmind sync with head
 1.38.2.1  10-Aug-2014  tls Rebase.
 1.39.2.2  05-Apr-2017  snj Pull up following revision(s) (requested by skrll in ticket #1395):
share/man/man4/axe.4: netbsd-7-nhusb
share/man/man4/axen.4: netbsd-7-nhusb
share/man/man4/cdce.4: netbsd-7-nhusb
share/man/man4/uaudio.4: netbsd-7-nhusb
share/man/man4/ucom.4: netbsd-7-nhusb
share/man/man4/uep.4: netbsd-7-nhusb
share/man/man4/urtw.4: netbsd-7-nhusb
share/man/man4/usb.4: netbsd-7-nhusb
share/man/man4/uyap.4: netbsd-7-nhusb
share/man/man4/xhci.4: netbsd-7-nhusb
share/man/man9/usbdi.9: netbsd-7-nhusb
sys/arch/amd64/conf/ALL: netbsd-7-nhusb
sys/arch/amd64/conf/GENERIC: netbsd-7-nhusb
sys/arch/amiga/dev/slhci_zbus.c: netbsd-7-nhusb
sys/arch/arm/allwinner/awin_otg.c: netbsd-7-nhusb
sys/arch/arm/allwinner/awin_usb.c: netbsd-7-nhusb
sys/arch/arm/amlogic/amlogic_dwctwo.c: netbsd-7-nhusb
sys/arch/arm/at91/at91ohci.c: netbsd-7-nhusb
sys/arch/arm/broadcom/bcm2835_dwctwo.c: netbsd-7-nhusb
sys/arch/arm/broadcom/bcm53xx_usb.c: netbsd-7-nhusb
sys/arch/arm/ep93xx/epohci.c: netbsd-7-nhusb
sys/arch/arm/gemini/obio_ehci.c: netbsd-7-nhusb
sys/arch/arm/imx/files.imx23: netbsd-7-nhusb
sys/arch/arm/imx/imxusb.c: netbsd-7-nhusb
sys/arch/arm/imx/imxusbreg.h: netbsd-7-nhusb
sys/arch/arm/omap/obio_ohci.c: netbsd-7-nhusb
sys/arch/arm/omap/omap3_ehci.c: netbsd-7-nhusb
sys/arch/arm/omap/omapl1x_ohci.c: netbsd-7-nhusb
sys/arch/arm/omap/tiotg.c: netbsd-7-nhusb
sys/arch/arm/s3c2xx0/ohci_s3c24x0.c: netbsd-7-nhusb
sys/arch/arm/samsung/exynos_usb.c: netbsd-7-nhusb
sys/arch/arm/xscale/pxa2x0_ohci.c: netbsd-7-nhusb
sys/arch/arm/zynq/zynq_usb.c: netbsd-7-nhusb
sys/arch/hpcarm/dev/nbp_slhci.c: netbsd-7-nhusb
sys/arch/hpcmips/dev/plumohci.c: netbsd-7-nhusb
sys/arch/i386/conf/ALL: netbsd-7-nhusb
sys/arch/i386/conf/GENERIC: netbsd-7-nhusb
sys/arch/i386/pci/gcscehci.c: netbsd-7-nhusb
sys/arch/luna68k/conf/GENERIC: netbsd-7-nhusb
sys/arch/mips/adm5120/dev/ahci.c: netbsd-7-nhusb
sys/arch/mips/adm5120/dev/ahcivar.h: netbsd-7-nhusb
sys/arch/mips/alchemy/dev/ohci_aubus.c: netbsd-7-nhusb
sys/arch/mips/atheros/dev/ehci_arbus.c: netbsd-7-nhusb
sys/arch/mips/atheros/dev/ohci_arbus.c: netbsd-7-nhusb
sys/arch/mips/conf/files.adm5120: netbsd-7-nhusb
sys/arch/mips/ralink/ralink_ehci.c: netbsd-7-nhusb
sys/arch/mips/ralink/ralink_ohci.c: netbsd-7-nhusb
sys/arch/mips/rmi/rmixl_ehci.c: netbsd-7-nhusb
sys/arch/mips/rmi/rmixl_ohci.c: netbsd-7-nhusb
sys/arch/playstation2/dev/ohci_sbus.c: netbsd-7-nhusb
sys/arch/powerpc/booke/dev/pq3ehci.c: netbsd-7-nhusb
sys/arch/powerpc/ibm4xx/dev/dwctwo_plb.c: netbsd-7-nhusb
sys/arch/x68k/dev/slhci_intio.c: netbsd-7-nhusb
sys/conf/files: netbsd-7-nhusb
sys/dev/cardbus/ehci_cardbus.c: netbsd-7-nhusb
sys/dev/cardbus/ohci_cardbus.c: netbsd-7-nhusb
sys/dev/cardbus/uhci_cardbus.c: netbsd-7-nhusb
sys/dev/ic/sl811hs.c: netbsd-7-nhusb
sys/dev/ic/sl811hsvar.h: netbsd-7-nhusb
sys/dev/isa/slhci_isa.c: netbsd-7-nhusb
sys/dev/marvell/ehci_mv.c: netbsd-7-nhusb
sys/dev/pci/ehci_pci.c: netbsd-7-nhusb
sys/dev/pci/ohci_pci.c: netbsd-7-nhusb
sys/dev/pci/uhci_pci.c: netbsd-7-nhusb
sys/dev/pci/xhci_pci.c: netbsd-7-nhusb
sys/dev/pcmcia/slhci_pcmcia.c: netbsd-7-nhusb
sys/dev/usb/Makefile.usbdevs: netbsd-7-nhusb
sys/dev/usb/TODO: netbsd-7-nhusb
sys/dev/usb/TODO.usbmp: netbsd-7-nhusb
sys/dev/usb/aubtfwl.c: netbsd-7-nhusb
sys/dev/usb/auvitek.c: netbsd-7-nhusb
sys/dev/usb/auvitek_audio.c: netbsd-7-nhusb
sys/dev/usb/auvitek_dtv.c: netbsd-7-nhusb
sys/dev/usb/auvitek_i2c.c: netbsd-7-nhusb
sys/dev/usb/auvitek_video.c: netbsd-7-nhusb
sys/dev/usb/auvitekvar.h: netbsd-7-nhusb
sys/dev/usb/ehci.c: netbsd-7-nhusb
sys/dev/usb/ehcireg.h: netbsd-7-nhusb
sys/dev/usb/ehcivar.h: netbsd-7-nhusb
sys/dev/usb/emdtv.c: netbsd-7-nhusb
sys/dev/usb/emdtv_dtv.c: netbsd-7-nhusb
sys/dev/usb/emdtv_ir.c: netbsd-7-nhusb
sys/dev/usb/emdtvvar.h: netbsd-7-nhusb
sys/dev/usb/ezload.c: netbsd-7-nhusb
sys/dev/usb/ezload.h: netbsd-7-nhusb
sys/dev/usb/files.usb: netbsd-7-nhusb
sys/dev/usb/hid.c: netbsd-7-nhusb
sys/dev/usb/hid.h: netbsd-7-nhusb
sys/dev/usb/if_athn_usb.c: netbsd-7-nhusb
sys/dev/usb/if_athn_usb.h: netbsd-7-nhusb
sys/dev/usb/if_atu.c: netbsd-7-nhusb
sys/dev/usb/if_atureg.h: netbsd-7-nhusb
sys/dev/usb/if_aue.c: netbsd-7-nhusb
sys/dev/usb/if_auereg.h: netbsd-7-nhusb
sys/dev/usb/if_axe.c: netbsd-7-nhusb
sys/dev/usb/if_axen.c: netbsd-7-nhusb
sys/dev/usb/if_axenreg.h: netbsd-7-nhusb
sys/dev/usb/if_axereg.h: netbsd-7-nhusb
sys/dev/usb/if_cdce.c: netbsd-7-nhusb
sys/dev/usb/if_cdcereg.h: netbsd-7-nhusb
sys/dev/usb/if_cue.c: netbsd-7-nhusb
sys/dev/usb/if_cuereg.h: netbsd-7-nhusb
sys/dev/usb/if_kue.c: netbsd-7-nhusb
sys/dev/usb/if_kuereg.h: netbsd-7-nhusb
sys/dev/usb/if_otus.c: netbsd-7-nhusb
sys/dev/usb/if_otusvar.h: netbsd-7-nhusb
sys/dev/usb/if_rum.c: netbsd-7-nhusb
sys/dev/usb/if_rumreg.h: netbsd-7-nhusb
sys/dev/usb/if_rumvar.h: netbsd-7-nhusb
sys/dev/usb/if_run.c: netbsd-7-nhusb
sys/dev/usb/if_runvar.h: netbsd-7-nhusb
sys/dev/usb/if_smsc.c: netbsd-7-nhusb
sys/dev/usb/if_smscreg.h: netbsd-7-nhusb
sys/dev/usb/if_smscvar.h: netbsd-7-nhusb
sys/dev/usb/if_udav.c: netbsd-7-nhusb
sys/dev/usb/if_udavreg.h: netbsd-7-nhusb
sys/dev/usb/if_upgt.c: netbsd-7-nhusb
sys/dev/usb/if_upgtvar.h: netbsd-7-nhusb
sys/dev/usb/if_upl.c: netbsd-7-nhusb
sys/dev/usb/if_ural.c: netbsd-7-nhusb
sys/dev/usb/if_uralreg.h: netbsd-7-nhusb
sys/dev/usb/if_uralvar.h: netbsd-7-nhusb
sys/dev/usb/if_url.c: netbsd-7-nhusb
sys/dev/usb/if_urlreg.h: netbsd-7-nhusb
sys/dev/usb/if_urndis.c: netbsd-7-nhusb
sys/dev/usb/if_urndisreg.h: netbsd-7-nhusb
sys/dev/usb/if_urtw.c: netbsd-7-nhusb
sys/dev/usb/if_urtwn.c: netbsd-7-nhusb
sys/dev/usb/if_urtwn_data.h: netbsd-7-nhusb
sys/dev/usb/if_urtwnreg.h: netbsd-7-nhusb
sys/dev/usb/if_urtwnvar.h: netbsd-7-nhusb
sys/dev/usb/if_urtwreg.h: netbsd-7-nhusb
sys/dev/usb/if_zyd.c: netbsd-7-nhusb
sys/dev/usb/if_zydreg.h: netbsd-7-nhusb
sys/dev/usb/irmce.c: netbsd-7-nhusb
sys/dev/usb/moscom.c: netbsd-7-nhusb
sys/dev/usb/motg.c: netbsd-7-nhusb
sys/dev/usb/motgvar.h: netbsd-7-nhusb
sys/dev/usb/ohci.c: netbsd-7-nhusb
sys/dev/usb/ohcireg.h: netbsd-7-nhusb
sys/dev/usb/ohcivar.h: netbsd-7-nhusb
sys/dev/usb/pseye.c: netbsd-7-nhusb
sys/dev/usb/slurm.c: netbsd-7-nhusb
sys/dev/usb/stuirda.c: netbsd-7-nhusb
sys/dev/usb/u3g.c: netbsd-7-nhusb
sys/dev/usb/uark.c: netbsd-7-nhusb
sys/dev/usb/uatp.c: netbsd-7-nhusb
sys/dev/usb/uaudio.c: netbsd-7-nhusb
sys/dev/usb/uberry.c: netbsd-7-nhusb
sys/dev/usb/ubsa.c: netbsd-7-nhusb
sys/dev/usb/ubsa_common.c: netbsd-7-nhusb
sys/dev/usb/ubsavar.h: netbsd-7-nhusb
sys/dev/usb/ubt.c: netbsd-7-nhusb
sys/dev/usb/uchcom.c: netbsd-7-nhusb
sys/dev/usb/ucom.c: netbsd-7-nhusb
sys/dev/usb/ucomvar.h: netbsd-7-nhusb
sys/dev/usb/ucycom.c: netbsd-7-nhusb
sys/dev/usb/udl.c: netbsd-7-nhusb
sys/dev/usb/udl.h: netbsd-7-nhusb
sys/dev/usb/udsbr.c: netbsd-7-nhusb
sys/dev/usb/udsir.c: netbsd-7-nhusb
sys/dev/usb/uep.c: netbsd-7-nhusb
sys/dev/usb/uftdi.c: netbsd-7-nhusb
sys/dev/usb/uftdireg.h: netbsd-7-nhusb
sys/dev/usb/ugen.c: netbsd-7-nhusb
sys/dev/usb/ugensa.c: netbsd-7-nhusb
sys/dev/usb/uhci.c: netbsd-7-nhusb
sys/dev/usb/uhcireg.h: netbsd-7-nhusb
sys/dev/usb/uhcivar.h: netbsd-7-nhusb
sys/dev/usb/uhid.c: netbsd-7-nhusb
sys/dev/usb/uhidev.c: netbsd-7-nhusb
sys/dev/usb/uhidev.h: netbsd-7-nhusb
sys/dev/usb/uhmodem.c: netbsd-7-nhusb
sys/dev/usb/uhso.c: netbsd-7-nhusb
sys/dev/usb/uhub.c: netbsd-7-nhusb
sys/dev/usb/uipad.c: netbsd-7-nhusb
sys/dev/usb/uipaq.c: netbsd-7-nhusb
sys/dev/usb/uirda.c: netbsd-7-nhusb
sys/dev/usb/uirdavar.h: netbsd-7-nhusb
sys/dev/usb/ukbd.c: netbsd-7-nhusb
sys/dev/usb/ukbdmap.c: netbsd-7-nhusb
sys/dev/usb/ukyopon.c: netbsd-7-nhusb
sys/dev/usb/ukyopon.h: netbsd-7-nhusb
sys/dev/usb/ulpt.c: netbsd-7-nhusb
sys/dev/usb/umass.c: netbsd-7-nhusb
sys/dev/usb/umass_isdata.c: netbsd-7-nhusb
sys/dev/usb/umass_isdata.h: netbsd-7-nhusb
sys/dev/usb/umass_quirks.c: netbsd-7-nhusb
sys/dev/usb/umass_quirks.h: netbsd-7-nhusb
sys/dev/usb/umass_scsipi.c: netbsd-7-nhusb
sys/dev/usb/umass_scsipi.h: netbsd-7-nhusb
sys/dev/usb/umassvar.h: netbsd-7-nhusb
sys/dev/usb/umcs.c: netbsd-7-nhusb
sys/dev/usb/umct.c: netbsd-7-nhusb
sys/dev/usb/umidi.c: netbsd-7-nhusb
sys/dev/usb/umidi_quirks.c: netbsd-7-nhusb
sys/dev/usb/umidi_quirks.h: netbsd-7-nhusb
sys/dev/usb/umodem.c: netbsd-7-nhusb
sys/dev/usb/umodem_common.c: netbsd-7-nhusb
sys/dev/usb/umodemvar.h: netbsd-7-nhusb
sys/dev/usb/ums.c: netbsd-7-nhusb
sys/dev/usb/uplcom.c: netbsd-7-nhusb
sys/dev/usb/urio.c: netbsd-7-nhusb
sys/dev/usb/urio.h: netbsd-7-nhusb
sys/dev/usb/usb.c: netbsd-7-nhusb
sys/dev/usb/usb.h: netbsd-7-nhusb
sys/dev/usb/usb_mem.c: netbsd-7-nhusb
sys/dev/usb/usb_mem.h: netbsd-7-nhusb
sys/dev/usb/usb_quirks.c: netbsd-7-nhusb
sys/dev/usb/usb_quirks.h: netbsd-7-nhusb
sys/dev/usb/usb_subr.c: netbsd-7-nhusb
sys/dev/usb/usbdevices.config: netbsd-7-nhusb
sys/dev/usb/usbdevs: netbsd-7-nhusb
sys/dev/usb/usbdevs.h: netbsd-7-nhusb
sys/dev/usb/usbdevs_data.h: netbsd-7-nhusb
sys/dev/usb/usbdi.c: netbsd-7-nhusb
sys/dev/usb/usbdi.h: netbsd-7-nhusb
sys/dev/usb/usbdi_util.c: netbsd-7-nhusb
sys/dev/usb/usbdi_util.h: netbsd-7-nhusb
sys/dev/usb/usbdivar.h: netbsd-7-nhusb
sys/dev/usb/usbhid.h: netbsd-7-nhusb
sys/dev/usb/usbhist.h: netbsd-7-nhusb
sys/dev/usb/usbroothub.c: netbsd-7-nhusb
sys/dev/usb/usbroothub.h: netbsd-7-nhusb
sys/dev/usb/usbroothub_subr.c: delete
sys/dev/usb/usbroothub_subr.h: delete
sys/dev/usb/uscanner.c: netbsd-7-nhusb
sys/dev/usb/uslsa.c: netbsd-7-nhusb
sys/dev/usb/usscanner.c: netbsd-7-nhusb
sys/dev/usb/ustir.c: netbsd-7-nhusb
sys/dev/usb/uthum.c: netbsd-7-nhusb
sys/dev/usb/utoppy.c: netbsd-7-nhusb
sys/dev/usb/uts.c: netbsd-7-nhusb
sys/dev/usb/uvideo.c: netbsd-7-nhusb
sys/dev/usb/uvisor.c: netbsd-7-nhusb
sys/dev/usb/uvscom.c: netbsd-7-nhusb
sys/dev/usb/uyap.c: netbsd-7-nhusb
sys/dev/usb/uyap_firmware.h: netbsd-7-nhusb
sys/dev/usb/uyurex.c: netbsd-7-nhusb
sys/dev/usb/x1input_rdesc.h: netbsd-7-nhusb
sys/dev/usb/xhci.c: netbsd-7-nhusb
sys/dev/usb/xhcireg.h: netbsd-7-nhusb
sys/dev/usb/xhcivar.h: netbsd-7-nhusb
sys/dev/usb/xinput_rdesc.h: netbsd-7-nhusb
sys/external/bsd/common/conf/files.linux: netbsd-7-nhusb
sys/external/bsd/common/include/linux/err.h: netbsd-7-nhusb
sys/external/bsd/common/include/linux/kernel.h: netbsd-7-nhusb
sys/external/bsd/common/include/linux/workqueue.h: netbsd-7-nhusb
sys/external/bsd/common/linux/linux_work.c: netbsd-7-nhusb
sys/external/bsd/drm2/dist/drm/radeon/atombios_encoders.c: netbsd-7-nhusb
sys/external/bsd/drm2/dist/drm/radeon/radeon_legacy_encoders.c: netbsd-7-nhusb
sys/external/bsd/drm2/drm/files.drmkms: netbsd-7-nhusb
sys/external/bsd/drm2/i915drm/files.i915drmkms: netbsd-7-nhusb
sys/external/bsd/drm2/include/linux/err.h: delete
sys/external/bsd/drm2/include/linux/workqueue.h: delete
sys/external/bsd/drm2/linux/files.drmkms_linux: netbsd-7-nhusb
sys/external/bsd/drm2/linux/linux_work.c: delete
sys/external/bsd/dwc2/dwc2.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dwc2.h: netbsd-7-nhusb
sys/external/bsd/dwc2/dwc2var.h: netbsd-7-nhusb
sys/external/bsd/dwc2/dwctwo2netbsd: netbsd-7-nhusb
sys/external/bsd/dwc2/conf/files.dwc2: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_core.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_core.h: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_coreintr.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hcd.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hcd.h: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hcdddma.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hcdintr.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hcdqueue.c: netbsd-7-nhusb
sys/external/bsd/dwc2/dist/dwc2_hw.h: netbsd-7-nhusb
sys/modules/drmkms_linux/Makefile: netbsd-7-nhusb
sys/modules/i915drmkms/Makefile: netbsd-7-nhusb
sys/rump/dev/lib/libugenhc/ugenhc.c: netbsd-7-nhusb
sys/rump/dev/lib/libusb/Makefile: netbsd-7-nhusb
sys/rump/dev/lib/libusb/USB.ioconf: netbsd-7-nhusb
sys/rump/dev/lib/libusb/usb_at_ugenhc.c: delete
sys/rump/dev/lib/libusb/opt/opt_usb.h: delete
sys/rump/dev/lib/libusb/opt/opt_usbverbose.h: delete
sys/sys/mbuf.h: netbsd-7-nhusb
usr.sbin/usbdevs/usbdevs.8: netbsd-7-nhusb
usr.sbin/usbdevs/usbdevs.c: netbsd-7-nhusb
Merge netbsd-7-nhusb:
- API / infrastructure changes to support memory management changes.
- Memory management improvements and bug fixes.
- HCDs should now be MP safe
- conversion to KERNHIST based debug
- FS/LS isoc support on ehci(4).
- conversion to kmem(9)
- Some USB 3 support - mostly from Takahiro HAYASHI (t-hash).
- interrupt transfers now get proper DMA operations
- general bug fixes
- kern/48308
- uhub status notification improvements
- umass(4) probe fix (applied to HEAD already)
- ohci(4) short transfer fix
- Change the SOFTINT level from NET to SERIAL for the USB softint handler.
This gives the callback a chance of running when another softint handler
at SOFTINT_NET has blocked holding a lock, e.g. softnet_lock and most of
the network stack.
- kern/49065 - ifconfig tun0 ... sequence locks up system / lockup:
softnet_lock held across usb xfr
- kern/50491 - unkillable wait in usbd_transfer while using usmsc0
on raspberry pi 2
- kern/51395 - USB Ethernet makes xhci hang
- Various improvements to slhci(4)
- Various improvements to dwc2(4)
 1.39.2.1  21-Mar-2015  snj branches: 1.39.2.1.4;
Pull up following revision(s) (requested by mrg in ticket #626):
sys/dev/usb/TODO.usbmp: revision 1.9
sys/dev/usb/uatp.c: revision 1.11
sys/dev/usb/ucycom.c: revision 1.42
sys/dev/usb/uhid.c: revision 1.93, 1.94
sys/dev/usb/uhidev.c: revision 1.63
sys/dev/usb/uhidev.h: revision 1.17
sys/dev/usb/ukbd.c: revision 1.130
sys/dev/usb/uyurex.c: revision 1.10
properly protect uhid's sc_q member with sc_lock. should fix PR#49728.
while here, remove D_MPSAFE from uhid* and all uhid users, as it really
needs all the callers to be safe and they're not.
--
don't take the device lock when stopping the uhidev. that calls
to abort and close pipes, both of which may take an adaptive lock.
fixes a LOCKDEBUG abort see on one particular machine.
 1.39.2.1.4.2  26-Jan-2017  skrll Sync with HEAD/nhusb
 1.39.2.1.4.1  06-Sep-2016  skrll First pass at netbsd-7 updated with USB code from HEAD
 1.41.2.10  05-Dec-2016  skrll Sync with HEAD
 1.41.2.9  09-Jul-2016  skrll Sync with HEAD
 1.41.2.8  06-Oct-2015  skrll Move from usbd_{alloc,free}_xfer and usbd_{alloc,free}_buffer to
usbd_{create,destroy}_xfer. The API change will allow future changes
to HCDs to simplify the transfer resource allocation and activation.

Several devices tested including ucom, umass, smsc, uvideo, and uaudio.
 1.41.2.7  06-Apr-2015  skrll Sync with HEAD
 1.41.2.6  21-Mar-2015  skrll Add prefixes to attach_arg structure member names. No functional change.
 1.41.2.5  19-Mar-2015  skrll Do the same as OpenBSD and get rid of the *_handle typedefs and use
plain structures insteads
 1.41.2.4  06-Dec-2014  skrll KNF. Remove argument name from function declarations.

No functional change.
 1.41.2.3  05-Dec-2014  skrll KNF. Remove ( ) from return statements.
 1.41.2.2  03-Dec-2014  skrll Replace malloc(9) with kmem(9)
 1.41.2.1  30-Nov-2014  skrll Use C99 types. u_int{8,16,32,64}_t to uint{8,16,32,64}_t.

No functional change.
 1.44.2.1  07-Jan-2017  pgoyette Sync with HEAD. (Note that most of these changes are simply $NetBSD$
tag issues.)
 1.45.8.1  02-Jan-2020  martin Pull up following revision(s) (requested by maxv in ticket #1480):

sys/dev/usb/uthum.c: revision 1.18
sys/dev/usb/ucycom.c: revision 1.49
sys/dev/usb/uhid.c: revision 1.111

Fix buffer overflows. sc_{o,f}len are controlled by the USB device. By
crafting the former the device can leak stack data. By crafting the latter
the device can overwrite the stack. The combination of the two means the
device can ROP the kernel and obtain code execution (demonstrated with an
actual exploit over vHCI).

Truncate the lengths to the size of the buffers, and also drop sc_ilen
since it is unused. Patch tested with vHCI+kASan.

-

Fix buffer overflows. Also add missing mutex_exit.

-

Fix buffer overflows: validate the lengths at attach time, given that they
are apparently not supposed to be variable. Drop sc_ilen since it is
unused.
 1.46.4.2  08-Apr-2020  martin Merge changes from current as of 20200406
 1.46.4.1  10-Jun-2019  christos Sync with HEAD
 1.47.2.1  02-Jan-2020  martin Pull up following revision(s) (requested by maxv in ticket #595):

sys/dev/usb/uthum.c: revision 1.18
sys/dev/usb/ucycom.c: revision 1.49
sys/dev/usb/uhid.c: revision 1.111

Fix buffer overflows. sc_{o,f}len are controlled by the USB device. By
crafting the former the device can leak stack data. By crafting the latter
the device can overwrite the stack. The combination of the two means the
device can ROP the kernel and obtain code execution (demonstrated with an
actual exploit over vHCI).

Truncate the lengths to the size of the buffers, and also drop sc_ilen
since it is unused. Patch tested with vHCI+kASan.

-

Fix buffer overflows. Also add missing mutex_exit.

-

Fix buffer overflows: validate the lengths at attach time, given that they
are apparently not supposed to be variable. Drop sc_ilen since it is
unused.
 1.56.2.1  12-Sep-2024  martin Pull up following revision(s) (requested by rin in ticket #841):

sys/dev/usb/ucycom.c: revision 1.57

Prevent errant ucycom-presenting device from causing up to 225
bytes of kernel memory following input buffer to leak to tty
application.

Probably not practically expolitable, but you never know.

RSS XML Feed