xfs: flag empty xattr leaf blocks for optimization
authorDarrick J. Wong <djwong@kernel.org>
Mon, 15 Apr 2024 21:54:47 +0000 (14:54 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Mon, 15 Apr 2024 21:58:54 +0000 (14:58 -0700)
commit40190f9f918aaf3355c8f777e6e658ea3bf77870
treef707e3f8435f3b2c2e004d16176ad629ae03acd5
parent0ee230dec2626ef25dc96abd47b84494f9c251e3
xfs: flag empty xattr leaf blocks for optimization

Empty xattr leaf blocks at offset zero are a waste of space but
otherwise harmless.  If we encounter one, flag it as an opportunity for
optimization.

If we encounter empty attr leaf blocks anywhere else in the attr fork,
that's corruption.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/scrub/attr.c
fs/xfs/scrub/dabtree.h