On Sat, Nov 05, 2005 at 03:42:42AM +0200, Alexander Kanavin wrote: > Greg KH wrote: > >>Changing the interface in probe() would be possible if > >>usb_serial_probe() would set its interface pointer to serial->interface > >> > >>603 id = usb_match_id(interface, type->id_table); > >>604 retval = type->probe(serial, id); > >> > >>here. > > > > > >I'm sorry, but I don't understand. Care to just mock up a patch to show > >what you mean? > > Sure. > > In usb-serial.c, usb_serial_probe() > > id = usb_match_id(interface, type->id_table); > retval = type->probe(serial, id); > + interface = serial->interface; > module_put(type->driver.owner); > > Then it would be possible for usb serial drivers to set a different data > interface in probe() via the serial structure, and for usb-serial to > pick that up.
Ugh, no, there's just too many bad things that can happen if you try to do this. Think about the fact that you are in the probe function of a different interface than the one you just claimed... thanks, greg k-h ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
