]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
crimson/zns: manage zone size, capacity and device size 46755/head
authorAravind Ramesh <Aravind.Ramesh@wdc.com>
Wed, 13 Jul 2022 09:26:58 +0000 (14:56 +0530)
committerAravind Ramesh <Aravind.Ramesh@wdc.com>
Tue, 26 Jul 2022 11:34:11 +0000 (17:04 +0530)
commitda260f3797b44071608c6e7147ad53344de718c1
tree27b819d5f293999b2505567071a2e8d3160e086d
parentaa7317e42059204cb58efb79d5ab26dcbe8c3dd4
crimson/zns: manage zone size, capacity and device size

zone_size and zone_capacity are reported in 512B sectors by the
kernel. Update the superblock correctly with zone size/capacity
in bytes.
Currently we are using stat() to get the device size, but it
fails on block devices to get the size. Use BLKGETSIZE ioctl
to get the actual size of the zns device in sectors and convert
to bytes.

Signed-off-by: Aravind Ramesh <aravind.ramesh@wdc.com>
src/crimson/os/seastore/segment_manager/zns.cc
src/crimson/os/seastore/segment_manager/zns.h