summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2021-09-01 11:14:57 -0700
committerDarrick J. Wong <djwong@kernel.org>2021-10-22 16:40:51 -0700
commitcd2822198dfe5b6f119d7900bc0307a387e253d6 (patch)
tree1e6a7f4a5e3cc3affd4e144d09196ccc113a8915 /fs
parent0c20a38103bdcd61e89a38cec79991dd5ef956fd (diff)
xfs: advertise metadata directory feature
Advertise the existence of the metadata directory feature; this will be used by scrub to decide if it needs to scan the metadir too. Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/xfs/libxfs/xfs_fs.h1
-rw-r--r--fs/xfs/libxfs/xfs_sb.c2
2 files changed, 3 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_fs.h b/fs/xfs/libxfs/xfs_fs.h
index be85fd1d4a12..71d87379b99b 100644
--- a/fs/xfs/libxfs/xfs_fs.h
+++ b/fs/xfs/libxfs/xfs_fs.h
@@ -253,6 +253,7 @@ typedef struct xfs_fsop_resblks {
#define XFS_FSOP_GEOM_FLAGS_BIGTIME (1 << 21) /* 64-bit nsec timestamps */
#define XFS_FSOP_GEOM_FLAGS_INOBTCNT (1 << 22) /* inobt btree counter */
#define XFS_FSOP_GEOM_FLAGS_ATOMIC_SWAP (1 << 23) /* atomic swapext */
+#define XFS_FSOP_GEOM_FLAGS_METADIR (1 << 24) /* metadata directories */
/*
* Minimum and maximum sizes need for growth checks.
diff --git a/fs/xfs/libxfs/xfs_sb.c b/fs/xfs/libxfs/xfs_sb.c
index fb59294c3e6c..387aba2fc714 100644
--- a/fs/xfs/libxfs/xfs_sb.c
+++ b/fs/xfs/libxfs/xfs_sb.c
@@ -1173,6 +1173,8 @@ xfs_fs_geometry(
}
if (xfs_can_atomicswap(mp))
geo->flags |= XFS_FSOP_GEOM_FLAGS_ATOMIC_SWAP;
+ if (xfs_has_metadir(mp))
+ geo->flags |= XFS_FSOP_GEOM_FLAGS_METADIR;
geo->rtsectsize = sbp->sb_blocksize;
geo->dirblocksize = xfs_dir2_dirblock_bytes(sbp);