On 01/23/14 20:13, Tim Roberts wrote:
> Bent Bisballe Nyeng wrote:
>> We have a composite device that works like a USB HUB connecting to one
>> device at a time.
>> When a new connection is made the endpoints change although the device
>> connection itself is not changed.
>
> What led you to think that was a legitimate thing to do?  Once a driver
> has done a "set configuration", it's not clear that the endpoint
> configuration is allowed to change.  You can certainly have multiple
> alternate settings, where each setting has a different set of endpoints,
> but I don't see how you can possibly expect an on-the-fly change to
> work.  How would you notify the host that things have changed?  You
> can't expect it to poll your descriptors repeatedly.

Allow me to elaborate a bit; we did not /make/ the device, we are merely 
/using/ it and need it to work. I do not know whether the behavior is 
embraced by the USB specification, all I'm saying is, that it did work 
with libusb once, and the patch made it work again.

On another note I'm not entirely sure whether the device actually 
reconnects when changing its configuration. If so, then libusb 
erroneously (in this usecase) reuses a cached version of the 
configuration rather than polling it again from the device.

As I understand it the removed conditional is merely a slight 
optimization, preventing libusb from polling the configuration from a 
device it has seen before. Removing the conditional might therefore 
waste some CPU cycles upon reconnect of a device, but it shouldn't make 
that much of a difference.

Kind regards
Bent Bisballe Nyeng

------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today. 
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
libusbx-devel mailing list
libusbx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libusbx-devel

Reply via email to