Re: fsync on large files

Linus Torvalds (torvalds@transmeta.com)
Wed, 17 Feb 1999 10:39:19 -0800 (PST)


On Wed, 17 Feb 1999, Alan Cox wrote:
>
> That is why I actually think losing . and .. causes special cases and bugs
> based on real world events, and several Novell reinstalls.

Actually, I think it's more of a case of Novell just having special-casing
and buggy code in general, not really an issue of "." and "..".

Under Linux with dentries, "." and ".." aren't special cases, and they
don't really introduce any problems for any filesystems. They are handled
by the VFS layer as magic names, yes, but that handling is very
straighforward - much more so than it used to be, in fact.

".." in particular is traditionally a strange mix of per-filesystem data
and then global special cases (current root directory, mount points and
other black magic), and as such it's not at all hard to get wrong. It's
especially nasty for directory renames, and then in particular when you
have aliased directory trees, ie LOFS or something.

But with dentries, ".." is actually a lot simpler than it ever used to be
(the only thing it needs to check these days is the current root pointer).

So yes, "." and ".." has special meaning, but that is the thing that
argues _against_ supporting them in the low-level filesystem (because a
lot of the special meaning is stuff that the low-level filesystem doesn't
know about anyway).

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/