Skip to content

Commit ca247c8

Browse files
author
Trond Myklebust
committed
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: a5864c9 ("NFS: Do not serialise O_DIRECT reads and writes") Signed-off-by: Trond Myklebust <[email protected]>
1 parent c80ebeb commit ca247c8

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fs/nfs/nfs42proc.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,7 @@ static ssize_t _nfs42_proc_copy(struct file *src,
445445
return status;
446446
}
447447

448+
nfs_file_block_o_direct(NFS_I(dst_inode));
448449
status = nfs_sync_inode(dst_inode);
449450
if (status)
450451
return status;

0 commit comments

Comments
 (0)