]> git.ipfire.org Git - people/ms/u-boot.git/blobdiff - include/usbdescriptors.h
Various USB related patches
[people/ms/u-boot.git] / include / usbdescriptors.h
index 2d9f739343e23176c77608d56c4090198781a8c3..8336c188c108c29890bb8a429db566e460c554c7 100644 (file)
 #define COMMUNICATIONS_DEVICE_CLASS    0x02
 
 /* c.f. CDC 4.2 Table 15 */
-#define COMMUNICATIONS_INTERFACE_CLASS 0x02
+#define COMMUNICATIONS_INTERFACE_CLASS_CONTROL 0x02
+#define COMMUNICATIONS_INTERFACE_CLASS_DATA            0x0A
+#define COMMUNICATIONS_INTERFACE_CLASS_VENDOR  0x0FF
 
 /* c.f. CDC 4.3 Table 16 */
-#define COMMUNICATIONS_NO_SUBCLASS     0x00
+#define COMMUNICATIONS_NO_SUBCLASS             0x00
 #define COMMUNICATIONS_DLCM_SUBCLASS   0x01
-#define COMMUNICATIONS_ACM_SUBCLASS    0x02
-#define COMMUNICATIONS_TCM_SUBCLASS    0x03
+#define COMMUNICATIONS_ACM_SUBCLASS            0x02
+#define COMMUNICATIONS_TCM_SUBCLASS            0x03
 #define COMMUNICATIONS_MCCM_SUBCLASS   0x04
-#define COMMUNICATIONS_CCM_SUBCLASS    0x05
+#define COMMUNICATIONS_CCM_SUBCLASS            0x05
 #define COMMUNICATIONS_ENCM_SUBCLASS   0x06
 #define COMMUNICATIONS_ANCM_SUBCLASS   0x07
 
 /* c.f. WMCD 5.1 */
 #define COMMUNICATIONS_WHCM_SUBCLASS   0x08
-#define COMMUNICATIONS_DMM_SUBCLASS    0x09
+#define COMMUNICATIONS_DMM_SUBCLASS            0x09
 #define COMMUNICATIONS_MDLM_SUBCLASS   0x0a
 #define COMMUNICATIONS_OBEX_SUBCLASS   0x0b
 
-/* c.f. CDC 4.6 Table 18 */
+/* c.f. CDC 4.4 Table 17 */
+#define COMMUNICATIONS_NO_PROTOCOL             0x00
+#define COMMUNICATIONS_V25TER_PROTOCOL 0x01    /*Common AT Hayes compatible*/
+
+/* c.f. CDC 4.5 Table 18 */
 #define DATA_INTERFACE_CLASS           0x0a
 
+/* c.f. CDC 4.6 No Table */
+#define DATA_INTERFACE_SUBCLASS_NONE   0x00    /* No subclass pertinent */
+
 /* c.f. CDC 4.7 Table 19 */
-#define COMMUNICATIONS_NO_PROTOCOL     0x00
+#define DATA_INTERFACE_PROTOCOL_NONE   0x00    /* No class protcol required */
 
 
 /* c.f. CDC 5.2.3 Table 24 */
-#define CS_INTERFACE                   0x24
+#define CS_INTERFACE           0x24
 #define CS_ENDPOINT                    0x25
 
 /*
  * c.f. WMCD 5.3 Table 5.3
  */
 
-#define USB_ST_HEADER                  0x00
+#define USB_ST_HEADER          0x00
 #define USB_ST_CMF                     0x01
 #define USB_ST_ACMF                    0x02
 #define USB_ST_DLMF                    0x03
 #define USB_ST_UF                      0x06
 #define USB_ST_CSF                     0x07
 #define USB_ST_TOMF                    0x08
-#define USB_ST_USBTF                   0x09
+#define USB_ST_USBTF           0x09
 #define USB_ST_NCT                     0x0a
 #define USB_ST_PUF                     0x0b
 #define USB_ST_EUF                     0x0c
 #define USB_ST_MCMF                    0x0d
 #define USB_ST_CCMF                    0x0e
 #define USB_ST_ENF                     0x0f
-#define USB_ST_ATMNF                   0x10
+#define USB_ST_ATMNF           0x10
 
 #define USB_ST_WHCM                    0x11
 #define USB_ST_MDLM                    0x12
-#define USB_ST_MDLMD                   0x13
+#define USB_ST_MDLMD           0x13
 #define USB_ST_DMM                     0x14
 #define USB_ST_OBEX                    0x15
 #define USB_ST_CS                      0x16
@@ -312,7 +321,8 @@ struct usb_class_union_function_descriptor {
        u8 bDescriptorType;
        u8 bDescriptorSubtype;  /* 0x06 */
        u8 bMasterInterface;
-       u8 bSlaveInterface0[0];
+       //u8 bSlaveInterface0[0];
+       u8 bSlaveInterface0;
 } __attribute__ ((packed));
 
 struct usb_class_country_selection_descriptor {