stefani@xxxxxxxxxxx writes: > } > > + if (dev->in_use) { > + retval = -EBUSY; > + goto exit; > + } This plus setting the flag has to be inside the mutex, otherwise you have an obvious race. -Andi -- ak@xxxxxxxxxxxxxxx -- Speaking for myself only -- 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