diff options
author | Christoph Hellwig <hch@lst.de> | 2016-10-20 15:50:07 +1100 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2016-10-20 15:50:07 +1100 |
commit | 5faaf4fa0a20d38edc4df57baf24ea35b7e91178 (patch) | |
tree | 04fbdf80c31a03ec499bc5628cd0454f128420c4 /fs/xfs/xfs_reflink.h | |
parent | ec40759902556f21f37641ad9f19d02c4dd4b555 (diff) | |
download | linux-5faaf4fa0a20d38edc4df57baf24ea35b7e91178.tar.gz linux-5faaf4fa0a20d38edc4df57baf24ea35b7e91178.tar.bz2 linux-5faaf4fa0a20d38edc4df57baf24ea35b7e91178.zip |
xfs: merge xfs_reflink_remap_range and xfs_file_share_range
There is no clear division of responsibility between those functions, so
just merge them into one to keep the code simple. Also move
xfs_file_wait_for_io to xfs_reflink.c together with its only caller.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
Diffstat (limited to 'fs/xfs/xfs_reflink.h')
-rw-r--r-- | fs/xfs/xfs_reflink.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/xfs/xfs_reflink.h b/fs/xfs/xfs_reflink.h index 5dc3c8ac12aa..7ddd9f69560d 100644 --- a/fs/xfs/xfs_reflink.h +++ b/fs/xfs/xfs_reflink.h @@ -43,11 +43,8 @@ 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); -#define XFS_REFLINK_DEDUPE 1 /* only reflink if contents match */ -#define XFS_REFLINK_ALL (XFS_REFLINK_DEDUPE) -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, - unsigned int flags); +extern int xfs_reflink_remap_range(struct file *file_in, loff_t pos_in, + struct file *file_out, loff_t pos_out, u64 len, bool is_dedupe); extern int xfs_reflink_clear_inode_flag(struct xfs_inode *ip, struct xfs_trans **tpp); extern int xfs_reflink_unshare(struct xfs_inode *ip, xfs_off_t offset, |