On Fri, 1 Dec 2006, Chris Ostler wrote: > I'm writing a driver for a composite (telephony) device which has three > interfaces. Due to the design of the device, the interfaces will never be > used in isolation - you have to use all three to get any useful > functionality. > > That said, there are essentially three 'channels' of communication: a > bi-directional control channel, and two bi-directional audio channels. I'd > like to present this as: > /dev/cg%d - the control channel > /dev/cg%da - the first audio channel > /dev/cg%db - the second audio channel > > Ideally, I'd like to bind the driver to the device, and then register the > three device nodes. However, it seems that binding is done at the > interface level. I seem to recall some discussion of binding at the device > level, but I didn't see any examples of this. ... > My questions then are: > 1) What's the proper way to bind to a device instead of an interface?
There is no way to do it. Instead you bind to the first interface and have your probe routine call usb_driver_claim_interface() for the other two. Similarly, your disconnect routine has to call usb_driver_release_interface() for all the interfaces. There are a few existing drivers which do this. Search the kernel source for calls to usb_driver_claim_interface. Alan Stern ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
