Re: [PATCH] USB: core: Remove usbfs_mutex

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 25, 2019 at 04:03:58PM -0400, Alan Stern wrote:
> Commit 4a2a8a2cce86 ("usbfs: private mutex for open, release, and
> remove") is now obsolete.  The commit was created back when we had
> to handle both usbfs device nodes and the old usbdevfs filesystem
> (/proc/bus/usb/), but usbdevfs no longer exists.
> 
> This means there's no longer any need to hold a mutex during two
> separate removal operations (and thus during an entire notifier chain
> call).  Furthermore, the one remaining remove/release pair doesn't
> race with open thanks to the synchronization provided by the device
> model core in bus_find_device().  Remove and release don't race with
> each other because they both run with the device lock held.
> 
> The upshot is that usbfs_mutex isn't needed any more.  This patch
> removes it entirely.
> 
> Signed-off-by: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>
> 

Ah, nice, I forgot all about this mutex, thanks for removing it!

greg k-h



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux