On Fri, 1 Sep 2006, Chris Aseltine wrote:

> Hello everyone,
> 
> I previously asked these questions to Greg privately email, but he asked
> me to email the list so everyone could see.  I've since learned the
> answers (I think..) but will still pose them here:
> 
> 1)  If I have a USB composite device with say, four interfaces, I wanted
> to know if I could load four different drivers / kernel modules for the
> device -- one per interface.
> 
> I believe you can, since each USB kernel module will have its registered
> probe() function called for each interface that arrives on the system, and
> each can decide whether it wants to claim the interface or not.

That's right.

> 2)  I then asked if I had a USB composite device with four interfaces, but
> the first two are CDC ACM -- what would happen?  In this case, one driver
> needs to be loaded for *two* interfaces, and two more drivers for the
> other two -- this also seems to work "out of the box".

Yes, it does.

> Any clarifications / confirmations welcome.  As I mentioned to Greg, my
> previous frame of reference is Windows where case #1 will work using the
> generic parent "bus" driver but #2 will not.

I don't know how Windows works internally.  In Linux, each interface is 
represented as by separate device structure, each capable of having its 
own driver.  Or of sharing a driver with a different interface.

> By the way, as I've been doing development, I've noticed that various
> constructs seem to disappear from the kernel on a regular basis (i.e.
> members of structs, function exports from inside the kernel, etc.)  This
> tends to lead to "surprises" when maintaining a driver that is outside of
> the tree.

I'm sure Greg has/will/is willing to talk your ears off about this.  
Basically, if you're working on a driver that could be at all useful, you 
should submit it for inclusion in the official kernel.  That way it isn't 
out-of-tree and you don't suffer from these "surprises" -- or at least, 
not as much.

> Can we safely assume that when any symbols, etc. disappear, the
> functionality they represented is still available through some other
> method?

Yes.  Unless it is decided that the functionality was a bad idea, poorly 
conceived, inadequately carried out, and is better off dead.  That happens 
occasionally but not too often, and there is almost always some other way 
to accomplish what you want.

Alan Stern


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to