[PATCH 02/18] xstat: Add a pair of system calls to make extended file stats available [ver #6]

Linus Torvalds torvalds at linux-foundation.org
Mon Jul 19 11:46:55 MDT 2010

On Mon, Jul 19, 2010 at 10:26 AM, David Howells <dhowells at redhat.com> wrote:
>> Ask your samba people, for example, if they'd _ever_ do just a "xstat()"?
> I suspect they would, though maybe they can say otherwise.  What about SMB
> directory enumeration?  I believe that is effectively getdents-with-stat.
> Having to do open+stat for each file for that would be painful.

Yeah, but do you need xstat information at all for something like
that? Most people try very hard to make do with the information
returned by readdir itself (d_type and inode number), because if you
end up looking up each name you've already pretty much lost in a
performance model.

(And I do agree that a "readdirplus()" is probably something that a
lot of server people would find useful, but obviously that's another
cross-filesystem nightmare. Only a few filesystems can cheaply give
you anything but d_type/d_ino, and not all do even that),


More information about the samba-technical mailing list