summaryrefslogtreecommitdiffstats
path: root/fs/xfs/scrub/repair.h
diff options
context:
space:
mode:
authorDarrick J. Wong <darrick.wong@oracle.com>2018-05-30 07:18:10 +0200
committerDarrick J. Wong <darrick.wong@oracle.com>2018-05-30 17:03:14 +0200
commit12c6510e2ff17cf94cae08ba7b6d2355760dfd1d (patch)
tree1d76ee415983bf1ede5b078c1a2ecd529560fd86 /fs/xfs/scrub/repair.h
parentxfs: add helpers to collect and sift btree block pointers during repair (diff)
downloadlinux-12c6510e2ff17cf94cae08ba7b6d2355760dfd1d.tar.xz
linux-12c6510e2ff17cf94cae08ba7b6d2355760dfd1d.zip
xfs: add helpers to dispose of old btree blocks after a repair
Now that we've plumbed in the ability to construct a list of dead btree blocks following a repair, add more helpers to dispose of them. This is done by examining the rmapbt -- if the btree was the only owner we can free the block, otherwise it's crosslinked and we can only remove the rmapbt record. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/scrub/repair.h')
-rw-r--r--fs/xfs/scrub/repair.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/xfs/scrub/repair.h b/fs/xfs/scrub/repair.h
index ba1fdd7b9a79..f14aaab7df9e 100644
--- a/fs/xfs/scrub/repair.h
+++ b/fs/xfs/scrub/repair.h
@@ -70,6 +70,12 @@ void xfs_repair_cancel_btree_extents(struct xfs_scrub_context *sc,
int xfs_repair_subtract_extents(struct xfs_scrub_context *sc,
struct xfs_repair_extent_list *exlist,
struct xfs_repair_extent_list *sublist);
+int xfs_repair_fix_freelist(struct xfs_scrub_context *sc, bool can_shrink);
+int xfs_repair_invalidate_blocks(struct xfs_scrub_context *sc,
+ struct xfs_repair_extent_list *btlist);
+int xfs_repair_reap_btree_extents(struct xfs_scrub_context *sc,
+ struct xfs_repair_extent_list *exlist,
+ struct xfs_owner_info *oinfo, enum xfs_ag_resv_type type);
/* Metadata repairers */