Hi again,

W dniu 17.04.2018 o 09:55, Andrzej Pietrasiewicz pisze:
> Hi,
> 
> W dniu 17.04.2018 o 03:17, Jerry Zhang pisze:
>> Control_config is a group under gadget that acts
> 
> <snip>
> 
>>    
>> @@ -1461,6 +1499,18 @@ static struct config_group *gadgets_make(
>>      if (!gi->composite.gadget_driver.function)
>>              goto err;
>>    
>> +    gi->control_config.c.label = "control_config";
>> +    /* composite requires some value, but it doesn't matter */
>> +    gi->control_config.c.bConfigurationValue = 42;
> 
> If I understand correctly this is never exposed to the host, is it?
> 
>> +    INIT_LIST_HEAD(&gi->control_config.func_list);
>> +    config_group_init_type_name(&gi->control_config.group,
>> +                    "control_config", &gadget_config_type);
>> +    configfs_add_default_group(&gi->control_config.group, &gi->group);
> 
> Since it is a config I'd rather this be put inside the "configs" group.
> Configs created by the user must be named following the
> <config name>.<bConfigurationValue> pattern, so there will be no conflict
> with any other conf. The name can be "control" then.
> 

Answering my own doubts: this could be ok from the kernel point of view,
but existing userspace (libusbgx) already assumes that in the configs directory
there are only entries of the form <config>.<number> and anything other than 
that
will cause it to report error.

Andrzej
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to