]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: convert remaining trace points to pass pag structures
authorChristoph Hellwig <hch@lst.de>
Mon, 25 Nov 2024 21:14:13 +0000 (13:14 -0800)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 24 Dec 2024 02:01:23 +0000 (18:01 -0800)
Source kernel commit: c4ae021bcb6bf8bbb329ce8ef947a43009bc2fe4

Convert all tracepoints that take [mp,agno] tuples to take a pag argument
instead so that decoding only happens when tracepoints are enabled and to
clean up the callers.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
include/xfs_trace.h
libxfs/xfs_alloc.c
libxfs/xfs_ialloc.c
libxfs/xfs_inode_util.c

index 0986e1621437d4e22dd33ba2b983cefe2df4f7b3..012e0018cb83672c67be4a891aebb1607ebe1bbd 100644 (file)
 
 #define trace_xfs_free_extent(...)             ((void) 0)
 #define trace_xfs_agf(a,b,c,d)                 ((void) 0)
-#define trace_xfs_read_agf(a,b)                        ((void) 0)
-#define trace_xfs_alloc_read_agf(a,b)          ((void) 0)
-#define trace_xfs_read_agi(a,b)                        ((void) 0)
-#define trace_xfs_ialloc_read_agi(a,b)         ((void) 0)
+#define trace_xfs_read_agf(...)                        ((void) 0)
+#define trace_xfs_alloc_read_agf(...)          ((void) 0)
+#define trace_xfs_read_agi(...)                        ((void) 0)
+#define trace_xfs_ialloc_read_agi(...)         ((void) 0)
 #define trace_xfs_irec_merge_pre(...)          ((void) 0)
 #define trace_xfs_irec_merge_post(...)         ((void) 0)
 
index ed04e40856740bfd8ec733009f97cd01613b7604..bd39bcde0ea224c98b9537c76bcae15e6e92f954 100644 (file)
@@ -3354,7 +3354,7 @@ xfs_read_agf(
        struct xfs_mount        *mp = pag->pag_mount;
        int                     error;
 
-       trace_xfs_read_agf(pag->pag_mount, pag->pag_agno);
+       trace_xfs_read_agf(pag);
 
        error = xfs_trans_read_buf(mp, tp, mp->m_ddev_targp,
                        XFS_AG_DADDR(mp, pag->pag_agno, XFS_AGF_DADDR(mp)),
@@ -3385,7 +3385,7 @@ xfs_alloc_read_agf(
        int                     error;
        int                     allocbt_blks;
 
-       trace_xfs_alloc_read_agf(pag->pag_mount, pag->pag_agno);
+       trace_xfs_alloc_read_agf(pag);
 
        /* We don't support trylock when freeing. */
        ASSERT((flags & (XFS_ALLOC_FLAG_FREEING | XFS_ALLOC_FLAG_TRYLOCK)) !=
index b3d6f7f4212588118520a17182c1aa5dfffc003a..4f087e6b07408146c40865ec9e34c5f847cd0117 100644 (file)
@@ -2724,7 +2724,7 @@ xfs_read_agi(
        struct xfs_mount        *mp = pag->pag_mount;
        int                     error;
 
-       trace_xfs_read_agi(pag->pag_mount, pag->pag_agno);
+       trace_xfs_read_agi(pag);
 
        error = xfs_trans_read_buf(mp, tp, mp->m_ddev_targp,
                        XFS_AG_DADDR(mp, pag->pag_agno, XFS_AGI_DADDR(mp)),
@@ -2755,7 +2755,7 @@ xfs_ialloc_read_agi(
        struct xfs_agi          *agi;
        int                     error;
 
-       trace_xfs_ialloc_read_agi(pag->pag_mount, pag->pag_agno);
+       trace_xfs_ialloc_read_agi(pag);
 
        error = xfs_read_agi(pag, tp,
                        (flags & XFS_IALLOC_FLAG_TRYLOCK) ? XBF_TRYLOCK : 0,
index 92bfdf0715f02ef05ca5ff958e716d1416ac1611..f9f16c7e2d0788e69ad8a8923befbe5be8e1515f 100644 (file)
@@ -439,8 +439,8 @@ xfs_iunlink_update_bucket(
        ASSERT(xfs_verify_agino_or_null(pag, new_agino));
 
        old_value = be32_to_cpu(agi->agi_unlinked[bucket_index]);
-       trace_xfs_iunlink_update_bucket(tp->t_mountp, pag->pag_agno, bucket_index,
-                       old_value, new_agino);
+       trace_xfs_iunlink_update_bucket(pag, bucket_index, old_value,
+                       new_agino);
 
        /*
         * We should never find the head of the list already set to the value