From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeff Garzik Subject: Re: Attempt at "stat light" implementation Date: Tue, 07 Apr 2009 15:48:40 -0400 Message-ID: <49DBAE18.20406@garzik.org> References: <20090407062356.GA1336463@fiona.linuxhacker.ru> <20090407174921.GA24424@infradead.org> <1C8AF5C3-0509-43E2-BFC3-075DCCA49717@linuxhacker.ru> <20090407182809.GX3204@webber.adilger.int> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Oleg Drokin , Christoph Hellwig , linux-fsdevel@vger.kernel.org To: Andreas Dilger Return-path: Received: from srv5.dvmed.net ([207.36.208.214]:49046 "EHLO mail.dvmed.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759058AbZDGTsp (ORCPT ); Tue, 7 Apr 2009 15:48:45 -0400 In-Reply-To: <20090407182809.GX3204@webber.adilger.int> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Andreas Dilger wrote: > On Apr 07, 2009 13:56 -0400, Oleg Drokin wrote: >> On Apr 7, 2009, at 1:49 PM, Christoph Hellwig wrote: >>> I think the best way to do it is to just define additional flags for >>> *statat family, that if present only request partial stat information. >> But having to open every dir (or take an extra intermediate lookup hit) >> might be a bad thing at times unless we officially allow to use a >> "magic" > "AT_FDCWD". What's your opinion on this? > > Generally, any application doing tree traversal will have the parent > directory open doing readdir() or getdents() so I don't think that is > a huge problem. And if that application does not have a directory open, it is vulnerable to races... Jeff