This is the mail archive of the
mailing list for the glibc project.
Re: Extended file stat: Splitting file- and fs-specific info?
- From: Andreas Dilger <adilger at dilger dot ca>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: David Howells <dhowells at redhat dot com>,Dave Chinner <david at fromorbit dot com>,"bfields at fieldses dot org Fields" <bfields at fieldses dot org>,"smfrench at gmail dot com French" <smfrench at gmail dot com>,"ben at decadent dot org dot uk Hutchings" <ben at decadent dot org dot uk>,"Trond dot Myklebust at netapp dot com Myklebust" <Trond dot Myklebust at netapp dot com>,"linux-fsdevel at vger dot kernel dot org Devel" <linux-fsdevel at vger dot kernel dot org>,linux-nfs at vger dot kernel dot org,linux-cifs at vger dot kernel dot org,samba-technical at lists dot samba dot org,"linux-ext4 at vger dot kernel dot org List" <linux-ext4 at vger dot kernel dot org>,linux-api at vger dot kernel dot org,libc-alpha at sourceware dot org
- Date: Fri, 11 May 2012 02:54:13 -0600
- Subject: Re: Extended file stat: Splitting file- and fs-specific info?
- References: <73759631-F1E4-4352-9FE6-E9F576F793FB@gmail.com> <email@example.com> <firstname.lastname@example.org> <20120509002420.GL5091@dastard> <email@example.com> <20120510171016.B45BA2C096@topped-with-meat.com>
On 2012-05-10, at 11:10 AM, Roland McGrath wrote:
> POSIX specifies st_blksize thusly: "A file system-specific preferred
> I/O block size for this object. In some file system types, this may
> vary from file to file."
> Since there is only one available to POSIX applications, it should map
> to the one that's described as "preferred IO size for general usage".
Sure, but statxat() isn't a POSIX API.
While I agree with the idea that there should be enough information about the underlying layout for applications to be able to submit good IO, it doesn't help if we have a bunch of extra fields that have vague meanings.
They will get filled in by the filesystem in a haphazard way, and will not be used by application developers that don't understand what they mean.