summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_reflink.h
diff options
context:
space:
mode:
authorDarrick J. Wong2016-10-03 18:11:40 +0200
committerDarrick J. Wong2016-10-06 01:26:05 +0200
commit862bb360ef569f625bcf700ae4b162a9c8fa9bba (patch)
treed643c7e7bb8850a33a74cfc8051bda55620b5265 /fs/xfs/xfs_reflink.h
parentxfs: store in-progress CoW allocations in the refcount btree (diff)
downloadkernel-qcow2-linux-862bb360ef569f625bcf700ae4b162a9c8fa9bba.tar.gz
kernel-qcow2-linux-862bb360ef569f625bcf700ae4b162a9c8fa9bba.tar.xz
kernel-qcow2-linux-862bb360ef569f625bcf700ae4b162a9c8fa9bba.zip
xfs: reflink extents from one file to another
Reflink extents from one file to another; that is to say, iteratively remove the mappings from the destination file, copy the mappings from the source file to the destination file, and increment the reference count of all the blocks that got remapped. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'fs/xfs/xfs_reflink.h')
-rw-r--r--fs/xfs/xfs_reflink.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/xfs/xfs_reflink.h b/fs/xfs/xfs_reflink.h
index 1d2f180f9eca..c35ce299281b 100644
--- a/fs/xfs/xfs_reflink.h
+++ b/fs/xfs/xfs_reflink.h
@@ -43,5 +43,7 @@ extern int xfs_reflink_cancel_cow_range(struct xfs_inode *ip, xfs_off_t offset,
extern int xfs_reflink_end_cow(struct xfs_inode *ip, xfs_off_t offset,
xfs_off_t count);
extern int xfs_reflink_recover_cow(struct xfs_mount *mp);
+extern int xfs_reflink_remap_range(struct xfs_inode *src, xfs_off_t srcoff,
+ struct xfs_inode *dest, xfs_off_t destoff, xfs_off_t len);
#endif /* __XFS_REFLINK_H */