Linux USB
 help / color / mirror / Atom feed
* [PATCH v2] usb: gadget: Increase max configuration interface to 32
@ 2024-05-21  5:42 Akash Kumar
  2024-07-12 12:04 ` AKASH KUMAR
  2024-07-31  8:18 ` Greg Kroah-Hartman
  0 siblings, 2 replies; 4+ messages in thread
From: Akash Kumar @ 2024-05-21  5:42 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Jing Leng, Felipe Balbi, Pratham Pratap ,
	Jack Pham, kernel, Wesley Cheng, Vijayavardhan Vennapusa,
	Krishna Kurapati
  Cc: linux-usb, linux-kernel, Akash Kumar

Currently, max configuration interfaces are limited to 16, which fails
for compositions containing 10 UVC configurations with interrupt ep
disabled along with other configurations , and we see bind failures
while allocating interface ID in uvc bind.

Increase max configuration interface to 32 to support any large
compositions, limited to the same size as USB device endpoints, as
interfaces cannot be more than endpoints.

Signed-off-by: Akash Kumar <quic_akakum@quicinc.com>
---
 include/linux/usb/composite.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h
index 2040696d75b6..d6d4fbfb6d0e 100644
--- a/include/linux/usb/composite.h
+++ b/include/linux/usb/composite.h
@@ -255,7 +255,7 @@ int config_ep_by_speed_and_alt(struct usb_gadget *g, struct usb_function *f,
 int config_ep_by_speed(struct usb_gadget *g, struct usb_function *f,
 			struct usb_ep *_ep);
 
-#define	MAX_CONFIG_INTERFACES		16	/* arbitrary; max 255 */
+#define	MAX_CONFIG_INTERFACES		32
 
 /**
  * struct usb_configuration - represents one gadget configuration
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] usb: gadget: Increase max configuration interface to 32
  2024-05-21  5:42 [PATCH v2] usb: gadget: Increase max configuration interface to 32 Akash Kumar
@ 2024-07-12 12:04 ` AKASH KUMAR
  2024-07-31  8:18 ` Greg Kroah-Hartman
  1 sibling, 0 replies; 4+ messages in thread
From: AKASH KUMAR @ 2024-07-12 12:04 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Jing Leng, Felipe Balbi, Pratham Pratap,
	Jack Pham, kernel, Wesley Cheng, Vijayavardhan Vennapusa,
	Krishna Kurapati
  Cc: linux-usb, linux-kernel

Gentle Reminder!!!

On 5/21/2024 11:12 AM, Akash Kumar wrote:
> Currently, max configuration interfaces are limited to 16, which fails
> for compositions containing 10 UVC configurations with interrupt ep
> disabled along with other configurations , and we see bind failures
> while allocating interface ID in uvc bind.
>
> Increase max configuration interface to 32 to support any large
> compositions, limited to the same size as USB device endpoints, as
> interfaces cannot be more than endpoints.
>
> Signed-off-by: Akash Kumar <quic_akakum@quicinc.com>
> ---
>   include/linux/usb/composite.h | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h
> index 2040696d75b6..d6d4fbfb6d0e 100644
> --- a/include/linux/usb/composite.h
> +++ b/include/linux/usb/composite.h
> @@ -255,7 +255,7 @@ int config_ep_by_speed_and_alt(struct usb_gadget *g, struct usb_function *f,
>   int config_ep_by_speed(struct usb_gadget *g, struct usb_function *f,
>   			struct usb_ep *_ep);
>   
> -#define	MAX_CONFIG_INTERFACES		16	/* arbitrary; max 255 */
> +#define	MAX_CONFIG_INTERFACES		32
>   
>   /**
>    * struct usb_configuration - represents one gadget configuration

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] usb: gadget: Increase max configuration interface to 32
  2024-05-21  5:42 [PATCH v2] usb: gadget: Increase max configuration interface to 32 Akash Kumar
  2024-07-12 12:04 ` AKASH KUMAR
@ 2024-07-31  8:18 ` Greg Kroah-Hartman
  1 sibling, 0 replies; 4+ messages in thread
From: Greg Kroah-Hartman @ 2024-07-31  8:18 UTC (permalink / raw)
  To: Akash Kumar
  Cc: Jing Leng, Felipe Balbi, Pratham Pratap , Jack Pham, kernel,
	Wesley Cheng, Vijayavardhan Vennapusa, Krishna Kurapati,
	linux-usb, linux-kernel

On Tue, May 21, 2024 at 11:12:57AM +0530, Akash Kumar wrote:
> Currently, max configuration interfaces are limited to 16, which fails
> for compositions containing 10 UVC configurations with interrupt ep
> disabled along with other configurations , and we see bind failures
> while allocating interface ID in uvc bind.
> 
> Increase max configuration interface to 32 to support any large
> compositions, limited to the same size as USB device endpoints, as
> interfaces cannot be more than endpoints.
> 
> Signed-off-by: Akash Kumar <quic_akakum@quicinc.com>
> ---
>  include/linux/usb/composite.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h
> index 2040696d75b6..d6d4fbfb6d0e 100644
> --- a/include/linux/usb/composite.h
> +++ b/include/linux/usb/composite.h
> @@ -255,7 +255,7 @@ int config_ep_by_speed_and_alt(struct usb_gadget *g, struct usb_function *f,
>  int config_ep_by_speed(struct usb_gadget *g, struct usb_function *f,
>  			struct usb_ep *_ep);
>  
> -#define	MAX_CONFIG_INTERFACES		16	/* arbitrary; max 255 */
> +#define	MAX_CONFIG_INTERFACES		32
>  
>  /**
>   * struct usb_configuration - represents one gadget configuration
> -- 
> 2.17.1
> 
> 

Hi,

This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
a patch that has triggered this response.  He used to manually respond
to these common problems, but in order to save his sanity (he kept
writing the same thing over and over, yet to different people), I was
created.  Hopefully you will not take offence and will fix the problem
in your patch and resubmit it so that it can be accepted into the Linux
kernel tree.

You are receiving this message because of the following common error(s)
as indicated below:

- This looks like a new version of a previously submitted patch, but you
  did not list below the --- line any changes from the previous version.
  Please read the section entitled "The canonical patch format" in the
  kernel file, Documentation/process/submitting-patches.rst for what
  needs to be done here to properly describe this.

If you wish to discuss this problem further, or you have questions about
how to resolve this issue, please feel free to respond to this email and
Greg will reply once he has dug out from the pending patches received
from other developers.

thanks,

greg k-h's patch email bot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v2] usb: gadget: Increase max configuration interface to 32
@ 2024-08-01  5:30 Akash Kumar
  0 siblings, 0 replies; 4+ messages in thread
From: Akash Kumar @ 2024-08-01  5:30 UTC (permalink / raw)
  To: Thinh Nguyen, Greg Kroah-Hartman, Jing Leng, Felipe Balbi,
	Jack Pham, kernel, Wesley Cheng, Laurent Pinchart, Daniel Scally
  Cc: Vijayavardhan Vennapusa, Krishna Kurapati, linux-usb,
	linux-kernel, Akash Kumar

Currently, max configuration interfaces are limited to 16, which fails
for compositions containing 10 UVC configurations with interrupt ep
disabled along with other configurations , and we see bind failures
while allocating interface ID in uvc bind.

Increase max configuration interface to 32 to support any large
compositions limited to same size as usb device endpoints as
interfaces cannot be more than endpoints.

Signed-off-by: Akash Kumar <quic_akakum@quicinc.com>
---
 include/linux/usb/composite.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Changes for v2:
Removed comment '/* arbitrary; max 255 */' as per review as it was
confusing as MAX_CONFIG_INTERFACES cannot go beyond 32 due to usb
ep limitation.

diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h
index 2040696d75b6..d6d4fbfb6d0e 100644
--- a/include/linux/usb/composite.h
+++ b/include/linux/usb/composite.h
@@ -255,7 +255,7 @@ int config_ep_by_speed_and_alt(struct usb_gadget *g, struct usb_function *f,
 int config_ep_by_speed(struct usb_gadget *g, struct usb_function *f,
 			struct usb_ep *_ep);
 
-#define	MAX_CONFIG_INTERFACES		16	/* arbitrary; max 255 */
+#define	MAX_CONFIG_INTERFACES		32
 
 /**
  * struct usb_configuration - represents one gadget configuration
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-08-01  5:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-21  5:42 [PATCH v2] usb: gadget: Increase max configuration interface to 32 Akash Kumar
2024-07-12 12:04 ` AKASH KUMAR
2024-07-31  8:18 ` Greg Kroah-Hartman
  -- strict thread matches above, loose matches on Subject: below --
2024-08-01  5:30 Akash Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox