[PATCH 3/3] usb: gadget: f_sourcesink: Addition of SSP endpoint companion for Isochronous transfers

Srikanth Chary Chennoju posted 3 patches 3 months ago
There is a newer version of this series
[PATCH 3/3] usb: gadget: f_sourcesink: Addition of SSP endpoint companion for Isochronous transfers
Posted by Srikanth Chary Chennoju 3 months ago
This patch is created to support super speed plus endpoint for
Isochronous transfers. Now super speed endpoint companion is
accompanied by super speed plus endpoint companion.
With this change we could see the Isoc IN and OUT performance
reaching to ~749MB/sec which is 96K per uframe.
The performance numbers are confirmed through Lecroy trace.

Signed-off-by: Srikanth Chary Chennoju <srikanth.chary-chennoju@amd.com>
---
 drivers/usb/gadget/function/f_sourcesink.c | 23 ++++++++++++++++++++--
 1 file changed, 21 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/gadget/function/f_sourcesink.c b/drivers/usb/gadget/function/f_sourcesink.c
index 84f3b3bc7669..6499e95e0e9c 100644
--- a/drivers/usb/gadget/function/f_sourcesink.c
+++ b/drivers/usb/gadget/function/f_sourcesink.c
@@ -232,6 +232,12 @@ static struct usb_ss_ep_comp_descriptor ss_iso_source_comp_desc = {
 	.wBytesPerInterval =	cpu_to_le16(1024),
 };
 
