]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs_scrub: ignore freed inodes when single-stepping during phase 3
authorDarrick J. Wong <djwong@kernel.org>
Mon, 24 Feb 2025 18:21:44 +0000 (10:21 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 25 Feb 2025 17:15:57 +0000 (09:15 -0800)
commit20dbdd616162b0a8503437f0f8ebda4f786a9714
tree32a8f6e1487cc3a2934d848e2f16e9a5e468bb2c
parentb0289f631ca96347020fbca05ebf5297c8889f10
xfs_scrub: ignore freed inodes when single-stepping during phase 3

For inodes that inumbers told us were allocated but weren't loaded by
the bulkstat call, we fall back to loading bulkstat data one inode at a
time to try to find the inodes that are too corrupt to load.

However, there are a couple of outcomes of the single bulkstat call that
clearly indicate that the inode is free, not corrupt.  In this case, the
phase 3 inode scan will try to scrub the inode, only to be told ENOENT
because it doesn't exist.

As an optimization here, don't increment ocount, just move on to the
next inode in the mask.

Signed-off-by: "Darrick J. Wong" <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
scrub/inodes.c