From owner-svn-src-stable-10@freebsd.org Sat Apr 29 01:04:41 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 974E8D52826; Sat, 29 Apr 2017 01:04:41 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6969E1FA0; Sat, 29 Apr 2017 01:04:41 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v3T14evl061664; Sat, 29 Apr 2017 01:04:40 GMT (envelope-from rmacklem@FreeBSD.org) Received: (from rmacklem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v3T14eBv061660; Sat, 29 Apr 2017 01:04:40 GMT (envelope-from rmacklem@FreeBSD.org) Message-Id: <201704290104.v3T14eBv061660@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rmacklem set sender to rmacklem@FreeBSD.org using -f From: Rick Macklem Date: Sat, 29 Apr 2017 01:04:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r317579 - in stable/10/sys/fs: nfs nfsclient X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Apr 2017 01:04:41 -0000 Author: rmacklem Date: Sat Apr 29 01:04:39 2017 New Revision: 317579 URL: https://svnweb.freebsd.org/changeset/base/317579 Log: MFC: r316829 Remove unused "cred" argument to ncl_flush(). The "cred" argument of ncl_flush() is unused and it was confusing to have the code passing in NULL for this argument in some cases. This patch deletes this argument. There is no semantic change because of this patch. Modified: stable/10/sys/fs/nfs/nfs_var.h stable/10/sys/fs/nfsclient/nfs_clnode.c stable/10/sys/fs/nfsclient/nfs_clstate.c stable/10/sys/fs/nfsclient/nfs_clvnops.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/fs/nfs/nfs_var.h ============================================================================== --- stable/10/sys/fs/nfs/nfs_var.h Sat Apr 29 00:53:17 2017 (r317578) +++ stable/10/sys/fs/nfs/nfs_var.h Sat Apr 29 01:04:39 2017 (r317579) @@ -592,7 +592,7 @@ int nfscl_maperr(NFSPROC_T *, int, uid_t void nfscl_init(void); /* nfs_clbio.c */ -int ncl_flush(vnode_t, int, struct ucred *, NFSPROC_T *, int, int); +int ncl_flush(vnode_t, int, NFSPROC_T *, int, int); /* nfs_clnode.c */ void ncl_invalcaches(vnode_t); Modified: stable/10/sys/fs/nfsclient/nfs_clnode.c ============================================================================== --- stable/10/sys/fs/nfsclient/nfs_clnode.c Sat Apr 29 00:53:17 2017 (r317578) +++ stable/10/sys/fs/nfsclient/nfs_clnode.c Sat Apr 29 01:04:39 2017 (r317579) @@ -250,7 +250,7 @@ ncl_inactive(struct vop_inactive_args *a } else retv = TRUE; if (retv == TRUE) { - (void)ncl_flush(vp, MNT_WAIT, NULL, ap->a_td, 1, 0); + (void)ncl_flush(vp, MNT_WAIT, ap->a_td, 1, 0); (void)nfsrpc_close(vp, 1, ap->a_td); } } Modified: stable/10/sys/fs/nfsclient/nfs_clstate.c ============================================================================== --- stable/10/sys/fs/nfsclient/nfs_clstate.c Sat Apr 29 00:53:17 2017 (r317578) +++ stable/10/sys/fs/nfsclient/nfs_clstate.c Sat Apr 29 01:04:39 2017 (r317579) @@ -3878,8 +3878,7 @@ nfscl_recalldeleg(struct nfsclclient *cl if ((dp->nfsdl_flags & NFSCLDL_WRITE) && (np->n_flag & NMODIFIED)) { np->n_flag |= NDELEGRECALL; NFSUNLOCKNODE(np); - ret = ncl_flush(vp, MNT_WAIT, cred, p, 1, - called_from_renewthread); + ret = ncl_flush(vp, MNT_WAIT, p, 1, called_from_renewthread); NFSLOCKNODE(np); np->n_flag &= ~NDELEGRECALL; } Modified: stable/10/sys/fs/nfsclient/nfs_clvnops.c ============================================================================== --- stable/10/sys/fs/nfsclient/nfs_clvnops.c Sat Apr 29 00:53:17 2017 (r317578) +++ stable/10/sys/fs/nfsclient/nfs_clvnops.c Sat Apr 29 01:04:39 2017 (r317579) @@ -721,12 +721,12 @@ nfs_close(struct vop_close_args *ap) * traditional vnode locking implemented for Vnode Ops. */ int cm = newnfs_commit_on_close ? 1 : 0; - error = ncl_flush(vp, MNT_WAIT, cred, ap->a_td, cm, 0); + error = ncl_flush(vp, MNT_WAIT, ap->a_td, cm, 0); /* np->n_flag &= ~NMODIFIED; */ } else if (NFS_ISV4(vp)) { if (nfscl_mustflush(vp) != 0) { int cm = newnfs_commit_on_close ? 1 : 0; - error = ncl_flush(vp, MNT_WAIT, cred, ap->a_td, + error = ncl_flush(vp, MNT_WAIT, ap->a_td, cm, 0); /* * as above w.r.t races when clearing @@ -2629,7 +2629,7 @@ nfs_fsync(struct vop_fsync_args *ap) */ return (0); } - return (ncl_flush(ap->a_vp, ap->a_waitfor, NULL, ap->a_td, 1, 0)); + return (ncl_flush(ap->a_vp, ap->a_waitfor, ap->a_td, 1, 0)); } /* @@ -2641,7 +2641,7 @@ nfs_fsync(struct vop_fsync_args *ap) * waiting for a buffer write to complete. */ int -ncl_flush(struct vnode *vp, int waitfor, struct ucred *cred, struct thread *td, +ncl_flush(struct vnode *vp, int waitfor, struct thread *td, int commit, int called_from_renewthread) { struct nfsnode *np = VTONFS(vp); @@ -3022,7 +3022,7 @@ nfs_advlock(struct vop_advlock_args *ap) if (ap->a_op == F_UNLCK && nfscl_checkwritelocked(vp, ap->a_fl, cred, td, ap->a_id, ap->a_flags)) - (void) ncl_flush(vp, MNT_WAIT, cred, td, 1, 0); + (void) ncl_flush(vp, MNT_WAIT, td, 1, 0); /* * Loop around doing the lock op, while a blocking lock