Josh, you're correct in that this is a long standing issue. Although I would 
not call it architectural, it is simply an API issue (the user should be able 
to specify the altsetting he wants the max-packet-size for).

As for this blocking this patch, no the patch can go in as is, but I was hoping 
you could help to do a new proper API for this.

As for you only fixing things you need for your project. If you're doing 
something with isoc endpoints and not using multiple alt-settings you're doing 
it wrong. A device is not allowed to have active isoc endpoints in altsetting 
0, iow in altsetting 0 it must either advertise maxpacketsize 0, or simply not 
advertise the isoc endpoints at all.

The reason for this is that otherwise the OS must reserve the isoc bandwidth 
even if the device is not active. IOW devices start in altsetting 0, without 
reserved bandwidth, and once the OS/driver wants to use them it changes their 
altsetting, thus reserving the bandwidth (note in some OS-es / with some host 
drivers the bandwidth is not reserved until the isoc stream is actually 
started).

So you should have multiple altsettings in your device, and thus you should 
need a new API to ensure you're getting the maxpacketsize for the right 
altsetting.

While talking about this, note that many isoc dusing evices have multiple 
altsettings, since they don't always use the same bandwidth. This is seen often 
with webcams where the used altsetting (== reserved bandwidth) depends on the 
resolution and framerate the user wants the webcam to stream in.


---
Reply to this email directly or view it on GitHub:
https://github.com/libusbx/libusbx/pull/163#issuecomment-30300154
------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT 
organizations don't have a clear picture of how application performance 
affects their revenue. With AppDynamics, you get 100% visibility into your 
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&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