Re: [PATCH 1/6] block: Add config option to not allow writing to mounted devices
From: Jan Kara <jack@suse.cz>
Date: 2023-08-14 16:42:03
Also in:
linux-btrfs, linux-fsdevel, linux-xfs
From: Jan Kara <jack@suse.cz>
Date: 2023-08-14 16:42:03
Also in:
linux-btrfs, linux-fsdevel, linux-xfs
On Tue 04-07-23 09:52:40, Eric Biggers wrote:
On Tue, Jul 04, 2023 at 11:56:44AM -0400, Colin Walters wrote:quoted
quoted
+/* open is exclusive wrt all other BLK_OPEN_WRITE opens to the device */ +#define BLK_OPEN_BLOCK_WRITES ((__force blk_mode_t)(1 << 5))Bikeshed but: I think BLK and BLOCK "stutter" here. The doc comment already uses the term "exclusive" so how about BLK_OPEN_EXCLUSIVE ?Yeah, using "block" in two different ways at the same time is confusing. BLK_OPEN_EXCLUSIVE would probably be good, as would something like BLK_OPEN_RESTRICT_WRITES.
BLK_OPEN_RESTRICT_WRITES sounds good to me. I'll rename the flag. Honza -- Jan Kara [off-list ref] SUSE Labs, CR