From owner-svn-src-all@FreeBSD.ORG Sun Jul 18 22:35:46 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8B1F1106566B; Sun, 18 Jul 2010 22:35:46 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7A8CA8FC12; Sun, 18 Jul 2010 22:35:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o6IMZkZv081274; Sun, 18 Jul 2010 22:35:46 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o6IMZkvN081273; Sun, 18 Jul 2010 22:35:46 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201007182235.o6IMZkvN081273@svn.freebsd.org> From: Rick Macklem Date: Sun, 18 Jul 2010 22:35:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r210227 - head/sys/fs/nfsclient X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Jul 2010 22:35:46 -0000 Author: rmacklem Date: Sun Jul 18 22:35:46 2010 New Revision: 210227 URL: http://svn.freebsd.org/changeset/base/210227 Log: Add a call to nfscl_mustflush() in nfs_close() of the experimental NFSv4 client, so that attributes are not acquired from the server when a delegation for the file is held. This can reduce the number of Getattr Ops significantly. MFC after: 2 weeks Modified: head/sys/fs/nfsclient/nfs_clvnops.c Modified: head/sys/fs/nfsclient/nfs_clvnops.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clvnops.c Sun Jul 18 20:57:53 2010 (r210226) +++ head/sys/fs/nfsclient/nfs_clvnops.c Sun Jul 18 22:35:46 2010 (r210227) @@ -709,7 +709,7 @@ nfs_close(struct vop_close_args *ap) /* * Get attributes so "change" is up to date. */ - if (!error) { + if (error == 0 && nfscl_mustflush(vp)) { ret = nfsrpc_getattr(vp, cred, ap->a_td, &nfsva, NULL); if (!ret) {