On Mon, May 05 2014, Andrzej Pietrasiewicz wrote: > When a gadget is composed with configfs the usb_add_config() is invoked > each time a configuration's directory is created, so this way configurations' > indices are determined. If we were to rearrange the configurations if > one of them becomes "special" then we loose the information about the original > sequence of configurations (i.e. which was index 0, index 1 etc). If the user > then decides that they don't want to use "OS descriptors" (=> no "special" > configuration) than we end up with configurations presented to the host in > different order than they were created. What I'm worried about is situation where configuration number visible on the device disagrees with what host sees. This may cause confusion or bugs at configfs level as well as in the code. I.e. the bConfigurationValue for the special configuration will be zero when accessed by the host, but might be non-zero when read via configfs or directly by the composite function driver. But perhaps this is all right since this will be used for hosts with a broken operating system anyway? I dunno. And also, renaming the configfs entries each time OS descriptors are toggled may be non-ideal as well. I'm not convinced either way, so I guess I'll leave it to your judgement. -- Best regards, _ _ .o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o ..o | Computer Science, Michał “mina86” Nazarewicz (o o) ooo +--<mpn@xxxxxxxxxx>--<xmpp:mina86@xxxxxxxxxx>--ooO--(_)--Ooo-- -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html