summaryrefslogtreecommitdiffstats
path: root/fs/xfs/scrub/findparent.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/scrub/findparent.c')
-rw-r--r--fs/xfs/scrub/findparent.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/fs/xfs/scrub/findparent.c b/fs/xfs/scrub/findparent.c
index 712dd73e4789..c78422ad757b 100644
--- a/fs/xfs/scrub/findparent.c
+++ b/fs/xfs/scrub/findparent.c
@@ -238,9 +238,10 @@ xrep_findparent_live_update(
* will be called when there is a dotdot update for the inode being repaired.
*/
int
-xrep_findparent_scan_start(
+__xrep_findparent_scan_start(
struct xfs_scrub *sc,
- struct xrep_parent_scan_info *pscan)
+ struct xrep_parent_scan_info *pscan,
+ notifier_fn_t custom_fn)
{
int error;
@@ -262,7 +263,10 @@ xrep_findparent_scan_start(
* ILOCK, which means that any in-progress inode updates will finish
* before we can scan the inode.
*/
- xfs_dir_hook_setup(&pscan->dhook, xrep_findparent_live_update);
+ if (custom_fn)
+ xfs_dir_hook_setup(&pscan->dhook, custom_fn);
+ else
+ xfs_dir_hook_setup(&pscan->dhook, xrep_findparent_live_update);
error = xfs_dir_hook_add(sc->mp, &pscan->dhook);
if (error)
goto out_iscan;