Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Jan 2004 18:24:24 -0500 (EST)
From:      Robert Watson <rwatson@FreeBSD.org>
To:        Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?= <des@des.no>
Cc:        cvs-src@FreeBSD.org
Subject:   Re: cvs commit: src/sys/kern kern_descrip.c
Message-ID:  <Pine.NEB.3.96L.1040116182253.81408I-100000@fledge.watson.org>
In-Reply-To: <xzpsmifr0ln.fsf@dwp.des.no>

next in thread | previous in thread | raw e-mail | index | archive | help

On Fri, 16 Jan 2004, Dag-Erling Sm=F8rgrav wrote:

> "Brian F. Feldman" <green@FreeBSD.org> writes:
> > I don't see a reason "newfdp" needs to be locked, since it is not
> > referenced by anything yet.  If "fdp" alone is locked, that is
> > sufficient to ensure they will both be consistent.
>=20
> It needs to be locked because it is passed to functions which assert
> that it is locked.=20

It sounds like this is an API problem, and is probably what we should fix.=
=20
I've found WITNESS an invaluable debugging tool for locking, and when
programming on systems without it, it's a very painful experience (i.e.,
debugging lock orders on Darwin).  You've also pointed out that the extra
locking work being done is actually unnecessary, so maybe we just need an
_unlocked() version of the API, or changes elsewhere?=20

Robert N M Watson             FreeBSD Core Team, TrustedBSD Projects
robert@fledge.watson.org      Senior Research Scientist, McAfee Research




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96L.1040116182253.81408I-100000>