FreeBSD kernel usb device Code
usb_freebsd.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define USB_HAVE_UGEN   1
 
#define USB_HAVE_DEVCTL   1
 
#define USB_HAVE_BUSDMA   1
 
#define USB_HAVE_COMPAT_LINUX   1
 
#define USB_HAVE_USER_IO   1
 
#define USB_HAVE_MBUF   1
 
#define USB_HAVE_TT_SUPPORT   1
 
#define USB_HAVE_POWERD   1
 
#define USB_HAVE_MSCTEST   1
 
#define USB_HAVE_MSCTEST_DETACH   1
 
#define USB_HAVE_PF   1
 
#define USB_HAVE_ROOT_MOUNT_HOLD   1
 
#define USB_HAVE_ID_SECTION   1
 
#define USB_HAVE_PER_BUS_PROCESS   1
 
#define USB_HAVE_FIXED_ENDPOINT   0
 
#define USB_HAVE_FIXED_IFACE   0
 
#define USB_HAVE_FIXED_CONFIG   0
 
#define USB_HAVE_FIXED_PORT   0
 
#define USB_HAVE_DISABLE_ENUM   1
 
#define USB_HAVE_MALLOC_WAITOK   1
 
#define USB_CALLOUT_ZERO_TICKS   1
 
#define USB_TD_GET_PROC(td)   (td)->td_proc
 
#define USB_PROC_GET_GID(td)   (td)->p_pgid
 
#define USB_HOST_ALIGN   8 /* bytes, must be power of two */
 
#define USB_FS_ISOC_UFRAME_MAX   4 /* exclusive unit */
 
#define USB_BUS_MAX   256 /* units */
 
#define USB_MAX_DEVICES   128 /* units */
 
#define USB_CONFIG_MAX   65535 /* bytes */
 
#define USB_IFACE_MAX   32 /* units */
 
#define USB_FIFO_MAX   128 /* units */
 
#define USB_MAX_EP_STREAMS   8 /* units */
 
#define USB_MAX_EP_UNITS   32 /* units */
 
#define USB_MAX_PORTS   255 /* units */
 
#define USB_MAX_FS_ISOC_FRAMES_PER_XFER   (120) /* units */
 
#define USB_MAX_HS_ISOC_FRAMES_PER_XFER   (8*120) /* units */
 
#define USB_HUB_MAX_DEPTH   5
 
#define USB_EP0_BUFSIZE   1024 /* bytes */
 
#define USB_CS_RESET_LIMIT   20 /* failures = 20 * 50 ms = 1sec */
 
#define USB_MAX_AUTO_QUIRK   8 /* maximum number of dynamic quirks */
 
#define USB_IN_POLLING_MODE_FUNC()   usbd_in_polling_mode()
 
#define USB_IN_POLLING_MODE_VALUE()   (SCHEDULER_STOPPED() || kdb_active)
 

Typedefs

typedef uint32_t usb_timeout_t
 
typedef uint32_t usb_frlength_t
 
typedef uint32_t usb_frcount_t
 
typedef uint32_t usb_size_t
 
typedef uint32_t usb_ticks_t
 
typedef uint16_t usb_power_mask_t
 
typedef uint16_t usb_stream_t
 

Macro Definition Documentation

◆ USB_BUS_MAX

#define USB_BUS_MAX   256 /* units */

Definition at line 78 of file usb_freebsd.h.

◆ USB_CALLOUT_ZERO_TICKS

#define USB_CALLOUT_ZERO_TICKS   1

Definition at line 59 of file usb_freebsd.h.

◆ USB_CONFIG_MAX

#define USB_CONFIG_MAX   65535 /* bytes */

Definition at line 80 of file usb_freebsd.h.

◆ USB_CS_RESET_LIMIT

#define USB_CS_RESET_LIMIT   20 /* failures = 20 * 50 ms = 1sec */

Definition at line 92 of file usb_freebsd.h.

◆ USB_EP0_BUFSIZE

#define USB_EP0_BUFSIZE   1024 /* bytes */

Definition at line 91 of file usb_freebsd.h.

◆ USB_FIFO_MAX

#define USB_FIFO_MAX   128 /* units */

Definition at line 82 of file usb_freebsd.h.

◆ USB_FS_ISOC_UFRAME_MAX

#define USB_FS_ISOC_UFRAME_MAX   4 /* exclusive unit */

Definition at line 77 of file usb_freebsd.h.

◆ USB_HAVE_BUSDMA

#define USB_HAVE_BUSDMA   1

Definition at line 39 of file usb_freebsd.h.

◆ USB_HAVE_COMPAT_LINUX

#define USB_HAVE_COMPAT_LINUX   1

Definition at line 40 of file usb_freebsd.h.

◆ USB_HAVE_DEVCTL

#define USB_HAVE_DEVCTL   1

Definition at line 38 of file usb_freebsd.h.

◆ USB_HAVE_DISABLE_ENUM

#define USB_HAVE_DISABLE_ENUM   1

Definition at line 55 of file usb_freebsd.h.

◆ USB_HAVE_FIXED_CONFIG

#define USB_HAVE_FIXED_CONFIG   0

Definition at line 53 of file usb_freebsd.h.

◆ USB_HAVE_FIXED_ENDPOINT

#define USB_HAVE_FIXED_ENDPOINT   0

Definition at line 51 of file usb_freebsd.h.

◆ USB_HAVE_FIXED_IFACE

#define USB_HAVE_FIXED_IFACE   0

