History

usb: gadget: f_fs: Add support for SuperSpeed Mode

Allow userspace to pass SuperSpeed descriptors and handle them in the driver accordingly. This change doesn't modify existing desc_header and thereby keeps the ABI changes backward compatible i.e. existing userspace drivers compiled with old header (functionfs.h) would continue to work with the updated kernel.

Manu Gautam committed 12 years ago

Commit 8d4e8971 parent d8eb6c63 files · +147 −50Browse files

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

Unified · Split

include/uapi/linux/usb/functionfs.h+5−0
@@ -13,6 +13,7 @@ enum { · 12 unmodified lines
1313 FUNCTIONFS_STRINGS_MAGIC = 2
1414 };
1515
16+#define FUNCTIONFS_SS_DESC_MAGIC 0x0055DE5C
1617
1718 #ifndef __KERNEL__
1819
@@ -50,7 +51,11 @@ struct usb_functionfs_descs_head { · 31 unmodified lines
5051 * | 12 | hs_count | LE32 | number of high-speed descriptors |
5152 * | 16 | fs_descrs | Descriptor[] | list of full-speed descriptors |
5253 * | | hs_descrs | Descriptor[] | list of high-speed descriptors |
54+ * | | ss_magic | LE32 | FUNCTIONFS_SS_DESC_MAGIC |
55+ * | | ss_count | LE32 | number of super-speed descriptors |
56+ * | | ss_descrs | Descriptor[] | list of super-speed descriptors |
5357 *
58+ * ss_magic: if present then it implies that SS_DESCs are also present
5459 * descs are just valid USB descriptors and have the following format:
5560 *
5661 * | off | name | type | description |