Am Donnerstag, 27. Juni 2002 18:20 schrieb David Brownell:
> Oliver Neukum wrote:
> >>after looking around in source codes and searching in mailing list and
> >>G*gle, I still couldn't find any hints why there exists only one
> >> "khubd" in USB Stack.
> >
> > Hotpluggings are rare events ...  Besides they take BKL and thus
> > couldn't run in concurrency.
>
> What was the reason they have BKL?  In principle it shouldn't
> be needed, since all the relevant USB data structures are locked
> correctly, and there's no comment in the code explaining why
> the hub driver touches the BKL ...

Module unloading.

This code from usb_find_interface_driver() would race else:

        for (tmp = usb_driver_list.next; tmp != &usb_driver_list;) {
                driver = list_entry(tmp, struct usb_driver, driver_list);
                tmp = tmp->next;

                if (driver->owner)
                        __MOD_INC_USE_COUNT(driver->owner);

        Regards
                Oliver




-------------------------------------------------------
Sponsored by:
ThinkGeek at http://www.ThinkGeek.com/
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to