Re: [PATCH v8 04/41] btrfs: Check and enable ZONED mode

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

 



On Fri, Oct 02, 2020 at 03:36:11AM +0900, Naohiro Aota wrote:
> --- a/fs/btrfs/ctree.h
> +++ b/fs/btrfs/ctree.h
> @@ -588,6 +588,9 @@ struct btrfs_fs_info {
>  	struct btrfs_root *free_space_root;
>  	struct btrfs_root *data_reloc_root;
>  
> +	/* Zone size when in ZONED mode */
> +	u64 zone_size;

I think this could be reused to avoid the lengthy

	if (btrfs_fs_incompat(fs_info, ZONED))

to do

	if (fs_info->zoned)

In order to keep the semantics of both an anonymouns union should work:

	union {
		u64 zone_size;
		u64 zone;
	};

and the existing usage of zone_size can be kept intact.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux