svn commit: r233325 - in stable/8/sys: i386/conf nfsclient

John Baldwin jhb at FreeBSD.org
Thu Mar 22 20:52:01 UTC 2012


Author: jhb
Date: Thu Mar 22 20:52:00 2012
New Revision: 233325
URL: http://svn.freebsd.org/changeset/base/233325

Log:
  MFC 232116:
  Adjust the nfs_skip_wcc_data_onerr setting so that it does not block
  post-op attributes for ENOENT errors now that the name caching logic
  depends on working post-op attributes.

Modified:
  stable/8/sys/nfsclient/nfs_krpc.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/boot/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/e1000/   (props changed)
  stable/8/sys/i386/conf/XENHVM   (props changed)

Modified: stable/8/sys/nfsclient/nfs_krpc.c
==============================================================================
--- stable/8/sys/nfsclient/nfs_krpc.c	Thu Mar 22 20:51:35 2012	(r233324)
+++ stable/8/sys/nfsclient/nfs_krpc.c	Thu Mar 22 20:52:00 2012	(r233325)
@@ -603,13 +603,15 @@ tryagain:
 		if (error == ESTALE)
 			nfs_purgecache(vp);
 		/*
-		 * Skip wcc data on NFS errors for now.  NetApp filers
-		 * return corrupt postop attrs in the wcc data for NFS
-		 * err EROFS.  Not sure if they could return corrupt
-		 * postop attrs for others errors.
+		 * Skip wcc data on non-ENOENT NFS errors for now.
+		 * NetApp filers return corrupt postop attrs in the
+		 * wcc data for NFS err EROFS.  Not sure if they could
+		 * return corrupt postop attrs for others errors.
+		 * Blocking ENOENT post-op attributes breaks negative
+		 * name caching, so always allow it through.
 		 */
 		if ((nmp->nm_flag & NFSMNT_NFSV3) &&
-		    !nfs_skip_wcc_data_onerr) {
+		    (!nfs_skip_wcc_data_onerr || error == ENOENT)) {
 			*mrp = mrep;
 			*mdp = md;
 			*dposp = dpos;


More information about the svn-src-all mailing list