最終更新:2022-01-20 (木) 18:13:03 (827d)
uapi/linux/usb/ch9.h
This file holds USB constants and structures that are needed for USB device APIs. These are used by the USB device model, which is defined in chapter 9 of the USB 2.0 specification and in the Wireless USB 1.0 (spread around). Linux has several APIs in C that need these: - the master/host side Linux-USB kernel driver API; - the "usbfs" user space API; and - the Linux "gadget" slave/device/peripheral side driver API.
構造体
- usb_ctrlrequest
- usb_descriptor_header?
- usb_device_descriptor
- usb_config_descriptor
- usb_string_descriptor?
- usb_interface_descriptor?
- usb_endpoint_descriptor
- usb_ss_ep_comp_descriptor?
- usb_qualifier_descriptor? - Device Qualifier descriptor
- usb_otg_descriptor? -
- usb_debug_descriptor?
- usb_interface_assoc_descriptor?
- usb_security_descriptor?
- usb_key_descriptor?
- usb_encryption_descriptor?
- usb_bos_descriptor?
- usb_dev_cap_header?
- usb_wireless_cap_descriptor?
- usb_ext_cap_descriptor?
- usb_ss_cap_descriptor?
- usb_ss_container_id_descriptor?
- usb_wireless_ep_comp_descriptor?
- usb_handshake?
- usb_connection_context?
enum
USB/標準リクエスト
定数 値 リクエスト USB_REQ_GET_STATUS? 0x00 GET_STATUS USB_REQ_CLEAR_FEATURE? 0x01 CLEAR_FEATURE USB_REQ_SET_FEATURE? 0x03 SET_FEATURE USB_REQ_SET_ADDRESS? 0x05 SET_ADDRESS USB_REQ_GET_DESCRIPTOR? 0x06 GET_DESCRIPTOR USB_REQ_SET_DESCRIPTOR? 0x07 SET_DESCRIPTOR? USB_REQ_GET_CONFIGURATION? 0x08 GET_CONFIGURATION USB_REQ_SET_CONFIGURATION? 0x09 SET_CONFIGURATION USB_REQ_GET_INTERFACE? 0x0A GET_INTERFACE? USB_REQ_SET_INTERFACE? 0x0B SET_INTERFACE USB_REQ_SYNCH_FRAME? 0x0C SYNCH_FRAME? USB_REQ_SET_SEL? 0x30 SET_SEL? USB_REQ_SET_ISOCH_DELAY? 0x31 SET_ISOCH_DELAY?
USB/ディスクリプタ
USB 2.0 spec table 9.5
USB_DT_DEVICE? 0x01 デバイスディスクリプタ usb_device_descriptor USB_DT_CONFIG? 0x02 コンフィグレーションディスクリプタ usb_config_descriptor USB_DT_STRING? 0x03 ストリングディスクリプタ usb_string_descriptor? USB_DT_INTERFACE? 0x04 インターフェイスディスクリプタ usb_interface_descriptor? USB_DT_ENDPOINT? 0x05 エンドポイントディスクリプタ usb_endpoint_descriptor USB_DT_DEVICE_QUALIFIER? 0x06 デバイスクオリファイアディスクリプタ usb_qualifier_descriptor? USB_DT_OTHER_SPEED_CONFIG? 0x07 アザースピードコンフィグレーションディスクリプタ USB_DT_INTERFACE_POWER? 0x08 インターフェイスパワーディスクリプタ
these are from a minor usb 2.0 revision (ECN)
these are from the Wireless USB spec
USB_DT_SECURITY? 0x0c usb_security_descriptor? USB_DT_KEY? 0x0d usb_key_descriptor? USB_DT_ENCRYPTION_TYPE? 0x0e usb_encryption_descriptor? USB_DT_BOS? 0x0f usb_bos_descriptor? USB_DT_DEVICE_CAPABILITY? 0x10 usb_wireless_cap_descriptor? USB_DT_WIRELESS_ENDPOINT_COMP? 0x11 USB_DT_WIRE_ADAPTER? 0x21 USB_DT_RPIPE? 0x22 USB_DT_CS_RADIO_CONTROL? 0x23
From the T10 UAS specification */
USB_DT_PIPE_USAGE? 0x24