4 * This file is part of the ReactOS PSDK package.
9 * THIS SOFTWARE IS NOT COPYRIGHTED
11 * This source code is offered for use in the public domain. You may
12 * use, modify or distribute it freely.
14 * This code is distributed in the hope that it will be useful but
15 * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
16 * DISCLAIMED. This includes but is not limited to warranties of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
23 /* Helper macro to enable gcc's extension. */
24 #ifndef __GNU_EXTENSION
26 #define __GNU_EXTENSION __extension__
28 #define __GNU_EXTENSION
36 typedef enum _USB_DEVICE_TYPE
{
41 typedef enum _USB_DEVICE_SPEED
{
47 #define USB_PORT_STATUS_CONNECT 0x0001
48 #define USB_PORT_STATUS_ENABLE 0x0002
49 #define USB_PORT_STATUS_SUSPEND 0x0004
50 #define USB_PORT_STATUS_OVER_CURRENT 0x0008
51 #define USB_PORT_STATUS_RESET 0x0010
52 #define USB_PORT_STATUS_POWER 0x0100
53 #define USB_PORT_STATUS_LOW_SPEED 0x0200
54 #define USB_PORT_STATUS_HIGH_SPEED 0x0400
57 typedef union _BM_REQUEST_TYPE
{
65 } BM_REQUEST_TYPE
, *PBM_REQUEST_TYPE
;
67 typedef struct _USB_DEFAULT_PIPE_SETUP_PACKET
{
68 BM_REQUEST_TYPE bmRequestType
;
71 __GNU_EXTENSION
struct {
78 __GNU_EXTENSION
struct {
85 } USB_DEFAULT_PIPE_SETUP_PACKET
, *PUSB_DEFAULT_PIPE_SETUP_PACKET
;
87 C_ASSERT(sizeof(USB_DEFAULT_PIPE_SETUP_PACKET
) == 8);
89 #define USB_DEVICE_QUALIFIER_DESCRIPTOR_TYPE 0x06
90 #define USB_OTHER_SPEED_CONFIGURATION_DESCRIPTOR_TYPE 0x07
92 typedef struct _USB_DEVICE_QUALIFIER_DESCRIPTOR
{
94 UCHAR bDescriptorType
;
97 UCHAR bDeviceSubClass
;
98 UCHAR bDeviceProtocol
;
99 UCHAR bMaxPacketSize0
;
100 UCHAR bNumConfigurations
;
102 } USB_DEVICE_QUALIFIER_DESCRIPTOR
, *PUSB_DEVICE_QUALIFIER_DESCRIPTOR
;
104 typedef union _USB_HIGH_SPEED_MAXPACKET
{
111 } USB_HIGH_SPEED_MAXPACKET
, *PUSB_HIGH_SPEED_MAXPACKET
;
113 #define USB_INTERFACE_ASSOCIATION_DESCRIPTOR_TYPE 0x0B
115 typedef struct _USB_INTERFACE_ASSOCIATION_DESCRIPTOR
{
117 UCHAR bDescriptorType
;
118 UCHAR bFirstInterface
;
119 UCHAR bInterfaceCount
;
120 UCHAR bFunctionClass
;
121 UCHAR bFunctionSubClass
;
122 UCHAR bFunctionProtocol
;
124 } USB_INTERFACE_ASSOCIATION_DESCRIPTOR
, *PUSB_INTERFACE_ASSOCIATION_DESCRIPTOR
;