tech-kern archive

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

Tips on programming usb devices?

        Hello.  I'm working on a driver for the Novatel 551L USB data modem
from Verizon.  This is a device that looks like an ethernet  port (cdce(4))
on one interface, and a modem on another (u3g(4)).  The easiest tack strikes
me as modifying the cdce(4) driver to attach an ucom device to itself in the
event there is such an interface to attach to.  For the initial attempt, I
match the device on the product and vendor IDs
        This works fine, but what happens now is that all of the interrfaces
on the device match the cdce(4) driver, and I get 4 instances of the driver
running at once.  I've been trying to use the u3g.c driver as a model of
how to configure multiple interfaces on a device, but there seem to be some
inconsistencies about how the various usb drivers initialize themselves,
and I'm not entirely sure I know which code does what.  Can someone point
me at a good code example in our tree of a driver that claims multiple
interfaces on a usb device and maybe even at the lines that do the
claiming?  I've been successful at getting the attaches to work, but not at
telling the config code that  I have all the interfaces for this device,
thank you very much.

        For those that care, I'm basing my work on the fact that the Linux
folks seem to have these Qualcomm Gobi based devices working by twiddling
the modems with some python scripts before they fire up dhcp clients
against the ethernet side of these devices.  If someone else has this
device working under NetBSD, or a device like it, I'm happy to use what
ever tricks they did to get it going.

        Any tips, thoughts or other help would be greatly appreciated.


Home | Main Index | Thread Index | Old Index