On Dec 15, 2006 14:37 -0800, Ulrich Drepper wrote:
The kernel doesn't necessarily have to clear the fields. The per-field
valid flag would determine is that field had valid data or garbage.
That said, there is no harm in the kernel/fs filling in additional fields
is they are readily available. It would be up to the caller to NOT ask
for fields that it doesn't need, as that _might_ cause additional work
on the part of the filesystem. If the kernel returns extra valid fields
(because they are "free") that the application doesn't use, no harm done.
Tell that to every distro maintainer, and/or try to convince the upstream
"ls" maintainers to change this. :-)
It isn't just to fix the ls --color problem. There are lots of other
apps that need some stat fields and not others. Also, implementing
the compatibility support for this (statlite->stat(), flags=$all_valid)
is trivial, if potentially less performant (though no worse than today).
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
-
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html