]> 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)
commitfb5f957d18072b31eab0c9cedb0a7ca1078a1beb
treecc07999d8751035b2e78b521c59be85f6e8ca842
parent3d2ca42184f31d36b9cec79dc090f58b5ddf73c3
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