Re: [GIT PULL] bcachefs
From: Linus Torvalds
Date: Thu Aug 10 2023 - 14:09:59 EST
On Thu, 10 Aug 2023 at 11:02, Kent Overstreet <kent.overstreet@xxxxxxxxx> wrote:
>
> When using sget() in the conventional way it's not possible for
> FMODE_EXCL to protect against concurrent opens scribbling over each
> other because we open the block device before checking if it's already
> mounted, and we expect that open to succeed.
So? Read-only operations. Don't write to anything until after you then
have verified your exclusive status.
If you think you need to be exclusive to other people opening the
device for other things, just stop expecting to control the whole
world.
Linus