svn commit: r207350 - head/sys/fs/nfsclient

Rick Macklem rmacklem at FreeBSD.org
Wed Apr 28 23:16:21 UTC 2010


Author: rmacklem
Date: Wed Apr 28 23:16:21 2010
New Revision: 207350
URL: http://svn.freebsd.org/changeset/base/207350

Log:
  For the experimental NFS client, it should always flush dirty
  buffers before closing the NFSv4 opens, as the comment states.
  This patch deletes the call to nfscl_mustflush() which would
  return 0 for the case where a delegation still exists, which
  was incorrect and could cause crashes during recovery from
  an expired lease.
  
  MFC after:	1 week

Modified:
  head/sys/fs/nfsclient/nfs_clnode.c

Modified: head/sys/fs/nfsclient/nfs_clnode.c
==============================================================================
--- head/sys/fs/nfsclient/nfs_clnode.c	Wed Apr 28 23:05:42 2010	(r207349)
+++ head/sys/fs/nfsclient/nfs_clnode.c	Wed Apr 28 23:16:21 2010	(r207350)
@@ -198,8 +198,7 @@ ncl_inactive(struct vop_inactive_args *a
 		 * must be flushed before the close, so that the stateid is
 		 * available for the writes.
 		 */
-		if (nfscl_mustflush(vp))
-			(void) ncl_flush(vp, MNT_WAIT, NULL, ap->a_td, 1, 0);
+		(void) ncl_flush(vp, MNT_WAIT, NULL, ap->a_td, 1, 0);
 		(void) nfsrpc_close(vp, 1, ap->a_td);
 	}
 


More information about the svn-src-all mailing list