changeset 10772:9a5f742f9516

6854659 creating file using O_EXCL with linux nfsv4 client results in bogus mtime
author Jeff A. Smith <Jeff.A.Smith@Sun.Com>
date Mon, 12 Oct 2009 20:23:30 -0500
parents 3f7f1ce8d4ba
children 434ca1ce22f9
files usr/src/uts/common/fs/nfs/nfs4_srv.c
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/usr/src/uts/common/fs/nfs/nfs4_srv.c	Mon Oct 12 17:15:03 2009 -0700
+++ b/usr/src/uts/common/fs/nfs/nfs4_srv.c	Mon Oct 12 20:23:30 2009 -0500
@@ -6339,6 +6339,12 @@
 		cva.va_mtime.tv_nsec = (mtime->tv_nsec / 1000) * 1000;
 		cva.va_mode = (mode_t)0;
 		vap = &cva;
+
+		/*
+		 * For EXCL create, attrset is set to the server attr
+		 * used to cache the client's verifier.
+		 */
+		*attrset = FATTR4_TIME_MODIFY_MASK;
 		break;
 	}