svn commit: r265470 - stable/10/sys/fs/nfsclient
Rick Macklem
rmacklem at FreeBSD.org
Tue May 6 21:59:49 UTC 2014
Author: rmacklem
Date: Tue May 6 21:59:48 2014
New Revision: 265470
URL: http://svnweb.freebsd.org/changeset/base/265470
Log:
MFC: r264738
For an NFSv4 mount with the "nocto" option, don't get the
up to date file attributes upon close. This reduces the
Getattr RPC count by about 65% for software builds.
Modified:
stable/10/sys/fs/nfsclient/nfs_clvnops.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/fs/nfsclient/nfs_clvnops.c
==============================================================================
--- stable/10/sys/fs/nfsclient/nfs_clvnops.c Tue May 6 21:54:52 2014 (r265469)
+++ stable/10/sys/fs/nfsclient/nfs_clvnops.c Tue May 6 21:59:48 2014 (r265470)
@@ -768,7 +768,9 @@ nfs_close(struct vop_close_args *ap)
/*
* Get attributes so "change" is up to date.
*/
- if (error == 0 && nfscl_mustflush(vp) != 0) {
+ if (error == 0 && nfscl_mustflush(vp) != 0 &&
+ vp->v_type == VREG &&
+ (VFSTONFS(vp->v_mount)->nm_flag & NFSMNT_NOCTO) == 0) {
ret = nfsrpc_getattr(vp, cred, ap->a_td, &nfsva,
NULL);
if (!ret) {
More information about the svn-src-stable
mailing list