Subject: Re: CVS commit: src/sys
To: Chuck Silvers <firstname.lastname@example.org>
From: Bill Studenmund <email@example.com>
Date: 12/27/2005 18:46:21
Content-Type: text/plain; charset=us-ascii
On Tue, Dec 27, 2005 at 05:20:26PM -0800, Bill Studenmund wrote:
> On Tue, Dec 27, 2005 at 03:54:15PM -0800, Chuck Silvers wrote:
> > On Tue, Dec 27, 2005 at 03:37:58PM -0800, Bill Studenmund wrote:
> > > On Tue, Dec 27, 2005 at 02:49:24PM -0800, Chuck Silvers wrote:
> > > > I'm also suspicious of this change. this change doesn't seem relat=
> > > > to the purpose given in the check-in comment, is it? if you really=
> > > > to reduce the amount of duplicate code, why not just split it into
> > > > multiple functions?
> > >=20
> > > A separate checkin might have been good. However at this point, a "cv=
> > > admin -m" will probably be enough to fix things up. I agree we should=
> > > this change, but I don't think it's so bad to include it.
> > if the purpose is to reduce the amount of duplicate code, why not just =
> > the function into multiple functions rather than changing the requireme=
> > of VOP_INACTIVE() in subtle ways?
> I'm sorry, I don't think it is changing the semantics of VOP_INACTIVE().=
> It took me a while to figure that out, but the only times one of these=20
> vrele()s would call VOP_INACTIVE() is: 1) if the vnode were revoked, in=
> which case we send the call is handed by deadfs. 2) if the vnode has been=
Sorry, that should have been "in which case we send the call to deadfs".
> reused and the reusing thread has already called vrele(). In the latter=
> case, we _should_ call VOP_INACTIVE(), as the new user has let the vnode=
> go back onto the free list. In the former case, I think we will do the=20
> same call to deadfs we would do otherwise; right now if you VOP_REVOKE() =
> vnode, there will be a vrele() call that will VOP_INACTIVE() on deadfs.
> So I think the semantics are the same.
> Actually, the change closes a small window of error. In the reuse case, i=
> the vget() call happens after the new user has already vrele()'d the node=
> the old code would skip a VOP_INACTIVE() call that would of happened had=
> the vget() code not held a reference.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)
-----END PGP SIGNATURE-----