diff options
| author | Rick Macklem <rmacklem@FreeBSD.org> | 2010-08-25 22:19:52 +0000 |
|---|---|---|
| committer | Rick Macklem <rmacklem@FreeBSD.org> | 2010-08-25 22:19:52 +0000 |
| commit | b2568d6da750468e9d91699b18924da8b7981557 (patch) | |
| tree | 1ed5554e08e9e071eb58f0df54414e18e47c9197 /sys/nfsclient/nfs_node.c | |
| parent | 18a8823f9ee12c218bcb8c3a50f67a2792f33ced (diff) | |
Notes
Diffstat (limited to 'sys/nfsclient/nfs_node.c')
| -rw-r--r-- | sys/nfsclient/nfs_node.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/nfsclient/nfs_node.c b/sys/nfsclient/nfs_node.c index 522bc445c19c..947beed82675 100644 --- a/sys/nfsclient/nfs_node.c +++ b/sys/nfsclient/nfs_node.c @@ -193,12 +193,14 @@ nfs_inactive(struct vop_inactive_args *ap) np = VTONFS(ap->a_vp); if (prtactive && vrefcnt(ap->a_vp) != 0) vprint("nfs_inactive: pushing active", ap->a_vp); + mtx_lock(&np->n_mtx); if (ap->a_vp->v_type != VDIR) { sp = np->n_sillyrename; np->n_sillyrename = NULL; } else sp = NULL; if (sp) { + mtx_unlock(&np->n_mtx); (void)nfs_vinvalbuf(ap->a_vp, 0, td, 1); /* * Remove the silly file that was rename'd earlier @@ -207,8 +209,10 @@ nfs_inactive(struct vop_inactive_args *ap) crfree(sp->s_cred); vrele(sp->s_dvp); free((caddr_t)sp, M_NFSREQ); + mtx_lock(&np->n_mtx); } np->n_flag &= NMODIFIED; + mtx_unlock(&np->n_mtx); return (0); } |
