]> www.infradead.org Git - users/hch/xfsprogs.git/commitdiff
xfs_spaceman: report health of the realtime refcount btree
authorDarrick J. Wong <djwong@kernel.org>
Wed, 3 Jul 2024 21:22:33 +0000 (14:22 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 31 Jul 2024 01:46:59 +0000 (18:46 -0700)
Report the health of the realtime reference count btree.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
spaceman/health.c

index 7dec61f39670014843887a2e3bce4ccb40fca6bb..ee0e108d5b2d6d06919ec24b15e08713a95ee0db 100644 (file)
@@ -46,6 +46,11 @@ static bool has_rtrmapbt(const struct xfs_fsop_geom *g)
        return g->rtblocks > 0 && (g->flags & XFS_FSOP_GEOM_FLAGS_RMAPBT);
 }
 
+static bool has_rtreflink(const struct xfs_fsop_geom *g)
+{
+       return g->rtblocks > 0 && (g->flags & XFS_FSOP_GEOM_FLAGS_REFLINK);
+}
+
 struct flag_map {
        unsigned int            mask;
        bool                    (*has_fn)(const struct xfs_fsop_geom *g);
@@ -151,6 +156,11 @@ static const struct flag_map rtgroup_flags[] = {
                .descr = "realtime reverse mappings btree",
                .has_fn = has_rtrmapbt,
        },
+       {
+               .mask = XFS_RTGROUP_GEOM_SICK_REFCNTBT,
+               .descr = "realtime reference count btree",
+               .has_fn = has_rtreflink,
+       },
        {0},
 };