History

Merge tag 'usb-3.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb

Pull USB updates from Greg KH: "Here is the big USB driver update for 3.17-rc1. Loads of gadget driver changes in here, including some big file movements to make things easier to manage over time. There's also the usual xhci and uas driver updates, and a handful of other changes in here. The changelog has the full details. All of these have been in linux-next for a while" * tag 'usb-3.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (211 commits) USB: devio: fix issue with log flooding uas: Log a warning when we cannot use uas because the hcd lacks streams uas: Only complain about missing sg if all other checks succeed xhci: Add missing checks for xhci_alloc_command failure xhci: Rename Asrock P67 pci product-id to EJ168 xhci: Blacklist using streams on the Etron EJ168 controller uas: Limit qdepth to 32 when connected over usb-2 uwb/whci: use correct structure type name in sizeof usb-core bInterval quirk USB: serial: ftdi_sio: Add support for new Xsens devices USB: serial: ftdi_sio: Annotate the current Xsens PID assignments usb: chipidea: debug: fix sparse non static symbol warnings usb: ci_hdrc_imx doc: fsl,usbphy is required usb: ci_hdrc_imx: Return -EINVAL for missing USB PHY usb: core: allow zero packet flag for interrupt urbs usb: lvstest: Fix sparse warnings generated by kbuild test bot USB: core: hcd-pci: free IRQ before disabling PCI device when shutting down phy: miphy365x: Represent each PHY channel as a DT subnode phy: miphy365x: Provide support for the MiPHY356x Generic PHY phy: miphy365x: Add Device Tree bindings for the MiPHY365x ...

Linus Torvalds committed 12 years ago

Commit ae9b4752 parents 79eb238 d310d05267 files · +11203 −5803Browse files

Showing the changes to include/uapi (1 of 267 files). Show all

Unified · Split

include/uapi/linux/usb/functionfs.h+80−2
@@ -18,10 +18,9 @@ enum functionfs_flags { · 17 unmodified lines
1818 FUNCTIONFS_HAS_FS_DESC = 1,
1919 FUNCTIONFS_HAS_HS_DESC = 2,
2020 FUNCTIONFS_HAS_SS_DESC = 4,
21+ FUNCTIONFS_HAS_MS_OS_DESC = 8,
2122 };
2223
23−#ifndef __KERNEL__
24−
2524 /* Descriptor of an non-audio endpoint */
2625 struct usb_endpoint_descriptor_no_audio {
2726 __u8 bLength;
@@ -41,6 +40,37 @@ struct usb_functionfs_descs_head { · 13 unmodified lines
4140 __le32 hs_count;
4241 } __attribute__((packed, deprecated));
4342
43+/* MS OS Descriptor header */
44+struct usb_os_desc_header {
45+ __u8 interface;
46+ __le32 dwLength;
47+ __le16 bcdVersion;
48+ __le16 wIndex;
49+ union {
50+ struct {
51+ __u8 bCount;
52+ __u8 Reserved;
53+ };
54+ __le16 wCount;
55+ };
56+} __attribute__((packed));
57+
58+struct usb_ext_compat_desc {
59+ __u8 bFirstInterfaceNumber;
60+ __u8 Reserved1;
61+ __u8 CompatibleID[8];
62+ __u8 SubCompatibleID[8];
63+ __u8 Reserved2[6];
64+};
65+
66+struct usb_ext_prop_desc {
67+ __le32 dwSize;
68+ __le32 dwPropertyDataType;
69+ __le16 wPropertyNameLength;
70+} __attribute__((packed));
71+
72+#ifndef __KERNEL__
73+
4474 /*
4575 * Descriptors format:
4676 *
@@ -52,9 +82,11 @@ struct usb_functionfs_descs_head { · 5 unmodified lines
5282 * | | fs_count | LE32 | number of full-speed descriptors |
5383 * | | hs_count | LE32 | number of high-speed descriptors |
5484 * | | ss_count | LE32 | number of super-speed descriptors |
85+ * | | os_count | LE32 | number of MS OS descriptors |
5586 * | | fs_descrs | Descriptor[] | list of full-speed descriptors |
5687 * | | hs_descrs | Descriptor[] | list of high-speed descriptors |
5788 * | | ss_descrs | Descriptor[] | list of super-speed descriptors |
89+ * | | os_descrs | OSDesc[] | list of MS OS descriptors |
5890 *
5991 * Depending on which flags are set, various fields may be missing in the
6092 * structure. Any flags that are not recognised cause the whole block to be
@@ -81,6 +113,52 @@ struct usb_functionfs_descs_head { · 20 unmodified lines
81113 * | 0 | bLength | U8 | length of the descriptor |
82114 * | 1 | bDescriptorType | U8 | descriptor type |
83115 * | 2 | payload | | descriptor's payload |
116+ *
117+ * OSDesc[] is an array of valid MS OS Feature Descriptors which have one of
118+ * the following formats:
119+ *
120+ * | off | name | type | description |
121+ * |-----+-----------------+------+--------------------------|
122+ * | 0 | inteface | U8 | related interface number |
123+ * | 1 | dwLength | U32 | length of the descriptor |
124+ * | 5 | bcdVersion | U16 | currently supported: 1 |
125+ * | 7 | wIndex | U16 | currently supported: 4 |
126+ * | 9 | bCount | U8 | number of ext. compat. |
127+ * | 10 | Reserved | U8 | 0 |
128+ * | 11 | ExtCompat[] | | list of ext. compat. d. |
129+ *
130+ * | off | name | type | description |
131+ * |-----+-----------------+------+--------------------------|
132+ * | 0 | inteface | U8 | related interface number |
133+ * | 1 | dwLength | U32 | length of the descriptor |
134+ * | 5 | bcdVersion | U16 | currently supported: 1 |
135+ * | 7 | wIndex | U16 | currently supported: 5 |
136+ * | 9 | wCount | U16 | number of ext. compat. |
137+ * | 11 | ExtProp[] | | list of ext. prop. d. |
138+ *
139+ * ExtCompat[] is an array of valid Extended Compatiblity descriptors
140+ * which have the following format:
141+ *
142+ * | off | name | type | description |
143+ * |-----+-----------------------+------+-------------------------------------|
144+ * | 0 | bFirstInterfaceNumber | U8 | index of the interface or of the 1st|
145+ * | | | | interface in an IAD group |
146+ * | 1 | Reserved | U8 | 0 |
147+ * | 2 | CompatibleID | U8[8]| compatible ID string |
148+ * | 10 | SubCompatibleID | U8[8]| subcompatible ID string |
149+ * | 18 | Reserved | U8[6]| 0 |
150+ *
151+ * ExtProp[] is an array of valid Extended Properties descriptors
152+ * which have the following format:
153+ *
154+ * | off | name | type | description |
155+ * |-----+-----------------------+------+-------------------------------------|
156+ * | 0 | dwSize | U32 | length of the descriptor |
157+ * | 4 | dwPropertyDataType | U32 | 1..7 |
158+ * | 8 | wPropertyNameLength | U16 | bPropertyName length (NL) |
159+ * | 10 | bPropertyName |U8[NL]| name of this property |
160+ * |10+NL| dwPropertyDataLength | U32 | bPropertyData length (DL) |
161+ * |14+NL| bProperty |U8[DL]| payload of this property |
84162 */
85163
86164 struct usb_functionfs_strings_head {