On Mon, 2006-03-13 at 13:48 -0800, Pete Zaitcev wrote:
> The control_interface->dev aka acm->control->dev is located inside
> the usb_interface structure, held down by the counter. How is this
> possible to be released? I suspect your analysis may be incomplete.

Your right, I am missing something.
Using NULL with tty_register_device() does fix the oops,
but maybe it is just covering an unrelated bug.

--

Here is the oops call trace, but I'm not sure where in
__mutex_lock_slowpath it hits. The access is to offset
x90 from 6b6b6b6b. I'm also not sure which sysfs_remove_link
call in class_device_del() is killing it, I had been assuming
the second but neither is called when NULL is used.

Unable to handle kernel paging request at virtual address 6b6b6bfb
EIP is at __mutex_lock_slowpath+0x70/0x286

void sysfs_hash_and_remove(struct dentry * dir, const char * name)
{
...
>>>     mutex_lock(&dir->d_inode->i_mutex);

void sysfs_remove_link(struct kobject * kobj, const char * name)
{
>>>     sysfs_hash_and_remove(kobj->dentry,name);
}

void class_device_del(struct class_device *class_dev)
{
...
        if (class_dev->dev) {
                class_name = make_class_name(class_dev);
>>>             sysfs_remove_link(&class_dev->kobj, "device");
>>>             sysfs_remove_link(&class_dev->dev->kobj, class_name);

void class_device_unregister(struct class_device *class_dev)
{
...
>>>     class_device_del(class_dev);

void class_device_destroy(struct class *cls, dev_t devt)
{
...
        if (class_dev)
>>>             class_device_unregister(class_dev);

void tty_unregister_device(struct tty_driver *driver, unsigned index)
{
        devfs_remove("%s%d", driver->devfs_name, index + driver->name_base);
>>>     class_device_destroy(tty_class, MKDEV(driver->major, 
>>> driver->minor_start) + index);


-- 
Paul Fulghum
Microgate Systems, Ltd



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