On Thu, Apr 14, 2022 at 03:54:59PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong <djwong@xxxxxxxxxx> > > Currently, the code that performs CoW remapping after a write has this > odd behavior where it walks /backwards/ through the data fork to remap > extents in reverse order. Earlier, we rewrote the reflink remap > function to use deferred bmap log items instead of trying to cram as > much into the first transaction that we could. Now do the same for the > CoW remap code. There doesn't seem to be any performance impact; we're > just making better use of code that we added for the benefit of reflink. > > Signed-off-by: Darrick J. Wong <djwong@xxxxxxxxxx> > --- > fs/xfs/xfs_reflink.c | 88 ++++++++++++++++++++++++++++++++------------------ > fs/xfs/xfs_trace.h | 3 +- > 2 files changed, 58 insertions(+), 33 deletions(-) Looks ok. Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx> -- Dave Chinner david@xxxxxxxxxxxxx