On Wed, 28 Jul 2004, Wolfgang Mües wrote:

> Hello,
> 
> On Wednesday 28 July 2004 07:14, David Brownell wrote:
> 
> > Indirecting through schedule_work() should always be safe,
> > and that's what I'd recommend for now.
> 
> What is the recommended way of using a device with 2 configurations
> in configuration #2?
> 
> I have run into the same trouble - that set_configuration is not usable 
> inside probe(). I have looked at the hotplug scripts, but I have found 
> no example for doing this. The usb hotplug scripts seems not to know 
> about different configurations?
> 
> best regards
> Wolfgang Mües

This is still relatively new and hasn't percolated down to the level of 
the hotplug scripts yet.  Nevertheless, in a hotplug script is the right 
place to do it.

The script can write the configuration value to the bConfigurationValue
file in the device's sysfs directory.  For example,

  echo 2 >/sys/devices/pci0000:00/0000:00:07.2/usb1/1-1/bConfigurationValue

Of course, inside a hotplug script that long pathname would be available 
as an argument or an environment variable.

Alan Stern



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to