]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: rewrite xfs_reflink_end_cow to use intents
authorDarrick J. Wong <djwong@kernel.org>
Tue, 26 Apr 2022 01:38:15 +0000 (18:38 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 28 Apr 2022 17:25:50 +0000 (10:25 -0700)
commit7d0daaf0d793558cfd47aabc3490475b8cef5f7f
treecc07999d8751035b2e78b521c59be85f6e8ca842
parent53cd13a8e9409ac7b8e50af544072f1d582182cf
xfs: rewrite xfs_reflink_end_cow to use intents

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@kernel.org>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/xfs_reflink.c
fs/xfs/xfs_trace.h