summaryrefslogtreecommitdiffstats
path: root/fs/xfs/libxfs/xfs_ag.c
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2024-02-22 12:43:40 -0800
committerDarrick J. Wong <djwong@kernel.org>2024-02-22 12:43:40 -0800
commit7e1b84b24d257700e417bc9cd724c1efdff653d7 (patch)
tree01cd17c635ebe6685c152823e2d7c2ced2c4cd03 /fs/xfs/libxfs/xfs_ag.c
parent4787fc802752c9b73b28ff18860c0560bf4337f2 (diff)
downloadlinux-stable-7e1b84b24d257700e417bc9cd724c1efdff653d7.tar.gz
linux-stable-7e1b84b24d257700e417bc9cd724c1efdff653d7.tar.bz2
linux-stable-7e1b84b24d257700e417bc9cd724c1efdff653d7.zip
xfs: hook live rmap operations during a repair operation
Hook the regular rmap code when an rmapbt repair operation is running so that we can unlock the AGF buffer to scan the filesystem and keep the in-memory btree up to date during the scan. Signed-off-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/libxfs/xfs_ag.c')
-rw-r--r--fs/xfs/libxfs/xfs_ag.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_ag.c b/fs/xfs/libxfs/xfs_ag.c
index 32d80a76440c..d728709054b2 100644
--- a/fs/xfs/libxfs/xfs_ag.c
+++ b/fs/xfs/libxfs/xfs_ag.c
@@ -417,6 +417,7 @@ xfs_initialize_perag(
init_waitqueue_head(&pag->pag_active_wq);
pag->pagb_count = 0;
pag->pagb_tree = RB_ROOT;
+ xfs_hooks_init(&pag->pag_rmap_update_hooks);
#endif /* __KERNEL__ */
error = xfs_buf_cache_init(&pag->pag_bcache);