svn commit: r353098 - projects/nfsv42/sys/fs/nfsclient

Rick Macklem rmacklem at FreeBSD.org
Fri Oct 4 05:02:40 UTC 2019


Author: rmacklem
Date: Fri Oct  4 05:02:39 2019
New Revision: 353098
URL: https://svnweb.freebsd.org/changeset/base/353098

Log:
  Fix the comment in the NFSv4.2 client copy_file_range.
  
  Fix the comment so that it correctly explains why both files are flushed
  before doing the Copy operation.

Modified:
  projects/nfsv42/sys/fs/nfsclient/nfs_clvnops.c

Modified: projects/nfsv42/sys/fs/nfsclient/nfs_clvnops.c
==============================================================================
--- projects/nfsv42/sys/fs/nfsclient/nfs_clvnops.c	Fri Oct  4 04:57:36 2019	(r353097)
+++ projects/nfsv42/sys/fs/nfsclient/nfs_clvnops.c	Fri Oct  4 05:02:39 2019	(r353098)
@@ -3585,8 +3585,9 @@ nfs_copy_file_range(struct vop_copy_file_range_args *a
 	error = vn_rlimit_fsize(outvp, &io, ap->a_fsizetd);
 
 	/*
-	 * Flush all writes for both files, so they will be up to date
-	 * on the server before doing the copy.
+	 * Flush the input file so that the data is up to date before
+	 * the copy.  Flush writes for the output file so that they
+	 * do not overwrite the data copied to the output file by the Copy.
 	 */
 	if (error == 0)
 		error = ncl_flush(invp, MNT_WAIT, curthread, 1, 0);


More information about the svn-src-projects mailing list