On Tue, 2006-03-14 at 00:06 +0100, Oliver Neukum wrote:
> > > 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.

Bob, this problem has not yet been properly diagnosed.
Can you help by running with this patch and returning
the syslog output (with the oops also)?

Thanks,
Paul

--- linux-2.6.16-rc6/drivers/usb/class/cdc-acm.c        2006-03-14 
08:30:32.000000000 -0600
+++ b/drivers/usb/class/cdc-acm.c       2006-03-14 09:21:43.000000000 -0600
@@ -489,6 +489,8 @@ static void acm_tty_unregister(struct ac
 {
        int i;
 
+       printk("acm_tty_unregister if=%p dev=%p ref=%d\n",
+              acm->control, &acm->control->dev, 
atomic_read(&acm->control->dev.kobj.kref.refcount));
        tty_unregister_device(acm_tty_driver, acm->minor);
        usb_put_intf(acm->control);
        acm_table[acm->minor] = NULL;
@@ -980,6 +982,9 @@ skip_normal_probe:
        usb_driver_claim_interface(&acm_driver, data_interface, acm);
 
        usb_get_intf(control_interface);
+       printk("acm_probe call tty_register_device if=%p dev=%p ref=%d\n",
+              control_interface, &control_interface->dev,
+              atomic_read(&control_interface->dev.kobj.kref.refcount));
        tty_register_device(acm_tty_driver, minor, &control_interface->dev);
 
        acm_table[minor] = acm;
--- linux-2.6.16-rc6/drivers/usb/core/message.c 2006-03-14 08:30:32.000000000 
-0600
+++ b/drivers/usb/core/message.c        2006-03-14 09:16:24.000000000 -0600
@@ -1290,6 +1290,8 @@ static void release_interface(struct dev
        struct usb_interface_cache *intfc =
                        altsetting_to_usb_interface_cache(intf->altsetting);
 
+       printk("usb release_interface if=%p dev=%p ref=%d\n",
+              intf, &intf->dev, atomic_read(&intf->dev.kobj.kref.refcount));
        kref_put(&intfc->ref, usb_release_interface_cache);
        kfree(intf);
 }




-------------------------------------------------------
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