From owner-cvs-all@FreeBSD.ORG Sat Aug 19 15:03:35 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02E4616A4DA; Sat, 19 Aug 2006 15:03:35 +0000 (UTC) (envelope-from netchild@FreeBSD.org) Received: from www.ebusiness-leidinger.de (jojo.ms-net.de [84.16.236.246]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5025643D45; Sat, 19 Aug 2006 15:03:34 +0000 (GMT) (envelope-from netchild@FreeBSD.org) Received: from Andro-Beta.Leidinger.net (p54A5F524.dip.t-dialin.net [84.165.245.36]) (authenticated bits=0) by www.ebusiness-leidinger.de (8.13.6/8.13.6) with ESMTP id k7JEkVkZ003083; Sat, 19 Aug 2006 16:46:32 +0200 (CEST) (envelope-from netchild@FreeBSD.org) Received: from Magellan.Leidinger.net (Magellan.Leidinger.net [192.168.1.1]) by Andro-Beta.Leidinger.net (8.13.4/8.13.3) with ESMTP id k7JF3cvI084587; Sat, 19 Aug 2006 17:03:38 +0200 (CEST) (envelope-from netchild@FreeBSD.org) Date: Sat, 19 Aug 2006 17:05:44 +0200 From: Alexander Leidinger To: Robert Watson Message-ID: <20060819170544.118d2c2b@Magellan.Leidinger.net> In-Reply-To: <20060818184107.B47942@fledge.watson.org> References: <200608172121.k7HLLUY5095480@repoman.freebsd.org> <20060818184107.B47942@fledge.watson.org> Organization: FreeBSD X-Mailer: Sylpheed-Claws 2.4.0 (GTK+ 2.8.20; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new Cc: cvs-src@FreeBSD.org, rdivacky@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/compat/linux linux_misc.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Aug 2006 15:03:35 -0000 Quoting Robert Watson (Fri, 18 Aug 2006 18:47:12 +0100 (BST)): > > On Thu, 17 Aug 2006, Alexander Leidinger wrote: > > > - protect td->td_proc->p_pid with the proc lock in linux_getpid > > in the amd64 (= non i386) case [1] > > Is this necessary? In principle, td->td_proc is static for a live thread > bound to a process (i.e., in a system call, which the current thread > presumable is, as long as td == curthread), p_pid is static for a live process > that isn't exiting (so in a system call is not generally exiting). The native > FreeBSD getpid() only acquires the process lock when following p_pptr, since > this can change during a system call (i.e., as a result of the parent dying, > and the child being re-parented to init(8)). Now that you tell me this, I have the impression that I have mixed up p_pid with p_pptr here... I have to have a look at the code again. Bye, Alexander. -- ...and that is how we know the Earth to be banana-shaped. http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137