Commit ca247c89 authored by Trond Myklebust's avatar Trond Myklebust
Browse files

NFSv4.2: Serialise O_DIRECT i/o and copy range



Ensure that all O_DIRECT reads and writes complete before copying a file
range, so that the destination is up to date.

Fixes: a5864c99 ("NFS: Do not serialise O_DIRECT reads and writes")
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent c80ebeba
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -445,6 +445,7 @@ static ssize_t _nfs42_proc_copy(struct file *src,
		return status;
	}

	nfs_file_block_o_direct(NFS_I(dst_inode));
	status = nfs_sync_inode(dst_inode);
	if (status)
		return status;