summaryrefslogtreecommitdiff
path: root/fs/xfs/libxfs/xfs_defer.h
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2023-11-22 11:13:03 -0800
committerDarrick J. Wong <djwong@kernel.org>2023-12-06 18:45:15 -0800
commite70fb328d5277297ea2d9169a3a046de6412d777 (patch)
treef4359168cf1c5207c23c3594951a8a531475d49c /fs/xfs/libxfs/xfs_defer.h
parentdeb4cd8ba87f17b12c72b3827820d9c703e9fd95 (diff)
xfs: recreate work items when recovering intent items
Recreate work items for each xfs_defer_pending object when we are recovering intent items. Signed-off-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/libxfs/xfs_defer.h')
-rw-r--r--fs/xfs/libxfs/xfs_defer.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_defer.h b/fs/xfs/libxfs/xfs_defer.h
index 5dce938ba3d5..bef5823f61fb 100644
--- a/fs/xfs/libxfs/xfs_defer.h
+++ b/fs/xfs/libxfs/xfs_defer.h
@@ -130,6 +130,15 @@ void xfs_defer_start_recovery(struct xfs_log_item *lip,
void xfs_defer_cancel_recovery(struct xfs_mount *mp,
struct xfs_defer_pending *dfp);
+static inline void
+xfs_defer_add_item(
+ struct xfs_defer_pending *dfp,
+ struct list_head *work)
+{
+ list_add_tail(work, &dfp->dfp_work);
+ dfp->dfp_count++;
+}
+
int __init xfs_defer_init_item_caches(void);
void xfs_defer_destroy_item_caches(void);