[AFS3-std] Re: A call for consensus on draft-deason-afs3-type-time-02

Andrew Deason adeason@sinenomine.net
Fri, 29 Jul 2011 13:51:56 -0500


On Fri, 29 Jul 2011 11:29:45 -0700
Russ Allbery <rra@stanford.edu> wrote:

> Andrew Deason <adeason@sinenomine.net> writes:
> 
> > This isn't really an analagous example, since as far as I know, you
> > can't actually manipulate the ns part of that timestamp, as there is
> > no interface on Linux to set or get a timestamp with nanosecond
> > resolution.
> 
> utimensat(2) as of Linux 2.6.22.

Okay, so the Linux VFS layer does have this, and it looks like at least
Solaris 10/11 do, too. Perhaps more importantly, this appears to be in
POSIX (or SuS or X/Open or whatever):
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/futimens.html>
so if other Unix doesn't already have it, they probably will within the
forseeable future.

While I'm sure POSIX doesn't require actually having 1-ns resolution
(the _POSIX_TIMESTAMP_RESOLUTION pathconf lets us say what it actually
is), that does indicate such interfaces are/will be rather widespread
soon enough.

-- 
Andrew Deason
adeason@sinenomine.net