xfs: use accessor functions for bitmap words
authorDarrick J. Wong <djwong@kernel.org>
Mon, 16 Oct 2023 16:49:01 +0000 (09:49 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 18 Oct 2023 18:46:19 +0000 (11:46 -0700)
commit97e993830a1cdd86ad7d207308b9f55a00660edd
tree36f4292ce96f5a738de9cb50bad045c6e42bb004
parent312d61021b8947446aa9ec80b78b9230e8cb3691
xfs: use accessor functions for bitmap words

Create get and set functions for rtbitmap words so that we can redefine
the ondisk format with a specific endianness.  Note that this requires
the definition of a distinct type for ondisk rtbitmap words so that the
compiler can perform proper typechecking as we go back and forth.

In the upcoming rtgroups feature, we're going to fix the problem that
rtwords are written in host endian order, which means we'll need the
distinct rtword/rtword_raw types.

Suggested-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_format.h
fs/xfs/libxfs/xfs_rtbitmap.c
fs/xfs/libxfs/xfs_rtbitmap.h
fs/xfs/xfs_ondisk.h