On Tue, Oct 15, 2024 at 01:43:01PM +1100, Dave Chinner wrote: > On Mon, Oct 14, 2024 at 06:21:21PM -0700, Darrick J. Wong wrote: > > On Tue, Oct 15, 2024 at 12:08:56PM +1100, Dave Chinner wrote: > > > On Thu, Oct 10, 2024 at 05:46:48PM -0700, Darrick J. Wong wrote: > > > > From: Christoph Hellwig <hch@xxxxxx> > > > > > > > > Prepare for tracking busy RT extents by passing the generic group > > > > structure to the xfs_extent_busy_class tracepoints. > > > > > > > > Signed-off-by: Christoph Hellwig <hch@xxxxxx> > > > > Reviewed-by: Darrick J. Wong <djwong@xxxxxxxxxx> > > > > Signed-off-by: Darrick J. Wong <djwong@xxxxxxxxxx> > > > > Reviewed-by: Darrick J. Wong <djwong@xxxxxxxxxx> > > > > Signed-off-by: Darrick J. Wong <djwong@xxxxxxxxxx> > > > > --- > > > > fs/xfs/xfs_extent_busy.c | 12 +++++++----- > > > > fs/xfs/xfs_trace.h | 34 +++++++++++++++++++++------------- > > > > 2 files changed, 28 insertions(+), 18 deletions(-) > > > > > > Subject is basically the same as the next patch - swap "busy" > > > and "extent" and they are the same. Perhaps this should be > > > called "Convert extent busy trace points to generic groups". > > > > Done. > > > > > > diff --git a/fs/xfs/xfs_extent_busy.c b/fs/xfs/xfs_extent_busy.c > > > > index 2806fc6ab4800d..ff10307702f011 100644 > > > > --- a/fs/xfs/xfs_extent_busy.c > > > > +++ b/fs/xfs/xfs_extent_busy.c > > > > @@ -41,7 +41,7 @@ xfs_extent_busy_insert_list( > > > > new->flags = flags; > > > > > > > > /* trace before insert to be able to see failed inserts */ > > > > - trace_xfs_extent_busy(pag, bno, len); > > > > + trace_xfs_extent_busy(&pag->pag_group, bno, len); > > > > > > > > spin_lock(&pag->pagb_lock); > > > > rbp = &pag->pagb_tree.rb_node; > > > > @@ -278,13 +278,13 @@ xfs_extent_busy_update_extent( > > > > ASSERT(0); > > > > } > > > > > > > > - trace_xfs_extent_busy_reuse(pag, fbno, flen); > > > > + trace_xfs_extent_busy_reuse(&pag->pag_group, fbno, flen); > > > > return true; > > > > > > > > out_force_log: > > > > spin_unlock(&pag->pagb_lock); > > > > xfs_log_force(pag_mount(pag), XFS_LOG_SYNC); > > > > - trace_xfs_extent_busy_force(pag, fbno, flen); > > > > + trace_xfs_extent_busy_force(&pag->pag_group, fbno, flen); > > > > spin_lock(&pag->pagb_lock); > > > > return false; > > > > } > > > > @@ -496,7 +496,8 @@ xfs_extent_busy_trim( > > > > out: > > > > > > > > if (fbno != *bno || flen != *len) { > > > > - trace_xfs_extent_busy_trim(args->pag, *bno, *len, fbno, flen); > > > > + trace_xfs_extent_busy_trim(&args->pag->pag_group, *bno, *len, > > > > + fbno, flen); > > > > > > Also, the more I see this sort of convert, the more I want to see a > > > pag_group(args->pag) helper to match with stuff like pag_mount() and > > > pag_agno().... > > > > Me too. I'll schedule /that/ transition for tomorrow, along with the > > patch folding that hch asked for. > > > > I'm gonna assume you also want an rtg_group() that does the same for > > rtgroups? > > I hadn't got that far yet, but I think that's probably a good idea. Ok will do. --D > -Dave. > -- > Dave Chinner > david@xxxxxxxxxxxxx >