]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
libxfs: add a realtime flag to the bmap update log redo items
authorDarrick J. Wong <djwong@kernel.org>
Mon, 22 Apr 2024 17:01:15 +0000 (10:01 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Mon, 3 Jun 2024 18:37:41 +0000 (11:37 -0700)
Extend the bmap update (BUI) log items with a new realtime flag that
indicates that the updates apply against a realtime file's data fork.
We'll wire up the actual code later.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
libxfs/defer_item.c

index fdb922f08c39d80591da7b8b98e0040eb9578ecb..21dd1d0f416e1ab8f6b097d8ec6a9fcbb3741d86 100644 (file)
@@ -490,6 +490,9 @@ xfs_bmap_update_get_group(
 {
        xfs_agnumber_t          agno;
 
+       if (xfs_ifork_is_realtime(bi->bi_owner, bi->bi_whichfork))
+               return;
+
        agno = XFS_FSB_TO_AGNO(mp, bi->bi_bmap.br_startblock);
 
        /*
@@ -519,10 +522,13 @@ static inline void
 xfs_bmap_update_put_group(
        struct xfs_bmap_intent  *bi)
 {
+       if (xfs_ifork_is_realtime(bi->bi_owner, bi->bi_whichfork))
+               return;
+
        xfs_perag_intent_put(bi->bi_pag);
 }
 
-/* Cancel a deferred rmap update. */
+/* Cancel a deferred bmap update. */
 STATIC void
 xfs_bmap_update_cancel_item(
        struct list_head                *item)