From owner-freebsd-current Thu Jul 12 1:58:29 2001 Delivered-To: freebsd-current@freebsd.org Received: from rina.r.dl.itc.u-tokyo.ac.jp (cvsup2.r.dl.itc.u-tokyo.ac.jp [133.11.199.247]) by hub.freebsd.org (Postfix) with ESMTP id AEF7937B401; Thu, 12 Jul 2001 01:58:24 -0700 (PDT) (envelope-from tanimura@r.dl.itc.u-tokyo.ac.jp) Received: from rina.r.dl.itc.u-tokyo.ac.jp (localhost [127.0.0.1]) by rina.r.dl.itc.u-tokyo.ac.jp (8.11.3+3.4W/3.7W-rina.r-20010412) with ESMTP id f6C8wGt38858 ; Thu, 12 Jul 2001 17:58:17 +0900 (JST) Message-Id: <200107120858.f6C8wGt38858@rina.r.dl.itc.u-tokyo.ac.jp> Date: Thu, 12 Jul 2001 17:58:15 +0900 From: Seigo Tanimura To: bright@sneakerz.org Cc: tanimura@r.dl.itc.u-tokyo.ac.jp, jake@FreeBSD.org, jhb@FreeBSD.org, current@FreeBSD.org Subject: Re: Lock of struct filedesc, file, pgrp, session and sigio In-Reply-To: In your message of "Thu, 12 Jul 2001 01:44:44 -0500" <20010712014442.E2449@sneakerz.org> References: <200106040748.f547mUD53783@rina.r.dl.itc.u-tokyo.ac.jp> <200106181004.f5IA4VD63112@rina.r.dl.itc.u-tokyo.ac.jp> <200107020812.f628CfK44241@rina.r.dl.itc.u-tokyo.ac.jp> <20010707164249.C88962@sneakerz.org> <20010709032044.B1894@sneakerz.org> <200107100845.f6A8jqt99404@rina.r.dl.itc.u-tokyo.ac.jp> <20010710035347.Q1894@sneakerz.org> <200107100903.f6A93et02367@rina.r.dl.itc.u-tokyo.ac.jp> <200107111137.f6BBbQt22812@rina.r.dl.itc.u-tokyo.ac.jp> <20010712014205.D2449@sneakerz.org> <20010712014442.E2449@sneakerz.org> User-Agent: Wanderlust/1.1.1 (Purple Rain) SEMI/1.13.7 (Awazu) FLIM/1.13.2 (Kasanui) MULE XEmacs/21.1 (patch 14) (Cuyahoga Valley) (i386--freebsd) Organization: Digital Library Research Division, Information Techinology Centre, The University of Tokyo MIME-Version: 1.0 (generated by SEMI 1.13.7 - "Awazu") Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 12 Jul 2001 01:44:44 -0500, Alfred Perlstein said: Alfred> * Alfred Perlstein [010712 01:42] wrote: >> * Seigo Tanimura [010711 19:08] wrote: >> > >> > The patch and the results of build test are now on the web page. >> > >> > The discussion of ktrace(2) problem does not cover the solution of >> > BSD/OS, so it needs updating. >> >> I'm just reviewing the file stuff, I have a number of updates mainly >> in the areas of needing FFIND_HOLD/fdrop rather than just a simple >> FFIND. >> >> getvnode(p->p_fd, args->fd, &fp); >> >> I'm quite sure should implicitly do a FHOLD operation on the returned >> struct file, i don't see this, at least not in linux_getdents() >> (compat/linux/linux_file.c). Alfred> Or at least an fhold needs to be done before relasing the lock Alfred> on the struct file. Some functions modify a file descriptor, while others do not. At that point, what we need is a pair of FFIND and FFIND_LOCK. Both of them hold a file descriptor. FFIND_LOCK locks a file descriptor, while FFIND does not. -- Seigo Tanimura To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message