Re: Piggy-backing new hardware using old usb-serial

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2013-03-28 at 15:58 +0100, Wesley W. Terpstra wrote:
> On Thu, 2013-03-28 at 09:39 -0500, Dan Williams wrote:
> > Greg's right, there's no reason not to use cdc-acm if you want to do
> > that, since not all cdc-acm devices are modems.  If you get a USBIF
> > vendor ID, then I'll happily add your device to the ModemManager probing
> > blacklist too.
> 
> Yes, the cdc-acm approach has the distinct advantage of not having to
> write one driver for each OS.
> 
> What does ModemManager probing consist of? Sending a few ATx commands to
> see what the device is? On the interactive console that wouldn't hurt,
> but on the proprietary data channel it could break things.

ModemManager looks at a certain set of serial devices and probes each
TTY the device provides with AT commands, Qualcomm DIAG (QCDM) requests,
Qualcomm MSM Interface (QMI) requests, and potentially other protocols.
It does filter devices based on driver name (eg, 'sierra' is certainly a
modem while 'whiteheat' certainly is not).

Probing is necessary because there are a *ton* of devices out there,
manufacturers often use the same VID/PID for wildly different devices
(even completely different modem chipsets *cough* TCT Mobile *cough*),
or don't bother to use a unique VID/PID at all.  Sometimes firmware
updates change the USB interface layout, so what used to be an AT port
is now a DIAG port, or even the PID has changed.  We've seen it all.

We've tried the tag-every-known-modem-by-USB-details approach before,
and that simply isn't scalable, especially when you throw tethering your
handset into the mix.  There are even more phones than there are USB
dongles.

Windows doesn't have this problem, because your dongle provider or
cellular provider provides the drivers for their specific device, and
you're never expected to install more than one set of drivers at a time.
Get a new device?  Great!  Install the connection manager specific for
that device and uninstall the old one.

Probing does break things on devices that don't expect it, like UPSs or
other stuff, which is why we have a blacklist for stuff we know MM
shouldn't probe.  Happy to add to it.

Dan

> I assume that it poses no problem to the linux cdc enumeration if my
> device reports two data interfaces (with two endpoints each).
> 
> Once I have added an interrupt endpoint and ignore the class specific
> requests to meet the CDC-ACM interface and have a valid VID+PID pair,
> I'll get back to you.
> 
> In case anyone else cares, I found some nice Dutch folks who resell PIDs
> under their VID for cheap:
> http://www.mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&option=com_phpshop&Itemid=1
> 
> I will probably go this route for now.
> 
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-usb" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


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




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux