]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
libxfs: refactor the fs_topology structure
authorChristoph Hellwig <hch@lst.de>
Mon, 15 Apr 2024 23:07:46 +0000 (16:07 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 17 Apr 2024 21:06:27 +0000 (14:06 -0700)
commitf35e15ee6139f9f82d89f6c420606cd2e93d9303
treecfc2b55848d9ef2c8f95ba93a74d8e096d60218a
parent2cfab496d998371fa914963b9d3b325d5ff0657d
libxfs: refactor the fs_topology structure

fs_topology is a mess that mixes up data and RT device reporting,
and to make things worse reuses lsectorsize for the logical sector
size while other parts of xfsprogs use it for the log sector size.

Split out a device_topology structure that reports the topology for
one device and embedded two of them into the fs_topology struture,
and pass them directly to blkid_get_topology.

Rename the sector size members to be more explicit, and move some
of the sanity checking from mkfs into the topology helpers.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
libxfs/topology.c
libxfs/topology.h
mkfs/xfs_mkfs.c
repair/sb.c