On Sat, 6 Mar 2010, Oliver Neukum wrote: > Am Samstag, 6. März 2010 16:34:31 schrieb Alan Stern: > > On Sat, 6 Mar 2010, Oliver Neukum wrote: > > > > The caller of usbfs_conn_disc_event() already holds usbfs_mutex. > > > Don't take it again. > > > > That's not true. The caller holds usbfs_mutex only when the action is > > USB_DEVICE_REMOVE. Not when the action is USB_DEVICE_ADD or USB_BUS_*. > > Right. That's what you get for wanting a quick fix. What do you > propose? Guard conndiscevcnt and file->private_data with a separate static mutex instead of usbfs_mutex. Incidentally, what's supposed to happen if more than one thread tries to poll the same file descriptor simultaneously? Do you really want the first thread to wait only until the first event while the second thread is forced to wait for a second event? Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html