diff options
author | Darrick J. Wong <djwong@kernel.org> | 2024-04-22 19:48:05 +0300 |
---|---|---|
committer | Darrick J. Wong <djwong@kernel.org> | 2024-04-23 17:47:03 +0300 |
commit | 77ede5f44b0d86c2ec812442846f512884009766 (patch) | |
tree | 3eb3b5850649190c24320581f76395620873935f /fs/xfs/scrub/trace.c | |
parent | 8ad345306d1eba337a3b88f9acbe762f9e770f76 (diff) | |
download | linux-77ede5f44b0d86c2ec812442846f512884009766.tar.xz |
xfs: walk directory parent pointers to determine backref count
If the filesystem has parent pointers enabled, walk the parent pointers
of subdirectories to determine the true backref count. In theory each
subdir should have a single parent reachable via dotdot, but in the case
of (corrupt) subdirs with multiple parents, we need to keep the link
counts high enough that the directory loop detector will be able to
correct the multiple parents problems.
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/scrub/trace.c')
-rw-r--r-- | fs/xfs/scrub/trace.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/xfs/scrub/trace.c b/fs/xfs/scrub/trace.c index b2ce7b22cad3..4a8cc2c98d99 100644 --- a/fs/xfs/scrub/trace.c +++ b/fs/xfs/scrub/trace.c @@ -19,6 +19,7 @@ #include "xfs_da_format.h" #include "xfs_dir2.h" #include "xfs_rmap.h" +#include "xfs_parent.h" #include "scrub/scrub.h" #include "scrub/xfile.h" #include "scrub/xfarray.h" |