<div dir="ltr"><div dir="auto"></div><div class="gmail_extra"><br><div class="gmail_quote">On Jan 9, 2017 18:56, "Bjørn Mork" <<a href="mailto:bjorn@mork.no" target="_blank">bjorn@mork.no</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Lars Knudsen <<a href="mailto:larsgk@gmail.com" target="_blank">larsgk@gmail.com</a>> writes:<br>
<br>
> It seemed like if just one interface in the description list was somehow<br>
> compliant with modem manager, the full device seemed claimed.<br>
><br>
> I may have missed something in my headers while experimenting. Can you give<br>
> an example of a header structure that will not be assumed to be a modem by<br>
> MM while still accessible as a proper CDC serial device - without<br>
> blacklisting anything?<br>
<br>
I am slowly starting to wonder if the concern is about composite devices<br>
where you want a subset of the functions to be used in one context (MM)<br>
and another subset to be used in another context (WebUSB)?  Is this<br>
correct?<br></blockquote><div><br></div><div>Well, ideally, any WebUSB device that exposes a CDC interface (e.g. configured with [0]CDC INT, [1]CDC BULK and [2]WebUSB CDC/BULK) would:</div><div><br></div><div>1) not be considered a modem (it would not make sense to do a modem including webusb headers - in the same device mode at least)</div><div>2) provide standard /dev/ttyUSBx serial functionality on the standard CDC endpoints (e.g. interface 1 above)</div><div>3) provide full user access to the WebUSB CDC/BULK interface (2 above)</div><div><br></div><div>What I was asking before is for an example header/configuration descriptors where MM would *not* pick up the CDC interface but the system still creating a /dev/ttyUSBx device (or ttyACMx - which it's called when MM is installed) - without creating blacklisting rules specifically for e.g. *that* VID/PID combo.</div><div>When I was experimenting the last few days - this did not seem possible.  I had to completely wipe any indication of this device being CDC before MM stopped claiming it.  Surely, MM should not pick it up if the device indicates it doesn't have call functionality?</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
If so, then I believe you won't be able handle that in a single<br>
configuration.  If you mix all functions in a single configuration then<br>
you are correct that MM will take control of the device based on the<br>
functions it (or the kernel) supports.<br>
<br>
Split the function subsets in different configurations and make the OS<br>
and/or userspace select the active one if you need to support these<br>
different use cases.  Anything else is going to be an endless mess of<br>
workarounds and quirk lists all over the place.<br>
<br>
<br>
Bjørn<br>
</blockquote></div></div>
</div>