All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Mount option bit definitions cleanups
@ 2021-06-18 14:52 David Sterba
  2021-06-18 14:52 ` [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type David Sterba
  2021-06-18 14:52 ` [PATCH 2/2] btrfs: shorten integrity checker extent data mount option David Sterba
  0 siblings, 2 replies; 5+ messages in thread
From: David Sterba @ 2021-06-18 14:52 UTC (permalink / raw)
  To: linux-btrfs; +Cc: David Sterba

The number of mount options has reached 32bit limit and adding a new one
causes some funny effects, so convert them to enum and use proper int
width.

David Sterba (2):
  btrfs: switch mount option bits to enums and use wider type
  btrfs: shorten integrity checker extent data mount option

 fs/btrfs/ctree.h   | 65 +++++++++++++++++++++++-----------------------
 fs/btrfs/disk-io.c |  3 +--
 fs/btrfs/super.c   |  5 ++--
 3 files changed, 36 insertions(+), 37 deletions(-)

-- 
2.31.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type
  2021-06-18 14:52 [PATCH 0/2] Mount option bit definitions cleanups David Sterba
@ 2021-06-18 14:52 ` David Sterba
  2021-06-22 10:53   ` Anand Jain
  2021-06-18 14:52 ` [PATCH 2/2] btrfs: shorten integrity checker extent data mount option David Sterba
  1 sibling, 1 reply; 5+ messages in thread
From: David Sterba @ 2021-06-18 14:52 UTC (permalink / raw)
  To: linux-btrfs; +Cc: David Sterba

Switch defines of BTRFS_MOUNT_* to an enum (the symbolic names are
recorded in the debugging information for convenience).

There are two more things done but separating them would not make much
sense as it's touching the same lines:

- Renumber shifts 18..31 to 17..30 to get rid of the hole in the
  sequence.

- Use 1UL as the value that gets shifted because we're approaching the
  32bit limit and due to integer promotions the value of (1 << 31)
  becomes 0xffffffff80000000 when cast to unsigned long (eg. the option
  manipulating helpers).

  This is not causing any problems yet as the operations are in-memory
  and masking the 31st bit works, we don't have more than 31 bits so the
  ill effects of not masking higher bits don't happen. But once we have
  more, the problems will emerge.

Signed-off-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/ctree.h | 65 ++++++++++++++++++++++++------------------------
 1 file changed, 33 insertions(+), 32 deletions(-)

diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index 6131b58f779f..e0f6aa6e8bd2 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -1384,38 +1384,39 @@ static inline u32 BTRFS_MAX_XATTR_SIZE(const struct btrfs_fs_info *info)
  *
  * Note: don't forget to add new options to btrfs_show_options()
  */
-#define BTRFS_MOUNT_NODATASUM		(1 << 0)
-#define BTRFS_MOUNT_NODATACOW		(1 << 1)
-#define BTRFS_MOUNT_NOBARRIER		(1 << 2)
-#define BTRFS_MOUNT_SSD			(1 << 3)
-#define BTRFS_MOUNT_DEGRADED		(1 << 4)
-#define BTRFS_MOUNT_COMPRESS		(1 << 5)
-#define BTRFS_MOUNT_NOTREELOG           (1 << 6)
-#define BTRFS_MOUNT_FLUSHONCOMMIT       (1 << 7)
-#define BTRFS_MOUNT_SSD_SPREAD		(1 << 8)
-#define BTRFS_MOUNT_NOSSD		(1 << 9)
-#define BTRFS_MOUNT_DISCARD_SYNC	(1 << 10)
-#define BTRFS_MOUNT_FORCE_COMPRESS      (1 << 11)
-#define BTRFS_MOUNT_SPACE_CACHE		(1 << 12)
-#define BTRFS_MOUNT_CLEAR_CACHE		(1 << 13)
-#define BTRFS_MOUNT_USER_SUBVOL_RM_ALLOWED (1 << 14)
-#define BTRFS_MOUNT_ENOSPC_DEBUG	 (1 << 15)
-#define BTRFS_MOUNT_AUTO_DEFRAG		(1 << 16)
-/* bit 17 is free */
-#define BTRFS_MOUNT_USEBACKUPROOT	(1 << 18)
-#define BTRFS_MOUNT_SKIP_BALANCE	(1 << 19)
-#define BTRFS_MOUNT_CHECK_INTEGRITY	(1 << 20)
-#define BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA (1 << 21)
-#define BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	(1 << 22)
-#define BTRFS_MOUNT_RESCAN_UUID_TREE	(1 << 23)
-#define BTRFS_MOUNT_FRAGMENT_DATA	(1 << 24)
-#define BTRFS_MOUNT_FRAGMENT_METADATA	(1 << 25)
-#define BTRFS_MOUNT_FREE_SPACE_TREE	(1 << 26)
-#define BTRFS_MOUNT_NOLOGREPLAY		(1 << 27)
-#define BTRFS_MOUNT_REF_VERIFY		(1 << 28)
-#define BTRFS_MOUNT_DISCARD_ASYNC	(1 << 29)
-#define BTRFS_MOUNT_IGNOREBADROOTS	(1 << 30)
-#define BTRFS_MOUNT_IGNOREDATACSUMS	(1 << 31)
+enum {
+	BTRFS_MOUNT_NODATASUM			= (1UL << 0),
+	BTRFS_MOUNT_NODATACOW			= (1UL << 1),
+	BTRFS_MOUNT_NOBARRIER			= (1UL << 2),
+	BTRFS_MOUNT_SSD				= (1UL << 3),
+	BTRFS_MOUNT_DEGRADED			= (1UL << 4),
+	BTRFS_MOUNT_COMPRESS			= (1UL << 5),
+	BTRFS_MOUNT_NOTREELOG   		= (1UL << 6),
+	BTRFS_MOUNT_FLUSHONCOMMIT		= (1UL << 7),
+	BTRFS_MOUNT_SSD_SPREAD			= (1UL << 8),
+	BTRFS_MOUNT_NOSSD			= (1UL << 9),
+	BTRFS_MOUNT_DISCARD_SYNC		= (1UL << 10),
+	BTRFS_MOUNT_FORCE_COMPRESS      	= (1UL << 11),
+	BTRFS_MOUNT_SPACE_CACHE			= (1UL << 12),
+	BTRFS_MOUNT_CLEAR_CACHE			= (1UL << 13),
+	BTRFS_MOUNT_USER_SUBVOL_RM_ALLOWED	= (1UL << 14),
+	BTRFS_MOUNT_ENOSPC_DEBUG		= (1UL << 15),
+	BTRFS_MOUNT_AUTO_DEFRAG			= (1UL << 16),
+	BTRFS_MOUNT_USEBACKUPROOT		= (1UL << 17),
+	BTRFS_MOUNT_SKIP_BALANCE		= (1UL << 18),
+	BTRFS_MOUNT_CHECK_INTEGRITY		= (1UL << 19),
+	BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA = (1UL << 20),
+	BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	= (1UL << 21),
+	BTRFS_MOUNT_RESCAN_UUID_TREE		= (1UL << 22),
+	BTRFS_MOUNT_FRAGMENT_DATA		= (1UL << 23),
+	BTRFS_MOUNT_FRAGMENT_METADATA		= (1UL << 24),
+	BTRFS_MOUNT_FREE_SPACE_TREE		= (1UL << 25),
+	BTRFS_MOUNT_NOLOGREPLAY			= (1UL << 26),
+	BTRFS_MOUNT_REF_VERIFY			= (1UL << 27),
+	BTRFS_MOUNT_DISCARD_ASYNC		= (1UL << 28),
+	BTRFS_MOUNT_IGNOREBADROOTS		= (1UL << 29),
+	BTRFS_MOUNT_IGNOREDATACSUMS		= (1UL << 30),
+};
 
 #define BTRFS_DEFAULT_COMMIT_INTERVAL	(30)
 #define BTRFS_DEFAULT_MAX_INLINE	(2048)
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 2/2] btrfs: shorten integrity checker extent data mount option
  2021-06-18 14:52 [PATCH 0/2] Mount option bit definitions cleanups David Sterba
  2021-06-18 14:52 ` [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type David Sterba
@ 2021-06-18 14:52 ` David Sterba
  2021-06-22 10:53   ` Anand Jain
  1 sibling, 1 reply; 5+ messages in thread
From: David Sterba @ 2021-06-18 14:52 UTC (permalink / raw)
  To: linux-btrfs; +Cc: David Sterba

Subjectively, CHECK_INTEGRITY_INCLUDING_EXTENT_DATA is quite long and
calling it CHECK_INTEGRITY_DATA still keeps the meaning and matches the
mount option name.

Signed-off-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/ctree.h   | 2 +-
 fs/btrfs/disk-io.c | 3 +--
 fs/btrfs/super.c   | 5 ++---
 3 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index e0f6aa6e8bd2..4d156d9e8050 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -1405,7 +1405,7 @@ enum {
 	BTRFS_MOUNT_USEBACKUPROOT		= (1UL << 17),
 	BTRFS_MOUNT_SKIP_BALANCE		= (1UL << 18),
 	BTRFS_MOUNT_CHECK_INTEGRITY		= (1UL << 19),
-	BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA = (1UL << 20),
+	BTRFS_MOUNT_CHECK_INTEGRITY_DATA	= (1UL << 20),
 	BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	= (1UL << 21),
 	BTRFS_MOUNT_RESCAN_UUID_TREE		= (1UL << 22),
 	BTRFS_MOUNT_FRAGMENT_DATA		= (1UL << 23),
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
index 544bb7a82e57..6eb0010f9c7e 100644
--- a/fs/btrfs/disk-io.c
+++ b/fs/btrfs/disk-io.c
@@ -3598,8 +3598,7 @@ int __cold open_ctree(struct super_block *sb, struct btrfs_fs_devices *fs_device
 	if (btrfs_test_opt(fs_info, CHECK_INTEGRITY)) {
 		ret = btrfsic_mount(fs_info, fs_devices,
 				    btrfs_test_opt(fs_info,
-					CHECK_INTEGRITY_INCLUDING_EXTENT_DATA) ?
-				    1 : 0,
+					CHECK_INTEGRITY_DATA) ? 1 : 0,
 				    fs_info->check_integrity_print_mask);
 		if (ret)
 			btrfs_warn(fs_info,
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
index bc613218c8c5..d07b18b2b250 100644
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@ -934,8 +934,7 @@ int btrfs_parse_options(struct btrfs_fs_info *info, char *options,
 		case Opt_check_integrity_including_extent_data:
 			btrfs_info(info,
 				   "enabling check integrity including extent data");
-			btrfs_set_opt(info->mount_opt,
-				      CHECK_INTEGRITY_INCLUDING_EXTENT_DATA);
+			btrfs_set_opt(info->mount_opt, CHECK_INTEGRITY_DATA);
 			btrfs_set_opt(info->mount_opt, CHECK_INTEGRITY);
 			break;
 		case Opt_check_integrity:
@@ -1516,7 +1515,7 @@ static int btrfs_show_options(struct seq_file *seq, struct dentry *dentry)
 	if (btrfs_test_opt(info, SKIP_BALANCE))
 		seq_puts(seq, ",skip_balance");
 #ifdef CONFIG_BTRFS_FS_CHECK_INTEGRITY
-	if (btrfs_test_opt(info, CHECK_INTEGRITY_INCLUDING_EXTENT_DATA))
+	if (btrfs_test_opt(info, CHECK_INTEGRITY_DATA))
 		seq_puts(seq, ",check_int_data");
 	else if (btrfs_test_opt(info, CHECK_INTEGRITY))
 		seq_puts(seq, ",check_int");
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type
  2021-06-18 14:52 ` [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type David Sterba
@ 2021-06-22 10:53   ` Anand Jain
  0 siblings, 0 replies; 5+ messages in thread
From: Anand Jain @ 2021-06-22 10:53 UTC (permalink / raw)
  To: David Sterba, linux-btrfs

On 18/06/2021 22:52, David Sterba wrote:
> Switch defines of BTRFS_MOUNT_* to an enum (the symbolic names are
> recorded in the debugging information for convenience).
> 
> There are two more things done but separating them would not make much
> sense as it's touching the same lines:
> 
> - Renumber shifts 18..31 to 17..30 to get rid of the hole in the
>    sequence.
> 
> - Use 1UL as the value that gets shifted because we're approaching the
>    32bit limit and due to integer promotions the value of (1 << 31)
>    becomes 0xffffffff80000000 when cast to unsigned long (eg. the option
>    manipulating helpers).
> 
>    This is not causing any problems yet as the operations are in-memory
>    and masking the 31st bit works, we don't have more than 31 bits so the
>    ill effects of not masking higher bits don't happen. But once we have
>    more, the problems will emerge.
> 
> Signed-off-by: David Sterba <dsterba@suse.com>

Reviewed-by: Anand Jain <anand.jain@oracle.com>

Thanks, Anand


> ---
>   fs/btrfs/ctree.h | 65 ++++++++++++++++++++++++------------------------
>   1 file changed, 33 insertions(+), 32 deletions(-)
> 
> diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
> index 6131b58f779f..e0f6aa6e8bd2 100644
> --- a/fs/btrfs/ctree.h
> +++ b/fs/btrfs/ctree.h
> @@ -1384,38 +1384,39 @@ static inline u32 BTRFS_MAX_XATTR_SIZE(const struct btrfs_fs_info *info)
>    *
>    * Note: don't forget to add new options to btrfs_show_options()
>    */
> -#define BTRFS_MOUNT_NODATASUM		(1 << 0)
> -#define BTRFS_MOUNT_NODATACOW		(1 << 1)
> -#define BTRFS_MOUNT_NOBARRIER		(1 << 2)
> -#define BTRFS_MOUNT_SSD			(1 << 3)
> -#define BTRFS_MOUNT_DEGRADED		(1 << 4)
> -#define BTRFS_MOUNT_COMPRESS		(1 << 5)
> -#define BTRFS_MOUNT_NOTREELOG           (1 << 6)
> -#define BTRFS_MOUNT_FLUSHONCOMMIT       (1 << 7)
> -#define BTRFS_MOUNT_SSD_SPREAD		(1 << 8)
> -#define BTRFS_MOUNT_NOSSD		(1 << 9)
> -#define BTRFS_MOUNT_DISCARD_SYNC	(1 << 10)
> -#define BTRFS_MOUNT_FORCE_COMPRESS      (1 << 11)
> -#define BTRFS_MOUNT_SPACE_CACHE		(1 << 12)
> -#define BTRFS_MOUNT_CLEAR_CACHE		(1 << 13)
> -#define BTRFS_MOUNT_USER_SUBVOL_RM_ALLOWED (1 << 14)
> -#define BTRFS_MOUNT_ENOSPC_DEBUG	 (1 << 15)
> -#define BTRFS_MOUNT_AUTO_DEFRAG		(1 << 16)
> -/* bit 17 is free */
> -#define BTRFS_MOUNT_USEBACKUPROOT	(1 << 18)
> -#define BTRFS_MOUNT_SKIP_BALANCE	(1 << 19)
> -#define BTRFS_MOUNT_CHECK_INTEGRITY	(1 << 20)
> -#define BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA (1 << 21)
> -#define BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	(1 << 22)
> -#define BTRFS_MOUNT_RESCAN_UUID_TREE	(1 << 23)
> -#define BTRFS_MOUNT_FRAGMENT_DATA	(1 << 24)
> -#define BTRFS_MOUNT_FRAGMENT_METADATA	(1 << 25)
> -#define BTRFS_MOUNT_FREE_SPACE_TREE	(1 << 26)
> -#define BTRFS_MOUNT_NOLOGREPLAY		(1 << 27)
> -#define BTRFS_MOUNT_REF_VERIFY		(1 << 28)
> -#define BTRFS_MOUNT_DISCARD_ASYNC	(1 << 29)
> -#define BTRFS_MOUNT_IGNOREBADROOTS	(1 << 30)
> -#define BTRFS_MOUNT_IGNOREDATACSUMS	(1 << 31)
> +enum {
> +	BTRFS_MOUNT_NODATASUM			= (1UL << 0),
> +	BTRFS_MOUNT_NODATACOW			= (1UL << 1),
> +	BTRFS_MOUNT_NOBARRIER			= (1UL << 2),
> +	BTRFS_MOUNT_SSD				= (1UL << 3),
> +	BTRFS_MOUNT_DEGRADED			= (1UL << 4),
> +	BTRFS_MOUNT_COMPRESS			= (1UL << 5),
> +	BTRFS_MOUNT_NOTREELOG   		= (1UL << 6),
> +	BTRFS_MOUNT_FLUSHONCOMMIT		= (1UL << 7),
> +	BTRFS_MOUNT_SSD_SPREAD			= (1UL << 8),
> +	BTRFS_MOUNT_NOSSD			= (1UL << 9),
> +	BTRFS_MOUNT_DISCARD_SYNC		= (1UL << 10),
> +	BTRFS_MOUNT_FORCE_COMPRESS      	= (1UL << 11),
> +	BTRFS_MOUNT_SPACE_CACHE			= (1UL << 12),
> +	BTRFS_MOUNT_CLEAR_CACHE			= (1UL << 13),
> +	BTRFS_MOUNT_USER_SUBVOL_RM_ALLOWED	= (1UL << 14),
> +	BTRFS_MOUNT_ENOSPC_DEBUG		= (1UL << 15),
> +	BTRFS_MOUNT_AUTO_DEFRAG			= (1UL << 16),
> +	BTRFS_MOUNT_USEBACKUPROOT		= (1UL << 17),
> +	BTRFS_MOUNT_SKIP_BALANCE		= (1UL << 18),
> +	BTRFS_MOUNT_CHECK_INTEGRITY		= (1UL << 19),
> +	BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA = (1UL << 20),
> +	BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	= (1UL << 21),
> +	BTRFS_MOUNT_RESCAN_UUID_TREE		= (1UL << 22),
> +	BTRFS_MOUNT_FRAGMENT_DATA		= (1UL << 23),
> +	BTRFS_MOUNT_FRAGMENT_METADATA		= (1UL << 24),
> +	BTRFS_MOUNT_FREE_SPACE_TREE		= (1UL << 25),
> +	BTRFS_MOUNT_NOLOGREPLAY			= (1UL << 26),
> +	BTRFS_MOUNT_REF_VERIFY			= (1UL << 27),
> +	BTRFS_MOUNT_DISCARD_ASYNC		= (1UL << 28),
> +	BTRFS_MOUNT_IGNOREBADROOTS		= (1UL << 29),
> +	BTRFS_MOUNT_IGNOREDATACSUMS		= (1UL << 30),
> +};
>   
>   #define BTRFS_DEFAULT_COMMIT_INTERVAL	(30)
>   #define BTRFS_DEFAULT_MAX_INLINE	(2048)
> 


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 2/2] btrfs: shorten integrity checker extent data mount option
  2021-06-18 14:52 ` [PATCH 2/2] btrfs: shorten integrity checker extent data mount option David Sterba
@ 2021-06-22 10:53   ` Anand Jain
  0 siblings, 0 replies; 5+ messages in thread
From: Anand Jain @ 2021-06-22 10:53 UTC (permalink / raw)
  To: David Sterba, linux-btrfs

On 18/06/2021 22:52, David Sterba wrote:
> Subjectively, CHECK_INTEGRITY_INCLUDING_EXTENT_DATA is quite long and
> calling it CHECK_INTEGRITY_DATA still keeps the meaning and matches the
> mount option name.
> 
> Signed-off-by: David Sterba <dsterba@suse.com>

Reviewed-by: Anand Jain <anand.jain@oracle.com>

Thanks, Anand


> ---
>   fs/btrfs/ctree.h   | 2 +-
>   fs/btrfs/disk-io.c | 3 +--
>   fs/btrfs/super.c   | 5 ++---
>   3 files changed, 4 insertions(+), 6 deletions(-)
> 
> diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
> index e0f6aa6e8bd2..4d156d9e8050 100644
> --- a/fs/btrfs/ctree.h
> +++ b/fs/btrfs/ctree.h
> @@ -1405,7 +1405,7 @@ enum {
>   	BTRFS_MOUNT_USEBACKUPROOT		= (1UL << 17),
>   	BTRFS_MOUNT_SKIP_BALANCE		= (1UL << 18),
>   	BTRFS_MOUNT_CHECK_INTEGRITY		= (1UL << 19),
> -	BTRFS_MOUNT_CHECK_INTEGRITY_INCLUDING_EXTENT_DATA = (1UL << 20),
> +	BTRFS_MOUNT_CHECK_INTEGRITY_DATA	= (1UL << 20),
>   	BTRFS_MOUNT_PANIC_ON_FATAL_ERROR	= (1UL << 21),
>   	BTRFS_MOUNT_RESCAN_UUID_TREE		= (1UL << 22),
>   	BTRFS_MOUNT_FRAGMENT_DATA		= (1UL << 23),
> diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
> index 544bb7a82e57..6eb0010f9c7e 100644
> --- a/fs/btrfs/disk-io.c
> +++ b/fs/btrfs/disk-io.c
> @@ -3598,8 +3598,7 @@ int __cold open_ctree(struct super_block *sb, struct btrfs_fs_devices *fs_device
>   	if (btrfs_test_opt(fs_info, CHECK_INTEGRITY)) {
>   		ret = btrfsic_mount(fs_info, fs_devices,
>   				    btrfs_test_opt(fs_info,
> -					CHECK_INTEGRITY_INCLUDING_EXTENT_DATA) ?
> -				    1 : 0,
> +					CHECK_INTEGRITY_DATA) ? 1 : 0,
>   				    fs_info->check_integrity_print_mask);
>   		if (ret)
>   			btrfs_warn(fs_info,
> diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
> index bc613218c8c5..d07b18b2b250 100644
> --- a/fs/btrfs/super.c
> +++ b/fs/btrfs/super.c
> @@ -934,8 +934,7 @@ int btrfs_parse_options(struct btrfs_fs_info *info, char *options,
>   		case Opt_check_integrity_including_extent_data:
>   			btrfs_info(info,
>   				   "enabling check integrity including extent data");
> -			btrfs_set_opt(info->mount_opt,
> -				      CHECK_INTEGRITY_INCLUDING_EXTENT_DATA);
> +			btrfs_set_opt(info->mount_opt, CHECK_INTEGRITY_DATA);
>   			btrfs_set_opt(info->mount_opt, CHECK_INTEGRITY);
>   			break;
>   		case Opt_check_integrity:
> @@ -1516,7 +1515,7 @@ static int btrfs_show_options(struct seq_file *seq, struct dentry *dentry)
>   	if (btrfs_test_opt(info, SKIP_BALANCE))
>   		seq_puts(seq, ",skip_balance");
>   #ifdef CONFIG_BTRFS_FS_CHECK_INTEGRITY
> -	if (btrfs_test_opt(info, CHECK_INTEGRITY_INCLUDING_EXTENT_DATA))
> +	if (btrfs_test_opt(info, CHECK_INTEGRITY_DATA))
>   		seq_puts(seq, ",check_int_data");
>   	else if (btrfs_test_opt(info, CHECK_INTEGRITY))
>   		seq_puts(seq, ",check_int");
> 


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-06-22 10:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-18 14:52 [PATCH 0/2] Mount option bit definitions cleanups David Sterba
2021-06-18 14:52 ` [PATCH 1/2] btrfs: switch mount option bits to enums and use wider type David Sterba
2021-06-22 10:53   ` Anand Jain
2021-06-18 14:52 ` [PATCH 2/2] btrfs: shorten integrity checker extent data mount option David Sterba
2021-06-22 10:53   ` Anand Jain

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.