Re: [PATCH] USB: gadget: Add ID numbers to gadget names

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, May 11, 2022 at 05:17:48PM +0200, Greg KH wrote:
> On Tue, May 10, 2022 at 11:51:29AM -0400, Alan Stern wrote:
> > Putting USB gadgets on a new bus of their own encounters a problem
> > when multiple gadgets are present: They all have the same name!  The
> > driver core fails with a "sys: cannot create duplicate filename" error
> > when creating any of the /sys/bus/gadget/devices/<gadget-name>
> > symbolic links after the first.
> > 
> > This patch fixes the problem by adding a ".N" suffix to each gadget's
> > name when the gadget is registered (where N is a unique ID number),
> > thus making the names distinct.
> > 
> > Reported-and-tested-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
> > Signed-off-by: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>
> > Reviewed-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
> > Fixes: fc274c1e9973 ("USB: gadget: Add a new bus for gadgets")
> > 
> > ---
> > 
> > 
> > [as1980]
> 
> Thanks, let me run this through the Android test suite first.  You can
> see the results here:
> 	https://android-review.googlesource.com/c/kernel/common/+/2095109
> 
> I'll let you know how it goes as I do not know if you are not logged in
> if you can see the test results or not, gerrit is odd...

All passed, so I'll go queue this up now, thanks!

greg k-h



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux