On Thu, Apr 18, 2002, David Brownell <[EMAIL PROTECTED]> wrote:
> > It also doesn't help in cases like usbdevfs. What if it wants to use the
> > device structure for some reason, like say a user reading
> > /proc/bus/usb/devices. It should increment the reference count, do it's
> > stuff and then decrement it. But it doesn't have a deallocate like call.
> > As a result, there's a race there.
> 
> Not so.  Like all USB device drivers, usbfs has disconnect().

It's not claiming the device. The /proc/bus/usb/devices example just
walks to the lists.

> And yes, there _were_ some races there, which now seem to
> have been fixed.  (The original code basically did nothing.)
> 
> Those races were finally tracked down through use of some
> refcount-related BUG() calls ... like other drivers' disconnect()
> bugs also triggered such calls.  Took way too many months to
> track them down since they only fired in some configurations.

Yes, those were bugs, but unrelated to what I was talking about.

> Moving the BUG() calls to where UHCI could trigger them too
> helped to quickly confirm the problem and sanity check the fix.

I'm not sure I understand what you mean here?

JE


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

Reply via email to