usb: gadget: f_fs: add usb_functionfs_descs_head_v2
PATCH 1/1 usb: gadget: f_fs: add usb_functionfs_descs_head_v2
Add usb_functionfs_descs_head_v2 structure for the new layout of descriptors.
Signed-off-by Zhuang Jin Can <[email protected]>
--- include/uapi/linux/usb/functionfs.h | 9 +++++++++ 1 file changed, 9 insertions(+)
include/uapi/linux/usb/functionfs.h +9 -0
@@ -32,6 +32,15 @@ struct usb_endpoint_descriptor_no_audio {__u8 bInterval; } __attribute__((packed)); +struct usb_functionfs_descs_head_v2 { +__le32 magic; +__le32 length; +__le32 flags; +__le32 fs_count; +__le32 hs_count; +__le32 ss_count; +} __attribute__((packed)); +/* Legacy format, deprecated as of 3.14. */ struct usb_functionfs_descs_head {__le32 magic;
Signature · 1 line
1.7.9.5
Quoted 2 lines · Zhuang Jin Can
Add
usb_functionfs_descs_head_v2structure for the new layout of descriptors.
NAK. It's a duplicate of <https://lkml.org/lkml/2014/6/6/128> and even more importantly, the format of the header is not fixed past the flags field (e.g. fs_count may be missing), so fs_count, hs_count and ss_count cannot be in the structure.
Quoted 25 lines
Signed-off-by Zhuang Jin Can <[email protected]>--- include/uapi/linux/usb/functionfs.h | 9 +++++++++ 1 file changed, 9 insertions(+)include/uapi/linux/usb/functionfs.h +9
-0@@ -32,6 +32,15 @@ struct usb_endpoint_descriptor_no_audio {__u8 bInterval; } __attribute__((packed)); +struct usb_functionfs_descs_head_v2 { +__le32 magic; +__le32 length; +__le32 flags; +__le32 fs_count; +__le32 hs_count; +__le32 ss_count; +} __attribute__((packed)); +/* Legacy format, deprecated as of 3.14. */ struct usb_functionfs_descs_head {__le32 magic;
Signature · 4 lines
Best regards, _ _ .o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o ..o | Computer Science, Michał “mina86” Nazarewicz (o o) ooo +--<[email protected]>--<xmpp:[email protected]>--ooO--(_)--Ooo--