+static struct usb_ssp_isoc_ep_comp_descriptor ssp_iso_source_comp_desc = {
+	.bLength =		USB_DT_SSP_ISOC_EP_COMP_SIZE,
+	.bDescriptorType =	USB_DT_SSP_ISOC_ENDPOINT_COMP,
+	.dwBytesPerInterval =	cpu_to_le32(1024),
+};
+
 static struct usb_endpoint_descriptor ss_iso_sink_desc = {
 	.bLength =		USB_DT_ENDPOINT_SIZE,
 	.bDescriptorType =	USB_DT_ENDPOINT,
@@ -250,6 +256,12 @@ static struct usb_ss_ep_comp_descriptor ss_iso_sink_comp_desc = {
 	.wBytesPerInterval =	cpu_to_le16(1024),
 };
 
+static struct usb_ssp_isoc_ep_comp_descriptor ssp_iso_sink_comp_desc = {
+	.bLength =		USB_DT_SSP_ISOC_EP_COMP_SIZE,
+	.bDescriptorType =	USB_DT_SSP_ISOC_ENDPOINT_COMP,
+	.dwBytesPerInterval =	cpu_to_le32(1024),
+};
+
 static struct usb_descriptor_header *ss_source_sink_descs[] = {
 	(struct usb_descriptor_header *) &source_sink_intf_alt0,
 	(struct usb_descriptor_header *) &ss_source_desc,
@@ -264,8 +276,10 @@ static struct usb_descriptor_header *ss_source_sink_descs[] = {
 	(struct usb_descriptor_header *) &ss_sink_comp_desc,
 	(struct usb_descriptor_header *) &ss_iso_source_desc,
 	(struct usb_descriptor_header *) &ss_iso_source_comp_desc,
+	(struct usb_descriptor_header *)&ssp_iso_source_comp_desc,
 	(struct usb_descriptor_header *) &ss_iso_sink_desc,
 	(struct usb_descriptor_header *) &ss_iso_sink_comp_desc,
+	(struct usb_descriptor_header *)&ssp_iso_sink_comp_desc,
 	NULL,
 };
 
@@ -428,7 +442,7 @@ sourcesink_bind(struct usb_configuration *c, struct usb_function *f)
 	 */
 	ss_iso_source_desc.wMaxPacketSize = ss->isoc_maxpacket;
 	ss_iso_source_desc.bInterval = ss->isoc_interval;
-	ss_iso_source_comp_desc.bmAttributes = ss->isoc_mult;
+	ss_iso_source_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;
 	ss_iso_source_comp_desc.bMaxBurst = ss->isoc_maxburst;
 	ss_iso_source_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
 		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
@@ -437,12 +451,17 @@ sourcesink_bind(struct usb_configuration *c, struct usb_function *f)
 
 	ss_iso_sink_desc.wMaxPacketSize = ss->isoc_maxpacket;
 	ss_iso_sink_desc.bInterval = ss->isoc_interval;
-	ss_iso_sink_comp_desc.bmAttributes = ss->isoc_mult;
+	ss_iso_sink_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;
 	ss_iso_sink_comp_desc.bMaxBurst = ss->isoc_maxburst;
 	ss_iso_sink_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
 		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
 	ss_iso_sink_desc.bEndpointAddress = fs_iso_sink_desc.bEndpointAddress;
 
+	ssp_iso_source_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
+		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;
+	ssp_iso_sink_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
+		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;
+
 	ret = usb_assign_descriptors(f, fs_source_sink_descs,
 			hs_source_sink_descs, ss_source_sink_descs,
 			ss_source_sink_descs);
-- 
2.25.1
Re: [PATCH 3/3] usb: gadget: f_sourcesink: Addition of SSP endpoint companion for Isochronous transfers
Posted by kernel test robot 3 months ago
Hi Srikanth,

kernel test robot noticed the following build warnings:

[auto build test WARNING on usb/usb-testing]
[also build test WARNING on usb/usb-next usb/usb-linus linus/master v6.16-rc4 next-20250704]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Srikanth-Chary-Chennoju/usb-gadget-zero-support-for-super-speed-plus/20250704-194150
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing
patch link:    https://lore.kernel.org/r/20250704114013.3396795-4-srikanth.chary-chennoju%40amd.com
patch subject: [PATCH 3/3] usb: gadget: f_sourcesink: Addition of SSP endpoint companion for Isochronous transfers
config: i386-randconfig-063-20250705 (https://download.01.org/0day-ci/archive/20250705/202507051018.998T0Yqk-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14+deb12u1) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250705/202507051018.998T0Yqk-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202507051018.998T0Yqk-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
   drivers/usb/gadget/function/f_sourcesink.c:382:43: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:382:43: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:382:43: sparse:     got unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:385:41: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:385:41: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:385:41: sparse:     got unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:421:43: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int isoc_maxpacket @@
   drivers/usb/gadget/function/f_sourcesink.c:421:43: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:421:43: sparse:     got unsigned int isoc_maxpacket
   drivers/usb/gadget/function/f_sourcesink.c:422:43: sparse: sparse: invalid assignment: |=
   drivers/usb/gadget/function/f_sourcesink.c:422:43: sparse:    left side has type restricted __le16
   drivers/usb/gadget/function/f_sourcesink.c:422:43: sparse:    right side has type unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:427:41: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int isoc_maxpacket @@
   drivers/usb/gadget/function/f_sourcesink.c:427:41: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:427:41: sparse:     got unsigned int isoc_maxpacket
   drivers/usb/gadget/function/f_sourcesink.c:428:41: sparse: sparse: invalid assignment: |=
   drivers/usb/gadget/function/f_sourcesink.c:428:41: sparse:    left side has type restricted __le16
   drivers/usb/gadget/function/f_sourcesink.c:428:41: sparse:    right side has type unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:443:43: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int isoc_maxpacket @@
   drivers/usb/gadget/function/f_sourcesink.c:443:43: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:443:43: sparse:     got unsigned int isoc_maxpacket
   drivers/usb/gadget/function/f_sourcesink.c:447:51: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [assigned] [toplevel] [usertype] wBytesPerInterval @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:447:51: sparse:     expected restricted __le16 static [addressable] [assigned] [toplevel] [usertype] wBytesPerInterval
   drivers/usb/gadget/function/f_sourcesink.c:447:51: sparse:     got unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:452:41: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize @@     got unsigned int isoc_maxpacket @@
   drivers/usb/gadget/function/f_sourcesink.c:452:41: sparse:     expected restricted __le16 static [addressable] [toplevel] [usertype] wMaxPacketSize
   drivers/usb/gadget/function/f_sourcesink.c:452:41: sparse:     got unsigned int isoc_maxpacket
   drivers/usb/gadget/function/f_sourcesink.c:456:49: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 static [addressable] [assigned] [toplevel] [usertype] wBytesPerInterval @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:456:49: sparse:     expected restricted __le16 static [addressable] [assigned] [toplevel] [usertype] wBytesPerInterval
   drivers/usb/gadget/function/f_sourcesink.c:456:49: sparse:     got unsigned int
>> drivers/usb/gadget/function/f_sourcesink.c:460:53: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 static [addressable] [toplevel] [usertype] dwBytesPerInterval @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:460:53: sparse:     expected restricted __le32 static [addressable] [toplevel] [usertype] dwBytesPerInterval
   drivers/usb/gadget/function/f_sourcesink.c:460:53: sparse:     got unsigned int
   drivers/usb/gadget/function/f_sourcesink.c:462:51: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 static [addressable] [toplevel] [usertype] dwBytesPerInterval @@     got unsigned int @@
   drivers/usb/gadget/function/f_sourcesink.c:462:51: sparse:     expected restricted __le32 static [addressable] [toplevel] [usertype] dwBytesPerInterval
   drivers/usb/gadget/function/f_sourcesink.c:462:51: sparse:     got unsigned int

vim +460 drivers/usb/gadget/function/f_sourcesink.c

   330	
   331	static int
   332	sourcesink_bind(struct usb_configuration *c, struct usb_function *f)
   333	{
   334		struct usb_composite_dev *cdev = c->cdev;
   335		struct f_sourcesink	*ss = func_to_ss(f);
   336		int	id;
   337		int ret;
   338	
   339		/* allocate interface ID(s) */
   340		id = usb_interface_id(c, f);
   341		if (id < 0)
   342			return id;
   343		source_sink_intf_alt0.bInterfaceNumber = id;
   344		source_sink_intf_alt1.bInterfaceNumber = id;
   345	
   346		/* sanity check the bulk module parameters */
   347		if (ss->bulk_maxburst > 15)
   348			ss->bulk_maxburst = 15;
   349	
   350		/* allocate bulk endpoints */
   351		ss->in_ep = usb_ep_autoconfig(cdev->gadget, &fs_source_desc);
   352		if (!ss->in_ep) {
   353	autoconf_fail:
   354			ERROR(cdev, "%s: can't autoconfigure on %s\n",
   355				f->name, cdev->gadget->name);
   356			return -ENODEV;
   357		}
   358	
   359		ss->out_ep = usb_ep_autoconfig(cdev->gadget, &fs_sink_desc);
   360		if (!ss->out_ep)
   361			goto autoconf_fail;
   362	
   363		/*
   364		 * Fill in the SS bulk descriptors from the module parameters.
   365		 * We assume that the user knows what they are doing and won't
   366		 * give parameters that their UDC doesn't support.
   367		 */
   368		ss_source_comp_desc.bMaxBurst = ss->bulk_maxburst;
   369		ss_sink_comp_desc.bMaxBurst = ss->bulk_maxburst;
   370	
   371		/* sanity check the isoc module parameters */
   372		if (ss->isoc_interval < 1)
   373			ss->isoc_interval = 1;
   374		if (ss->isoc_interval > 16)
   375			ss->isoc_interval = 16;
   376		if (ss->isoc_mult > 2)
   377			ss->isoc_mult = 2;
   378		if (ss->isoc_maxburst > 15)
   379			ss->isoc_maxburst = 15;
   380	
   381		/* fill in the FS isoc descriptors from the module parameters */
   382		fs_iso_source_desc.wMaxPacketSize = ss->isoc_maxpacket > 1023 ?
   383							1023 : ss->isoc_maxpacket;
   384		fs_iso_source_desc.bInterval = ss->isoc_interval;
   385		fs_iso_sink_desc.wMaxPacketSize = ss->isoc_maxpacket > 1023 ?
   386							1023 : ss->isoc_maxpacket;
   387		fs_iso_sink_desc.bInterval = ss->isoc_interval;
   388	
   389		/* allocate iso endpoints */
   390		ss->iso_in_ep = usb_ep_autoconfig(cdev->gadget, &fs_iso_source_desc);
   391		if (!ss->iso_in_ep)
   392			goto no_iso;
   393	
   394		ss->iso_out_ep = usb_ep_autoconfig(cdev->gadget, &fs_iso_sink_desc);
   395		if (!ss->iso_out_ep) {
   396			usb_ep_autoconfig_release(ss->iso_in_ep);
   397			ss->iso_in_ep = NULL;
   398	no_iso:
   399			/*
   400			 * We still want to work even if the UDC doesn't have isoc
   401			 * endpoints, so null out the alt interface that contains
   402			 * them and continue.
   403			 */
   404			fs_source_sink_descs[FS_ALT_IFC_1_OFFSET] = NULL;
   405			hs_source_sink_descs[HS_ALT_IFC_1_OFFSET] = NULL;
   406			ss_source_sink_descs[SS_ALT_IFC_1_OFFSET] = NULL;
   407		}
   408	
   409		if (ss->isoc_maxpacket > 1024)
   410			ss->isoc_maxpacket = 1024;
   411	
   412		/* support high speed hardware */
   413		hs_source_desc.bEndpointAddress = fs_source_desc.bEndpointAddress;
   414		hs_sink_desc.bEndpointAddress = fs_sink_desc.bEndpointAddress;
   415	
   416		/*
   417		 * Fill in the HS isoc descriptors from the module parameters.
   418		 * We assume that the user knows what they are doing and won't
   419		 * give parameters that their UDC doesn't support.
   420		 */
   421		hs_iso_source_desc.wMaxPacketSize = ss->isoc_maxpacket;
   422		hs_iso_source_desc.wMaxPacketSize |= ss->isoc_mult << 11;
   423		hs_iso_source_desc.bInterval = ss->isoc_interval;
   424		hs_iso_source_desc.bEndpointAddress =
   425			fs_iso_source_desc.bEndpointAddress;
   426	
   427		hs_iso_sink_desc.wMaxPacketSize = ss->isoc_maxpacket;
   428		hs_iso_sink_desc.wMaxPacketSize |= ss->isoc_mult << 11;
   429		hs_iso_sink_desc.bInterval = ss->isoc_interval;
   430		hs_iso_sink_desc.bEndpointAddress = fs_iso_sink_desc.bEndpointAddress;
   431	
   432		/* support super speed hardware */
   433		ss_source_desc.bEndpointAddress =
   434			fs_source_desc.bEndpointAddress;
   435		ss_sink_desc.bEndpointAddress =
   436			fs_sink_desc.bEndpointAddress;
   437	
   438		/*
   439		 * Fill in the SS isoc descriptors from the module parameters.
   440		 * We assume that the user knows what they are doing and won't
   441		 * give parameters that their UDC doesn't support.
   442		 */
   443		ss_iso_source_desc.wMaxPacketSize = ss->isoc_maxpacket;
   444		ss_iso_source_desc.bInterval = ss->isoc_interval;
   445		ss_iso_source_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;
   446		ss_iso_source_comp_desc.bMaxBurst = ss->isoc_maxburst;
   447		ss_iso_source_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
   448			(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
   449		ss_iso_source_desc.bEndpointAddress =
   450			fs_iso_source_desc.bEndpointAddress;
   451	
   452		ss_iso_sink_desc.wMaxPacketSize = ss->isoc_maxpacket;
   453		ss_iso_sink_desc.bInterval = ss->isoc_interval;
   454		ss_iso_sink_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;
   455		ss_iso_sink_comp_desc.bMaxBurst = ss->isoc_maxburst;
   456		ss_iso_sink_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
   457			(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
   458		ss_iso_sink_desc.bEndpointAddress = fs_iso_sink_desc.bEndpointAddress;
   459	
 > 460		ssp_iso_source_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
   461			(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;
   462		ssp_iso_sink_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
   463			(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;
   464	
   465		ret = usb_assign_descriptors(f, fs_source_sink_descs,
   466				hs_source_sink_descs, ss_source_sink_descs,
   467				ss_source_sink_descs);
   468		if (ret)
   469			return ret;
   470	
   471		DBG(cdev, "%s: IN/%s, OUT/%s, ISO-IN/%s, ISO-OUT/%s\n",
   472				f->name, ss->in_ep->name, ss->out_ep->name,
   473				ss->iso_in_ep ? ss->iso_in_ep->name : "<none>",
   474				ss->iso_out_ep ? ss->iso_out_ep->name : "<none>");
   475		return 0;
   476	}
   477	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Re: [PATCH 3/3] usb: gadget: f_sourcesink: Addition of SSP endpoint companion for Isochronous transfers
Posted by Greg KH 3 months ago
On Fri, Jul 04, 2025 at 05:10:13PM +0530, Srikanth Chary Chennoju wrote:
> This patch is created to support super speed plus endpoint for
> Isochronous transfers. Now super speed endpoint companion is
> accompanied by super speed plus endpoint companion.
> With this change we could see the Isoc IN and OUT performance
> reaching to ~749MB/sec which is 96K per uframe.
> The performance numbers are confirmed through Lecroy trace.

You do have a full 72 characters wide, you can use it :)

> 
> Signed-off-by: Srikanth Chary Chennoju <srikanth.chary-chennoju@amd.com>
> ---
>  drivers/usb/gadget/function/f_sourcesink.c | 23 ++++++++++++++++++++--
>  1 file changed, 21 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/usb/gadget/function/f_sourcesink.c b/drivers/usb/gadget/function/f_sourcesink.c
> index 84f3b3bc7669..6499e95e0e9c 100644
> --- a/drivers/usb/gadget/function/f_sourcesink.c
> +++ b/drivers/usb/gadget/function/f_sourcesink.c
> @@ -232,6 +232,12 @@ static struct usb_ss_ep_comp_descriptor ss_iso_source_comp_desc = {
>  	.wBytesPerInterval =	cpu_to_le16(1024),
>  };
>  
> +static struct usb_ssp_isoc_ep_comp_descriptor ssp_iso_source_comp_desc = {
> +	.bLength =		USB_DT_SSP_ISOC_EP_COMP_SIZE,
> +	.bDescriptorType =	USB_DT_SSP_ISOC_ENDPOINT_COMP,
> +	.dwBytesPerInterval =	cpu_to_le32(1024),
> +};
> +
>  static struct usb_endpoint_descriptor ss_iso_sink_desc = {
>  	.bLength =		USB_DT_ENDPOINT_SIZE,
>  	.bDescriptorType =	USB_DT_ENDPOINT,
> @@ -250,6 +256,12 @@ static struct usb_ss_ep_comp_descriptor ss_iso_sink_comp_desc = {
>  	.wBytesPerInterval =	cpu_to_le16(1024),
>  };
>  
> +static struct usb_ssp_isoc_ep_comp_descriptor ssp_iso_sink_comp_desc = {
> +	.bLength =		USB_DT_SSP_ISOC_EP_COMP_SIZE,
> +	.bDescriptorType =	USB_DT_SSP_ISOC_ENDPOINT_COMP,
> +	.dwBytesPerInterval =	cpu_to_le32(1024),
> +};
> +
>  static struct usb_descriptor_header *ss_source_sink_descs[] = {
>  	(struct usb_descriptor_header *) &source_sink_intf_alt0,
>  	(struct usb_descriptor_header *) &ss_source_desc,
> @@ -264,8 +276,10 @@ static struct usb_descriptor_header *ss_source_sink_descs[] = {
>  	(struct usb_descriptor_header *) &ss_sink_comp_desc,
>  	(struct usb_descriptor_header *) &ss_iso_source_desc,
>  	(struct usb_descriptor_header *) &ss_iso_source_comp_desc,
> +	(struct usb_descriptor_header *)&ssp_iso_source_comp_desc,
>  	(struct usb_descriptor_header *) &ss_iso_sink_desc,
>  	(struct usb_descriptor_header *) &ss_iso_sink_comp_desc,
> +	(struct usb_descriptor_header *)&ssp_iso_sink_comp_desc,

Odd spacing :(

Please follow the format that was previously there.


>  	NULL,
>  };
>  
> @@ -428,7 +442,7 @@ sourcesink_bind(struct usb_configuration *c, struct usb_function *f)
>  	 */
>  	ss_iso_source_desc.wMaxPacketSize = ss->isoc_maxpacket;
>  	ss_iso_source_desc.bInterval = ss->isoc_interval;
> -	ss_iso_source_comp_desc.bmAttributes = ss->isoc_mult;
> +	ss_iso_source_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;

What is 0x80 for?  Is that a #define somewhere?

>  	ss_iso_source_comp_desc.bMaxBurst = ss->isoc_maxburst;
>  	ss_iso_source_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
>  		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
> @@ -437,12 +451,17 @@ sourcesink_bind(struct usb_configuration *c, struct usb_function *f)
>  
>  	ss_iso_sink_desc.wMaxPacketSize = ss->isoc_maxpacket;
>  	ss_iso_sink_desc.bInterval = ss->isoc_interval;
> -	ss_iso_sink_comp_desc.bmAttributes = ss->isoc_mult;
> +	ss_iso_sink_comp_desc.bmAttributes = 0x80 | ss->isoc_mult;

Same here.

>  	ss_iso_sink_comp_desc.bMaxBurst = ss->isoc_maxburst;
>  	ss_iso_sink_comp_desc.wBytesPerInterval = ss->isoc_maxpacket *
>  		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1);
>  	ss_iso_sink_desc.bEndpointAddress = fs_iso_sink_desc.bEndpointAddress;
>  
> +	ssp_iso_source_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
> +		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;
> +	ssp_iso_sink_comp_desc.dwBytesPerInterval = ss->isoc_maxpacket *
> +		(ss->isoc_mult + 1) * (ss->isoc_maxburst + 1) * 2;

Why * 2?

thanks,

greg k-h