linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Oleg Drokin <green@linuxhacker.ru>
Cc: Andreas Dilger <adilger@sun.com>, linux-fsdevel@vger.kernel.org
Subject: Re: Attempt at "stat light" implementation
Date: Tue, 7 Apr 2009 13:52:38 -0400	[thread overview]
Message-ID: <20090407175238.GB24424@infradead.org> (raw)
In-Reply-To: <12974D21-AAD4-44D2-A014-C0C27986AF11@linuxhacker.ru>

On Tue, Apr 07, 2009 at 10:54:31AM -0400, Oleg Drokin wrote:
>> In the end it DOES seem that fstatat(2) is a sufficient interface for
>> this:
>>
>>       int fstatat(int dirfd, const char *pathname, struct stat *buf,
>> 		   int flags);
>> since it is working on the directory and passing in the filenames
>> for each file.  There is even a AT_SYMLINK_NOFOLLOW to avoid the
>> need to have a separate "l" version.
>
> I thought about it, but unless we would allow userspace to pass in
> the magic AT_FDCWD, they would still would need to open something
> even if only once per run (and probably once per dir, to avoid
> extra lookup overhead), and that is probably not very desirable.

AT_FDCWD is part of the Posix-specified *at interface and can be passed
in from userspace since day1.  Apropos Posix, you should probably talk
to Uli Drepper about exposing these things in glibc and possibly
standardizing it through Austin group (or whatever replaced it)

  reply	other threads:[~2009-04-07 17:52 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-07  6:23 Attempt at "stat light" implementation Oleg Drokin
2009-04-07 10:23 ` Andreas Dilger
2009-04-07 14:54   ` Oleg Drokin
2009-04-07 17:52     ` Christoph Hellwig [this message]
2009-04-07 15:22   ` jim owens
2009-04-07 15:38     ` Oleg Drokin
2009-04-07 16:20       ` jim owens
2009-04-07 17:32 ` Jamie Lokier
2009-04-07 17:38   ` Jeff Garzik
2009-04-07 17:56     ` Jamie Lokier
2009-04-07 18:21       ` Andreas Dilger
2009-04-07 19:30         ` Ulrich Drepper
2009-04-12 20:55           ` Jamie Lokier
2009-04-07 17:41   ` Oleg Drokin
2009-04-07 17:54     ` Jamie Lokier
2009-04-07 18:00       ` Oleg Drokin
2009-04-07 18:18     ` Andreas Dilger
2009-04-07 18:31     ` Nicholas Miell
2009-04-07 17:49 ` Christoph Hellwig
2009-04-07 17:56   ` Oleg Drokin
2009-04-07 18:28     ` Andreas Dilger
2009-04-07 18:50       ` Jamie Lokier
2009-04-07 19:48       ` Jeff Garzik
2009-04-07 19:47   ` Jeff Garzik
2009-04-07 20:18 ` Evgeniy Polyakov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090407175238.GB24424@infradead.org \
    --to=hch@infradead.org \
    --cc=adilger@sun.com \
    --cc=green@linuxhacker.ru \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).