diff options
author | jhb <jhb@FreeBSD.org> | 2001-01-27 00:01:31 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2001-01-27 00:01:31 +0000 |
commit | b6baa60b1e807d09641c20b2ff1fe838ddebbd3b (patch) | |
tree | 81781cbbf3ad98f73e64d11188dfe3084b844e12 /sys/fs/coda/coda_vfsops.c | |
parent | 0c5b7b7672ac24978496b6d8b72a9f4c74349b64 (diff) | |
download | FreeBSD-src-b6baa60b1e807d09641c20b2ff1fe838ddebbd3b.zip FreeBSD-src-b6baa60b1e807d09641c20b2ff1fe838ddebbd3b.tar.gz |
Back out proc locking to protect p_ucred for obtaining additional
references along with the actual obtaining of additional references.
Diffstat (limited to 'sys/fs/coda/coda_vfsops.c')
-rw-r--r-- | sys/fs/coda/coda_vfsops.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/sys/fs/coda/coda_vfsops.c b/sys/fs/coda/coda_vfsops.c index 0708181..0496ea5 100644 --- a/sys/fs/coda/coda_vfsops.c +++ b/sys/fs/coda/coda_vfsops.c @@ -292,7 +292,6 @@ coda_root(vfsp, vpp) int error; struct proc *p = curproc; /* XXX - bnoble */ ViceFid VFid; - struct ucred* uc; ENTRY; MARK_ENTRY(CODA_ROOT_STATS); @@ -316,12 +315,7 @@ coda_root(vfsp, vpp) } } - PROC_LOCK(p); - uc = p->p_ucred; - crhold(uc); - PROC_UNLOCK(p); - error = venus_root(vftomi(vfsp), uc, p, &VFid); - crfree(uc); + error = venus_root(vftomi(vfsp), p->p_ucred, p, &VFid); if (!error) { /* @@ -447,7 +441,6 @@ coda_fhtovp(vfsp, fhp, nam, vpp, exflagsp, creadanonp) int error; struct proc *p = curproc; /* XXX -mach */ ViceFid VFid; - struct ucred *uc; int vtype; ENTRY; @@ -461,12 +454,7 @@ coda_fhtovp(vfsp, fhp, nam, vpp, exflagsp, creadanonp) return(0); } - PROC_LOCK(p); - uc = p->p_ucred; - crhold(uc); - PROC_UNLOCK(p); - error = venus_fhtovp(vftomi(vfsp), &cfid->cfid_fid, uc, p, &VFid, &vtype); - crfree(uc); + error = venus_fhtovp(vftomi(vfsp), &cfid->cfid_fid, p->p_ucred, p, &VFid, &vtype); if (error) { CODADEBUG(CODA_VGET, myprintf(("vget error %d\n",error));) |