From: Darrick J. Wong Date: Mon, 15 Apr 2024 23:07:31 +0000 (-0700) Subject: xfs: use xfs_defer_finish_one to finish recovered work items X-Git-Tag: v6.8.0~102 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ea8dad89a9f152f72f6e9f0031705d57244aaace;p=thirdparty%2Fxfsprogs-dev.git xfs: use xfs_defer_finish_one to finish recovered work items Source kernel commit: e5f1a5146ec35f3ed5d7f5ac7807a10c0062b6b8 Get rid of the open-coded calls to xfs_defer_finish_one. This also means that the recovery transaction takes care of cleaning up the dfp, and we have solved (I hope) all the ownership issues in recovery. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Bill O'Donnell --- diff --git a/libxfs/xfs_defer.c b/libxfs/xfs_defer.c index 4900a7d6..4ef9867c 100644 --- a/libxfs/xfs_defer.c +++ b/libxfs/xfs_defer.c @@ -479,7 +479,7 @@ xfs_defer_relog( * Log an intent-done item for the first pending intent, and finish the work * items. */ -static int +int xfs_defer_finish_one( struct xfs_trans *tp, struct xfs_defer_pending *dfp) diff --git a/libxfs/xfs_defer.h b/libxfs/xfs_defer.h index bef5823f..c1a648e9 100644 --- a/libxfs/xfs_defer.h +++ b/libxfs/xfs_defer.h @@ -41,6 +41,7 @@ void xfs_defer_add(struct xfs_trans *tp, enum xfs_defer_ops_type type, struct list_head *h); int xfs_defer_finish_noroll(struct xfs_trans **tp); int xfs_defer_finish(struct xfs_trans **tp); +int xfs_defer_finish_one(struct xfs_trans *tp, struct xfs_defer_pending *dfp); void xfs_defer_cancel(struct xfs_trans *); void xfs_defer_move(struct xfs_trans *dtp, struct xfs_trans *stp);