Re: [PATCH 10/19] USB: gadget/legacy: remove sb_mutex

From: Christoph Hellwig
Date: Tue Sep 26 2023 - 05:24:40 EST


On Wed, Sep 13, 2023 at 12:10:56PM -0400, Alan Stern wrote:
> On Wed, Sep 13, 2023 at 08:10:04AM -0300, Christoph Hellwig wrote:
> > Creating new a new super_block vs freeing the old one for single instance
> > file systems is serialized by the wait for SB_DEAD.
> >
> > Remove the superfluous sb_mutex.
> >
> > Signed-off-by: Christoph Hellwig <hch@xxxxxx>
> > ---
>
> You might mention that this is essentially a reversion of commit
> d18dcfe9860e ("USB: gadgetfs: Fix race between mounting and
> unmounting").

The difference we have now is that sb creation waits for the
old one to go way, but I'll add a notice on all that.