]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit - repair/dinode.c
xfs_repair: support more than INT_MAX block maps
authorDarrick J. Wong <djwong@kernel.org>
Mon, 15 Apr 2024 23:07:51 +0000 (16:07 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 17 Apr 2024 21:06:28 +0000 (14:06 -0700)
commit90ee2c3a94511da87929989a06199fd537c94db4
tree1dbc7646f97c5e6c356cc94021291785eed57e72
parent585a1f78971bd0559fb51505eddc4f67f3bcb49d
xfs_repair: support more than INT_MAX block maps

Now that it's possible to have more than INT_MAX block mappings attached
to a file fork, expand the counters used by this data structure so that
it can support all possible block mappings.

Note that in practice we're still never going to exceed 4 billion
extents because the previous patch switched off the block mappings for
regular files.  This is still twice as much as memory as previous, but
it's not totally unconstrained.  Hopefully few people bloat the xattr
structures that large.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
repair/bmap.c
repair/bmap.h
repair/dinode.c
repair/dir2.c