Re: silent semantic changes with reiser4

From: Linus Torvalds
Date: Sun Aug 29 2004 - 00:16:26 EST




On Sat, 28 Aug 2004 viro@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx wrote:
>
> OK, forget getcwd(). What does lookup of .. do from that point? *Especially*
> for stuff you've got from regular files. That's the decision that needs to
> be made.

I think that will decide on whether we expose attributes through the
normal namespace or not.

If we do expose them in the normal namespace, then ".." should work the
way the namespace looks: if you do ".." on the "attribute directory" of a
file, you get the directory that the file was in. Ie an old-style
user-space "getcwd()" would give the right path (well, an old-style
user-space getcwd() would probably refuse the file on the base that it is
S_IFREG, but ignoring that..)

If we _don't_ expose it in the normal namespace, we should should either
just error out (logically you'd get the file itself, but I really don't
wan tto have ".." return a non-directory, because _that_ really might
confuse things), or you'd just return the same directory (ie it would be a
"local root" in the namespace you got moved to).

So let's try to be self-consistent with how we expose it in the normal
namespace.

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