Am Donnerstag, 2. Februar 2012, 09:48:06 schrieb Bjørn Mork: > Hmm, looking at the code, and realizing that the reason we're taking > wlock here only is that the driver used to take the combined read/write > lock, I don't think it's necessary at all. desc->count is only modified > by wdm_open() and wdm_release(), both holding the global wdm_mutex at > the time. The only place desc->count is tested without holding the > wdm_mutex lock is in recover_from_urb_loss() which is called from > wdm_resume() and wdm_post_reset(). I don't think that is a problem > though, as both require holding the device lock which will protect them > from competing against each other. > > So in short: I don't think the wlock offers any extra protection in > wdm_open and wdm_release and I would like to just drop it if you too > think that's OK. What is to guard pre/post_reset against open() ? Regards Oliver -- 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