Commit 9026b3a9 authored by Darrick J. Wong's avatar Darrick J. Wong Committed by Trond Myklebust

nfs: disable client side deduplication

The NFS protocol doesn't support deduplication, so turn it off again.

Fixes: ce96e888 ("Fix nfs4.2 return -EINVAL when do dedupe operation")
Signed-off-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent 1a7441b2
...@@ -187,7 +187,11 @@ static loff_t nfs42_remap_file_range(struct file *src_file, loff_t src_off, ...@@ -187,7 +187,11 @@ static loff_t nfs42_remap_file_range(struct file *src_file, loff_t src_off,
bool same_inode = false; bool same_inode = false;
int ret; int ret;
if (remap_flags & ~(REMAP_FILE_DEDUP | REMAP_FILE_ADVISORY)) /* NFS does not support deduplication. */
if (remap_flags & REMAP_FILE_DEDUP)
return -EOPNOTSUPP;
if (remap_flags & ~REMAP_FILE_ADVISORY)
return -EINVAL; return -EINVAL;
/* check alignment w.r.t. clone_blksize */ /* check alignment w.r.t. clone_blksize */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment