summaryrefslogtreecommitdiff
path: root/sys/dev/usb/usb.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix build of USB bootloader code by adding checks for _STANDALONE being defined.Hans Petter Selasky2020-11-181-2/+2
| | | | | | | | | | Currently the USB bootloader code is not part of buildworld. MFC after: 1 week Sponsored by: Mellanox Technologies // NVIDIA Networking Notes: svn path=/head/; revision=367787
* Correctly implement support for remote wakeup for USB 3.0 device.Hans Petter Selasky2020-03-191-0/+5
| | | | | | | | | Submitted by: Horse Ma <Shichun.Ma@dell.com> MFC after: 1 week Sponsored by: Mellanox Technologies Notes: svn path=/head/; revision=359120
* Add cdceem(4) driver, for virtual ethernet devices compliantEdward Tomasz Napierala2019-08-071-0/+1
| | | | | | | | | | | | | | | | | with Communication Device Class Ethernet Emulation Model (CDC EEM). The driver supports both the device, and host side operation; there is a new USB template (#11) for the former. This enables communication with virtual USB NIC provided by iLO 5, as found in new HPE Proliant servers. Reviewed by: hselasky MFC after: 2 weeks Relnotes: yes Sponsored by: Hewlett Packard Enterprise Notes: svn path=/head/; revision=350685
* sys/dev: further adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-271-0/+2
| | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. Notes: svn path=/head/; revision=326255
* Add definition of the ISOCHRONOUS endpoint usage bits.Hans Petter Selasky2015-03-251-0/+5
| | | | | | | | | Refer to the USB v2.0 specification for more information. MFC after: 1 week Notes: svn path=/head/; revision=280598
* Remove no longer used allocation type.Hans Petter Selasky2015-03-171-1/+0
| | | | | | | Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com> Notes: svn path=/head/; revision=280168
* Actually change the USB_PORT_ROOT_RESET_DELAY definition as stated inHans Petter Selasky2014-10-221-1/+1
| | | | | | | | | | | the r241987 commit message, instead of having users locally overriding the value using tunables in /boot/loader.conf . Found by: Adam Parco Discussed with: Nick Hibma Notes: svn path=/head/; revision=273456
* Import USB RNDIS driver to FreeBSD from OpenBSD.Hans Petter Selasky2014-02-061-0/+3
| | | | | | | | | | | | | | | | | Useful for so-called USB tethering. - Imported code from OpenBSD - Adapted code to FreeBSD - Removed some unused functions - Fixed some buffer encoding and decoding issues - Optimised data transport path a bit, by sending multiple packets at a time - Increased receive buffer to 16K Obtained from: OpenBSD Requested by: eadler @ MFC after: 2 weeks Notes: svn path=/head/; revision=261541
* Allow the Arduino Leonardo to work by supporting CDC=0 devices.Adrian Chadd2013-10-311-0/+1
| | | | | | | | | | | | | CDC=0 simply means "no command codes", CDC=1 means "AT command codes." There's no driver change required! It's purely to tell the application layer whether to speak AT commands or not. Things are all still serial. PR: usb/183505 Reviewed by: hps MFC after: 1 week Notes: svn path=/head/; revision=257446
* Use an anonymous struct for generated string descriptors.Hans Petter Selasky2013-01-301-4/+3
| | | | | | | Submitted by: Christoph Mallon Notes: svn path=/head/; revision=246124
* Provide one global language string descriptor forHans Petter Selasky2013-01-301-0/+7
| | | | | | | | | | american english instead of giving each module its own. Submitted by: Christoph Mallon Notes: svn path=/head/; revision=246123
* Modify the FreeBSD USB kernel code so that it can be compiled directlyHans Petter Selasky2013-01-301-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | into the FreeBSD boot loader, typically for non-USB aware BIOSes, EFI systems or embedded platforms. This is also useful for out of the system compilation of the FreeBSD USB stack for various purposes. The USB kernel files can now optionally include a global header file which should include all needed definitions required to compile the FreeBSD USB stack. When the global USB header file is included, no other USB header files will be included by default. Add new file containing the USB stack configuration for the FreeBSD loader build. Replace some __FBSDID()'s by /* $FreeBSD$ */ comments. Now all USB files follow the same style. Use cases: - console in loader via USB - loading kernel via USB Discussed with: Hiroki Sato, hrs @ EuroBSDCon Notes: svn path=/head/; revision=246122
* Make several timing parameters of the USB enumeration sequence tuneable.Hans Petter Selasky2012-10-241-23/+21
| | | | | | | | | | | | | | Also update the port reset time from 250ms to 50ms. Some USB devices have a hard limit in hardware at 222ms for the port reset time and will not enumerate unless this delay is closer to the usb.org defined value. This patch can fix enumeration with some USB devices. Tested by: Guido van Rooij Submitted by: Nick Hibma MFC after: 1 week Notes: svn path=/head/; revision=241987
* Add support for the so-called streams feature of BULK endpointsHans Petter Selasky2012-08-121-2/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | in SUPER-speed mode, USB 3.0. This feature has not been tested yet, due to lack of hardware. This feature is useful when implementing protocols like UASP, USB attached SCSI which promises higher USB mass storage throughput. This patch also implements support for hardware processing of endpoints for increased performance. The switching to hardware processing of an endpoint is done via a callback to the USB controller driver. The stream feature is implemented like a variant of a hardware USB protocol. USB controller drivers implementing device mode needs to be updated to implement the new "xfer_stall" USB controller method and remove the "xfer" argument from the "set_stall" method. The API's toward existing USB drivers are preserved. To setup a USB transfer in stream mode, set the "stream_id" field of the USB config structure to the desired value. The maximum number of BULK streams is currently hardcoded and limited to 8 via a define in usb_freebsd.h. All USB drivers should be re-compiled after this change. LibUSB will be updated next week to support streams mode. A new IOCTL to setup BULK streams as already been implemented. The ugen device nodes currently only supports stream ID zero. The FreeBSD version has been bumped. MFC after: 2 weeks Notes: svn path=/head/; revision=239214
* Add definitions and structures for USB 2.0 Link Power Management, LPM.Hans Petter Selasky2012-04-021-3/+13
| | | | | | | MFC after: 2 weeks Notes: svn path=/head/; revision=233771
* - Try to fix support for USB 3.0 HUBs.Hans Petter Selasky2012-01-121-0/+1
| | | | | | | | | - Try to fix support for USB 3.0 suspend and resume. MFC after: 1 week Notes: svn path=/head/; revision=230032
* Fix size of USB 3.0 descriptor field.Hans Petter Selasky2011-11-091-1/+1
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=227401
* Fix size of USB 3.0 descriptor field.Hans Petter Selasky2011-11-091-1/+1
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=227396
* Fix suspend and resume of FULL and HIGH speed USB devicesHans Petter Selasky2011-10-261-0/+1
| | | | | | | | | | in the generic XHCI driver. There appears to be some minor logic missing for this feature to work. MFC after: 3 days Notes: svn path=/head/; revision=226803
* Add missing USB 3.0 definitions. Correct some wrong ones.Hans Petter Selasky2010-10-041-6/+28
| | | | | | | Approved by: thompsa (mentor) Notes: svn path=/head/; revision=213427
* Add basic support for USB Network Control Model (NCM) v1.0 to if_cdce.c.Andrew Thompson2009-09-281-2/+3
| | | | | | | | | http://www.usb.org/developers/devclass_docs/NCM10.zip Submitted by: Hans Petter Selasky Notes: svn path=/head/; revision=197563
* - Fix false positive uipaq probeAlfred Perlstein2009-08-241-0/+2
| | | | | | | | | Reported by: Alexander Motin <mav@freebsd.org> Submitted by: hps Notes: svn path=/head/; revision=196493
* - Make struct usb_xfer opaque so that drivers can not access the internalsAndrew Thompson2009-06-231-0/+85
| | | | | | | - Reduce the number of headers needed for a usb driver, the common case is just usb.h and usbdi.h Notes: svn path=/head/; revision=194677
* Fix _USB2_* refernces in the header protection defines.Andrew Thompson2009-06-151-3/+3
| | | | Notes: svn path=/head/; revision=194230
* Rename usb pipes to endpoints as it better represents what they are, and structAndrew Thompson2009-06-071-2/+2
| | | | | | | usb_pipe may be used for a different purpose later on. Notes: svn path=/head/; revision=193644
* s/usb2_/usb_/ on all C structs for the USB stack.Andrew Thompson2009-05-281-44/+44
| | | | Notes: svn path=/head/; revision=192984
* MFp4 //depot/projects/usb@159897Andrew Thompson2009-04-051-2/+4
| | | | | | | | | Add new endpoint direction values for use with usb2_config Submitted by: Hans Petter Selasky Notes: svn path=/head/; revision=190732
* Reintroduce r188878, provide compat typedefs for usb1.Andrew Thompson2009-02-231-0/+24
| | | | Notes: svn path=/head/; revision=188947
* Move the new USB stack into its new home.Andrew Thompson2009-02-231-0/+619
| | | | Notes: svn path=/head/; revision=188942
* Move usb to a graveyard location under sys/legacy/dev, it is intended that theAndrew Thompson2009-02-231-708/+0
| | | | | | | | | | new USB2 stack will fully replace this for 8.0. Remove kernel modules, a subsequent commit will update conf/files. Unhook usbdevs from the build. Notes: svn path=/head/; revision=188939
* Add a reset device command to ugen.c.Nick Hibma2008-11-131-0/+1
| | | | | | | | This is needed to make some devices work that require a firmware upload and a USB reset afterwards. Notes: svn path=/head/; revision=184941
* Add isochronous transfer support for USB 2.0Kevin Lo2008-08-181-0/+2
| | | | | | | Obtained from: NetBSD Notes: svn path=/head/; revision=181820
* Add definition for UIPROTO_MOUSE.Warner Losh2007-06-301-0/+1
| | | | | | | Approved by: re@ Notes: svn path=/head/; revision=171097
* Remove usb_port.h from usb.h, except for one or two useful things thatWarner Losh2007-06-181-2/+4
| | | | | | | don't belong there (these moved into usb.h). Notes: svn path=/head/; revision=170940
* Move PWR_* from usb_port.h to usb.hWarner Losh2007-06-141-0/+8
| | | | Notes: svn path=/head/; revision=170729
* Move malloc definitions to usb.h.Warner Losh2007-06-141-4/+3
| | | | | | | | | | Also, remove usb_malloc_type: it was unused. Remove METHODS_NONE: it was unused. Move include of opt_usb.h from usb_port.h to usb.h, since usb_port.h is going away (there will be a usb_compat.h for out-of-tree drivers that want it). Notes: svn path=/head/; revision=170727
* Remove more __OtherBSD__ ifdefs that don't make sense, and haven't forWarner Losh2007-06-131-4/+0
| | | | | | | some time. Notes: svn path=/head/; revision=170656
* Remove compat ifdefs for version < 500014 from the rest of the USB files.Christian Brueffer2007-06-071-4/+0
| | | | | | | | Approved by: rwatson (mentor) MFC after: 1 week Notes: svn path=/head/; revision=170397
* s/Static/static/gWarner Losh2006-09-061-0/+8
| | | | | | | | | | | | | s/device_ptr_t/device_t/g No md5 changes in the .o's # Note to the md5 tracking club: $FreeBSD$ changes md5 after every commit # so you need to checkout -kk to get $FreeBSD$ instead of the actual value # of the keyword. Notes: svn path=/head/; revision=162095
* Add support for Xbox 360 gamepads. They are HID-capable devices, butMaxime Henrion2005-12-311-0/+2
| | | | | | | | | | | | | lack a report descriptor and don't use the standard interface class. This patch works around these deficiencies so that the uhid(4) driver can recognize and use those broken devices. PR: usb/90141 Submitted by: Ed Schouten <ed@fxq.nl> (with minor mods from me) MFC after: 1 week Notes: svn path=/head/; revision=153924
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-061-1/+1
| | | | Notes: svn path=/head/; revision=139749
* Packed structures are defined differently in older gcc's, like the oneJosef Karthauser2002-11-061-0/+4
| | | | | | | | currently in -stable. Put the exception into usb.h instead of having it hard coded in the sound code. Notes: svn path=/head/; revision=106529
* MFNetBSD: Increasre the reset recovery time. (rev 1.69)Josef Karthauser2002-09-271-3/+3
| | | | Notes: svn path=/head/; revision=104050
* MFNetBSD: Update class codes. (rev 1.68)Josef Karthauser2002-09-271-5/+13
| | | | Notes: svn path=/head/; revision=104049
* MFNetBSD: Add Bluetooth related classes etc. (rev 1.67)Josef Karthauser2002-09-271-5/+12
| | | | Notes: svn path=/head/; revision=104047
* MFNetBSD: revision 1.66Josef Karthauser2002-09-271-6/+6
| | | | | | | Get rid of trailing white space. Notes: svn path=/head/; revision=104046
* s/__attribute__((__packed__))/__packed/gAlfred Perlstein2002-09-231-1/+1
| | | | Notes: svn path=/head/; revision=103842
* Revert part of the last commit. A couple of defines were removedJosef Karthauser2002-02-261-0/+4
| | | | | | | by NetBSD because they don't use them (they've no usbd), but we do. Notes: svn path=/head/; revision=91294
* Merge from NetBSD:Josef Karthauser2002-02-261-16/+4
| | | | | | | | | | | | | | | | usb.h (rev 1.61): date: 2002/01/01 14:23:37; author: augustss; Add a missing subclass definition. usb.h (rev 1.63) and usb_port.h (rev 1.52): date: 2002/02/25 00:46:37; author: augustss; Some portability improvement. Add define for usb.h version. Notes: svn path=/head/; revision=91267
* Prefix structure members to protect them against clashes with eg.Alfred Perlstein2002-02-201-48/+48
| | | | | | | | | | | | c++ keywords. This keeps us in sync with NetBSD because they actually committed my delta first. Ok'd by: lennard Notes: svn path=/head/; revision=90996