On Mon, Mar 13, 2006 at 11:49:29PM +0100, Oliver Neukum wrote:
> Am Montag, 13. M?rz 2006 23:33 schrieb Greg KH:
> > > Wouldn't it be better to do get_device() on control_interface->dev just
> > > before calling tty_register_device(), so that the data structure isn't
> > > released too soon? ?(And of course, call put_device() after the tty
> > > device is unregistered.) ?That way all the sysfs links remain intact, as
> > > intended.
> > 
> > The sysfs core does the 'get' when it creates the symlink. ?I'm guessing
> > that the acm driver isn't properly handing the reference counting of it,
> > but I haven't looked into it much just yet...
> 
> It does usb_get_intf() before it passes the reference to the tty layer.

Yeah, that looks sane, the odd thing is on the disconnect path you
disconnect the control interface too.  This device has the two
interfaces switched, so there's something in there that hasn't been
tested with having the disconnect happening on the other interface
first...

And without such a device, it sure is a pain to try to debug it.

thanks,

greg k-h


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&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