From owner-freebsd-current@FreeBSD.ORG Fri May 7 20:03:57 2004 Return-Path: Delivered-To: freebsd-current@www.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B076816A4CE for ; Fri, 7 May 2004 20:03:57 -0700 (PDT) Received: from smtp01.syd.iprimus.net.au (smtp01.syd.iprimus.net.au [210.50.30.52]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1004D43D39 for ; Fri, 7 May 2004 20:03:57 -0700 (PDT) (envelope-from tim@robbins.dropbear.id.au) Received: from robbins.dropbear.id.au (210.50.216.161) by smtp01.syd.iprimus.net.au (7.0.024) id 409956B400100313; Sat, 8 May 2004 13:03:24 +1000 Received: by robbins.dropbear.id.au (Postfix, from userid 1000) id 1176D41E5; Sat, 8 May 2004 13:02:58 +1000 (EST) Date: Sat, 8 May 2004 13:02:58 +1000 From: Tim Robbins To: Bruce M Simpson Message-ID: <20040508030258.GA19512@cat.robbins.dropbear.id.au> References: <20040507092235.GA61837@stack.nl> <20040507100119.GA15782@cat.robbins.dropbear.id.au> <20040507235556.GB37035@empiric.dek.spc.org> <20040508010228.GA18935@cat.robbins.dropbear.id.au> <20040508012357.GA37547@empiric.dek.spc.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040508012357.GA37547@empiric.dek.spc.org> User-Agent: Mutt/1.4.1i cc: Marc Olzheim cc: Poul-Henning Kamp cc: freebsd-current@www.freebsd.org Subject: Re: Unified getcwd() implementation X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 May 2004 03:03:57 -0000 On Sat, May 08, 2004 at 02:23:57AM +0100, Bruce M Simpson wrote: > On Sat, May 08, 2004 at 11:02:28AM +1000, Tim Robbins wrote: > > It's not inherently Linux-specific, but it exists solely for the benefit > > of Linux emulation. I don't see why they need to be merged at the > > expense of complicating the native system calls -- we have way > > too many tentacles of the Linux emulator reaching in there already. > > Sorry, what you are saying here doesn't seem to make sense to me. > The implementation of getcwd() in the Linux emulator is a full getcwd() > implementation. I did not claim otherwise. > The whole point of reverting to directory scanning rather than using the > namecache is to address the problems caused when path components can't be > found in the namecache; this is the ethos of the patch, which eliminates > the duplicated functionality in the Linuxulator at the same time. When path components are not found in the namecache, getcwd() (in libc) will find the directory the old-fashioned way by walking ".." links. > I don't understand how this 'complicates native system calls' when it's > intended to address several PRs which exist with regards to our current > implementation of getcwd() in FreeBSD, unless there is something I'm missing? I don't see how it differs from what we already do in userland. Tim