mbox series

[0/4] btrfs-progs: zoned: fix mkfs failure on various zone size

Message ID 20220406014313.993961-1-naohiro.aota@wdc.com (mailing list archive)
Headers show
Series btrfs-progs: zoned: fix mkfs failure on various zone size | expand

Message

Naohiro Aota April 6, 2022, 1:43 a.m. UTC
There are mkfs.btrfs failures on various zone sizes. For example, with 32
MB zone size, mkfs.btrfs creates the initial system block group at 64 MB,
which collides with the regular superblock location. This series addresses
the issues.

Patches 1 and 2 fix the location of the initial system block group when the
zone size is 32 MB.

Patch 3 fixes the location of the initial data block group when the zone
size is 16 MB.

Patch 4 fixes a bug revealed by patch 3.

Naohiro Aota (4):
  btrfs-progs: zoned: export sb_zone_number() and related constants
  btrfs-progs: zoned: fix initial system BG location
  btrfs-progs: fix ordering of hole_size setting and
    dev_extent_hole_check()
  btrfs-progs: zoned: fix and simplify dev_extent_hole_check_zoned()

 kernel-shared/volumes.c | 32 ++++++++++----------------------
 kernel-shared/zoned.c   | 33 ---------------------------------
 kernel-shared/zoned.h   | 33 +++++++++++++++++++++++++++++++++
 mkfs/common.c           | 30 +++++++++++++++++++++++++++++-
 4 files changed, 72 insertions(+), 56 deletions(-)

Comments

David Sterba April 8, 2022, 8:24 p.m. UTC | #1
On Wed, Apr 06, 2022 at 10:43:09AM +0900, Naohiro Aota wrote:
> There are mkfs.btrfs failures on various zone sizes. For example, with 32
> MB zone size, mkfs.btrfs creates the initial system block group at 64 MB,
> which collides with the regular superblock location. This series addresses
> the issues.
> 
> Patches 1 and 2 fix the location of the initial system block group when the
> zone size is 32 MB.
> 
> Patch 3 fixes the location of the initial data block group when the zone
> size is 16 MB.
> 
> Patch 4 fixes a bug revealed by patch 3.
> 
> Naohiro Aota (4):
>   btrfs-progs: zoned: export sb_zone_number() and related constants
>   btrfs-progs: zoned: fix initial system BG location
>   btrfs-progs: fix ordering of hole_size setting and
>     dev_extent_hole_check()
>   btrfs-progs: zoned: fix and simplify dev_extent_hole_check_zoned()

Added to devel, thanks.