summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarrick J. Wong <djwong@kernel.org>2022-07-14 11:15:53 -0700
committerDarrick J. Wong <djwong@kernel.org>2022-10-14 14:17:20 -0700
commitbb707e6ee69770854c9969def3b8f66498b1c649 (patch)
tree3aa4e9fc5981ff0b0a16c3c758b71a396ed39c42
parent0b4d41a564f5b3a6b841c00ffa5fb98a97e32e79 (diff)
xfs: remove xfs_trans_set_refcount_flagsrefcount-intent-cleanups_2022-10-14
Remove this single-use helper. Signed-off-by: Darrick J. Wong <djwong@kernel.org>
-rw-r--r--fs/xfs/xfs_refcount_item.c32
1 files changed, 12 insertions, 20 deletions
diff --git a/fs/xfs/xfs_refcount_item.c b/fs/xfs/xfs_refcount_item.c
index d58d9d0c434b..e4b418a7a32c 100644
--- a/fs/xfs/xfs_refcount_item.c
+++ b/fs/xfs/xfs_refcount_item.c
@@ -289,25 +289,6 @@ xfs_refcount_update_diff_items(
XFS_FSB_TO_AGNO(mp, rb->ri_startblock);
}
-/* Set the phys extent flags for this reverse mapping. */
-static void
-xfs_trans_set_refcount_flags(
- struct xfs_phys_extent *refc,
- enum xfs_refcount_intent_type type)
-{
- refc->pe_flags = 0;
- switch (type) {
- case XFS_REFCOUNT_INCREASE:
- case XFS_REFCOUNT_DECREASE:
- case XFS_REFCOUNT_ALLOC_COW:
- case XFS_REFCOUNT_FREE_COW:
- refc->pe_flags |= type;
- break;
- default:
- ASSERT(0);
- }
-}
-
/* Log refcount updates in the intent item. */
STATIC void
xfs_refcount_update_log_item(
@@ -331,7 +312,18 @@ xfs_refcount_update_log_item(
ext = &cuip->cui_format.cui_extents[next_extent];
ext->pe_startblock = refc->ri_startblock;
ext->pe_len = refc->ri_blockcount;
- xfs_trans_set_refcount_flags(ext, refc->ri_type);
+ switch (refc->ri_type) {
+ case XFS_REFCOUNT_INCREASE:
+ case XFS_REFCOUNT_DECREASE:
+ case XFS_REFCOUNT_ALLOC_COW:
+ case XFS_REFCOUNT_FREE_COW:
+ ext->pe_flags = refc->ri_type;
+ break;
+ default:
+ ASSERT(0);
+ ext->pe_flags = 0;
+ break;
+ }
}
static struct xfs_log_item *