Skip to content

Commit 22ad1e7

Browse files
Sarah Sharpgregkh
authored andcommitted
USB: Add parsing of SuperSpeed endpoint companion descriptor.
Allow the xHCI drivers (and any new USB 3.0 drivers) to parse the SuperSpeed endpoint companion descriptor to find the maximum number of bulk endpoint streams the endpoint supports. This is used to calculate the maximum total number of streams the driver can allocate. Signed-off-by: Sarah Sharp <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent e07896e commit 22ad1e7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

include/linux/usb/ch9.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -556,6 +556,8 @@ struct usb_ss_ep_comp_descriptor {
556556
} __attribute__ ((packed));
557557

558558
#define USB_DT_SS_EP_COMP_SIZE 6
559+
/* Bits 4:0 of bmAttributes if this is a bulk endpoint */
560+
#define USB_SS_MAX_STREAMS(p) (1 << (p & 0x1f))
559561

560562
/*-------------------------------------------------------------------------*/
561563

0 commit comments

Comments
 (0)