Definition at line 52 of file usb_freebsd.h.

◆ USB_HAVE_FIXED_PORT

#define USB_HAVE_FIXED_PORT   0

Definition at line 54 of file usb_freebsd.h.

◆ USB_HAVE_ID_SECTION

#define USB_HAVE_ID_SECTION   1

Definition at line 49 of file usb_freebsd.h.

◆ USB_HAVE_MALLOC_WAITOK

#define USB_HAVE_MALLOC_WAITOK   1

Definition at line 56 of file usb_freebsd.h.

◆ USB_HAVE_MBUF

#define USB_HAVE_MBUF   1

Definition at line 42 of file usb_freebsd.h.

◆ USB_HAVE_MSCTEST

#define USB_HAVE_MSCTEST   1

Definition at line 45 of file usb_freebsd.h.

◆ USB_HAVE_MSCTEST_DETACH

#define USB_HAVE_MSCTEST_DETACH   1

Definition at line 46 of file usb_freebsd.h.

◆ USB_HAVE_PER_BUS_PROCESS

#define USB_HAVE_PER_BUS_PROCESS   1

Definition at line 50 of file usb_freebsd.h.

◆ USB_HAVE_PF

#define USB_HAVE_PF   1

Definition at line 47 of file usb_freebsd.h.

◆ USB_HAVE_POWERD

#define USB_HAVE_POWERD   1

Definition at line 44 of file usb_freebsd.h.

◆ USB_HAVE_ROOT_MOUNT_HOLD

#define USB_HAVE_ROOT_MOUNT_HOLD   1

Definition at line 48 of file usb_freebsd.h.

◆ USB_HAVE_TT_SUPPORT

#define USB_HAVE_TT_SUPPORT   1

Definition at line 43 of file usb_freebsd.h.

◆ USB_HAVE_UGEN

#define USB_HAVE_UGEN   1

Definition at line 37 of file usb_freebsd.h.

◆ USB_HAVE_USER_IO

#define USB_HAVE_USER_IO   1

Definition at line 41 of file usb_freebsd.h.

◆ USB_HOST_ALIGN

#define USB_HOST_ALIGN   8 /* bytes, must be power of two */

Definition at line 70 of file usb_freebsd.h.

◆ USB_HUB_MAX_DEPTH

#define USB_HUB_MAX_DEPTH   5

Definition at line 90 of file usb_freebsd.h.

◆ USB_IFACE_MAX

#define USB_IFACE_MAX   32 /* units */

Definition at line 81 of file usb_freebsd.h.

◆ USB_IN_POLLING_MODE_FUNC

#define USB_IN_POLLING_MODE_FUNC ( )    usbd_in_polling_mode()

Definition at line 96 of file usb_freebsd.h.

◆ USB_IN_POLLING_MODE_VALUE

#define USB_IN_POLLING_MODE_VALUE ( )    (SCHEDULER_STOPPED() || kdb_active)

Definition at line 97 of file usb_freebsd.h.

◆ USB_MAX_AUTO_QUIRK

#define USB_MAX_AUTO_QUIRK   8 /* maximum number of dynamic quirks */

Definition at line 94 of file usb_freebsd.h.

◆ USB_MAX_DEVICES

#define USB_MAX_DEVICES   128 /* units */

Definition at line 79 of file usb_freebsd.h.

◆ USB_MAX_EP_STREAMS

#define USB_MAX_EP_STREAMS   8 /* units */

Definition at line 83 of file usb_freebsd.h.

◆ USB_MAX_EP_UNITS

#define USB_MAX_EP_UNITS   32 /* units */

Definition at line 84 of file usb_freebsd.h.

◆ USB_MAX_FS_ISOC_FRAMES_PER_XFER

#define USB_MAX_FS_ISOC_FRAMES_PER_XFER   (120) /* units */

Definition at line 87 of file usb_freebsd.h.

◆ USB_MAX_HS_ISOC_FRAMES_PER_XFER

#define USB_MAX_HS_ISOC_FRAMES_PER_XFER   (8*120) /* units */

Definition at line 88 of file usb_freebsd.h.

◆ USB_MAX_PORTS

#define USB_MAX_PORTS   255 /* units */

Definition at line 85 of file usb_freebsd.h.

◆ USB_PROC_GET_GID

#define USB_PROC_GET_GID (   td)    (td)->p_pgid

Definition at line 62 of file usb_freebsd.h.

◆ USB_TD_GET_PROC

#define USB_TD_GET_PROC (   td)    (td)->td_proc

Definition at line 61 of file usb_freebsd.h.

Typedef Documentation

◆ usb_frcount_t

typedef uint32_t usb_frcount_t

Definition at line 101 of file usb_freebsd.h.

◆ usb_frlength_t

typedef uint32_t usb_frlength_t

Definition at line 100 of file usb_freebsd.h.

◆ usb_power_mask_t

typedef uint16_t usb_power_mask_t

Definition at line 104 of file usb_freebsd.h.

◆ usb_size_t

typedef uint32_t usb_size_t

Definition at line 102 of file usb_freebsd.h.

◆ usb_stream_t

typedef uint16_t usb_stream_t

Definition at line 105 of file usb_freebsd.h.

◆ usb_ticks_t

typedef uint32_t usb_ticks_t

Definition at line 103 of file usb_freebsd.h.

◆ usb_timeout_t

typedef uint32_t usb_timeout_t

Definition at line 99 of file usb_freebsd.h.