]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: scrub directory parent pointers
authorDarrick J. Wong <darrick.wong@oracle.com>
Fri, 17 Nov 2017 04:11:32 +0000 (22:11 -0600)
committerEric Sandeen <sandeen@redhat.com>
Fri, 17 Nov 2017 04:11:32 +0000 (22:11 -0600)
Source kernel commit: 0f28b25731f76feda1ec71671754a2b7179ee1ef

Scrub parent pointers, sort of.  For directories, we can ride the
'..' entry up to the parent to confirm that there's at most one
dentry that points back to this directory.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_fs.h

index 181209f5ccad2bb41af9d6956596a9f21fbc584b..a3dd1a5edc5c3ecb8c9fa833177122ea2b435b8e 100644 (file)
@@ -522,9 +522,10 @@ struct xfs_scrub_metadata {
 #define XFS_SCRUB_TYPE_DIR     15      /* directory */
 #define XFS_SCRUB_TYPE_XATTR   16      /* extended attribute */
 #define XFS_SCRUB_TYPE_SYMLINK 17      /* symbolic link */
+#define XFS_SCRUB_TYPE_PARENT  18      /* parent pointers */
 
 /* Number of scrub subcommands. */
-#define XFS_SCRUB_TYPE_NR      18
+#define XFS_SCRUB_TYPE_NR      19
 
 /* i: Repair this metadata. */
 #define XFS_SCRUB_IFLAG_REPAIR         (1 << 0)