From owner-cvs-all Wed Jan 24 4:11:28 2001 Delivered-To: cvs-all@freebsd.org Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by hub.freebsd.org (Postfix) with ESMTP id 9438A37B400; Wed, 24 Jan 2001 04:11:05 -0800 (PST) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id XAA29987; Wed, 24 Jan 2001 23:10:59 +1100 Date: Wed, 24 Jan 2001 23:10:51 +1100 (EST) From: Bruce Evans X-Sender: bde@besplex.bde.org To: Alfred Perlstein Cc: John Baldwin , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/isofs/cd9660 cd9660_vfsops.c In-Reply-To: <20010123163418.N26076@fw.wintelcom.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, 23 Jan 2001, Alfred Perlstein wrote: > * John Baldwin [010123 16:26] wrote: > > jhb 2001/01/23 16:26:19 PST > > > > Modified files: > > sys/isofs/cd9660 cd9660_vfsops.c > > Log: > > Proc locking to protect p_ucred while we obtain additional references. > > I really don't think you need the PROC_LOCK for these. > > You only need the 'uc' variable, and even then it's only to protect > against rfork threads playing with setuid which is an inhernent > race condition as p_ucred shouldn't be NULL. (afaik). I don't think you need any locking or crhold()ing for these. I think xxx_mount() is only called with p == curproc, so p_ucred can't change. Unfortunately, most vfs and vnop interfaces including VFS_MOUNT() make it unclear that p == curproc by pretending to support arbitrary p's. > Just give it some more thought, because I'm not sure I'm right > about this. Me too. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message