Date: Wed, 24 Jan 2001 04:34:38 -0800 (PST) From: John Baldwin <jhb@FreeBSD.org> To: Bruce Evans <bde@zeta.org.au> Cc: cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org, Alfred Perlstein <bright@wintelcom.net> Subject: Re: cvs commit: src/sys/isofs/cd9660 cd9660_vfsops.c Message-ID: <XFMail.010124043438.jhb@FreeBSD.org> In-Reply-To: <Pine.BSF.4.21.0101242229170.44683-100000@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 24-Jan-01 Bruce Evans wrote: > On Tue, 23 Jan 2001, Alfred Perlstein wrote: > >> * John Baldwin <jhb@FreeBSD.org> [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. Yes, Alfred and I talked this out over the phone today. I will be backing out these ucred changes and not committing any more of them. I'm also going to be revisiting calcru() very soon as well. >> Just give it some more thought, because I'm not sure I'm right >> about this. > > Me too. > > Bruce -- John Baldwin <jhb@FreeBSD.org> -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.Baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.010124043438.jhb>