Messages in this thread |  | | From | Frank Li <> | Subject | RE: [EXT] Re: [PATCH v2] USB: gadget: Add ID numbers to configfs-gadget driver names | Date | Sun, 25 Dec 2022 03:07:12 +0000 |
| |
> > I'm wondering if it maybe makes more sense to use the gadget name as a > suffix > instead? > > gi->composite.gadget_driver.driver.name = > kasprintf(GFP_KERNEL, "configfs-gadget.%s" name); > > So that when you > > mkdir g1 > > you will ultimately see /sys/bus/gadget/drivers/configfs-gadget.g1 > > instead of /sys/bus/gadget/drivers/configfs-gadget.0 > > Gadget names are guaranteed to be unique because they are created > as sibling subdirectories in configfs. Your patch would then be greatly > simplified (no need for ida).
I vote this ways.
Best regards Frank Li
> > Regards, > > Andrzej >
|  |