summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkris <kris@FreeBSD.org>2006-01-28 03:06:35 +0000
committerkris <kris@FreeBSD.org>2006-01-28 03:06:35 +0000
commita70f9992d4d20ade14008ebc80a7b04f20f54a8e (patch)
treeb16b4a540157c456023ee753d4ab8883c99e7715
parent93d466e244c9ef833fd40b7fbf0f42f74110b2f0 (diff)
downloadFreeBSD-src-a70f9992d4d20ade14008ebc80a7b04f20f54a8e.zip
FreeBSD-src-a70f9992d4d20ade14008ebc80a7b04f20f54a8e.tar.gz
Back out r1.653; it turns out that the race (or at least the printf) is
actually not hard to trigger, and it can cause a lot of console spam. Approved by: kan
-rw-r--r--sys/kern/vfs_subr.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
index c7b7621..21876e7 100644
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -1920,7 +1920,6 @@ vget( struct vnode *vp, int flags, struct thread *td)
{
int oweinact;
int oldflags;
- int usecount;
int error;
error = 0;
@@ -1942,7 +1941,6 @@ vget( struct vnode *vp, int flags, struct thread *td)
flags |= LK_EXCLUSIVE;
oweinact = 1;
}
- usecount = vp->v_usecount;
v_incr_usecount(vp);
if ((error = vn_lock(vp, flags | LK_INTERLOCK, td)) != 0) {
VI_LOCK(vp);
@@ -1953,24 +1951,6 @@ vget( struct vnode *vp, int flags, struct thread *td)
* active.
*/
v_decr_usecount(vp);
- /*
- * Print warning when race below occur:
- *
- * thread1 thread2
- * ------- -------
- * v_usecount=0
- * vref(vp) v_usecount=1
- * vget(vp)
- * v_incr_usecount(vp) v_usecount=2
- * vn_lock(vp)
- * vrele(vp) v_usecount=1
- * v_decr_usecount(vp) v_usecount=0
- *
- * In such situation VOP_INACTIVE() will not be called for
- * the vnode vp.
- */
- if (usecount > 0 && vp->v_usecount == 0)
- printf("vinactive() won't be called for vp=%p\n", vp);
return (error);
}
if (vp->v_iflag & VI_DOOMED && (flags & LK_RETRY) == 0)
OpenPOWER on IntegriCloud