mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Alexander Viro <viro@math.psu.edu>
Cc: Linus Torvalds <torvalds@transmeta.com>,
	Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 2.5.3-pre1] Fix NFS dentry lookup behaviour
Date: Fri, 18 Jan 2002 13:10:51 +0100	[thread overview]
Message-ID: <15432.4299.720181.998342@charged.uio.no> (raw)
In-Reply-To: <Pine.GSO.4.21.0201171720390.11155-100000@weyl.math.psu.edu>
In-Reply-To: <Pine.LNX.4.33.0201171414220.3114-100000@penguin.transmeta.com> <Pine.GSO.4.21.0201171720390.11155-100000@weyl.math.psu.edu>

>>>>> " " == Alexander Viro <viro@math.psu.edu> writes:

     > Nothing, especially since it will happen automatically when we
     > switch to slightly different handling of cwd/root (no
     > user-visible changes, will allow union-mounts - basically,
     > cleanup of first and last steps of path_walk()).

So what is the plan? I've raised the issue of open(".") on Linux
Fsdevel several times, and ended up getting nowhere. This is the first
time I've heard mention of a planned cleanup of path_walk.
I'll be happy to drop that part of the patch if you can confirm that it
will solve the following problem.

Reminder of the problem
-----------------------
For NFS the current code *is broken* since we don't get called back at
all in path_walk() for the special case of accessing cwd. That has 2
consequences:

  - open(".") may succeed even if cwd is know to be a stale dentry.

  - The attribute cache, and hence also the data cache, does not get
    revalidated. This breaks close-to-open semantics for those who
    require it, and leads to silly inconsistencies: typically 'ls -l'
    returning gratuitous "file 'blah' does not exist" errors.

Putting cache revalidation in ->open() itself would be a pain: there
is no way of detecting whether or the attributes were checked during
the dcache lookup, so it would mean that we end up duplicating a lot
of cache checks for the non-cwd case.

Using the existing inode->i_op->revalidate() is also not an option,
since it might break other filesystems, and is in any case scheduled
for deletion due to being ill-defined.

If we could use d_revalidate(), then that would be OK as far as I'm
concerned, however this too was deemed unacceptable when raised on
linux-fsdevel.

Cheers,
  Trond

  parent reply	other threads:[~2002-01-18 12:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-17  2:37 Trond Myklebust
2002-01-17 22:15 ` Linus Torvalds
2002-01-17 22:24   ` Alexander Viro
2002-01-18 12:10   ` Trond Myklebust [this message]
2002-01-18 12:53     ` Alan Cox
2002-01-18 15:24 ` Trond Myklebust
2002-01-18 17:32   ` 2.4.18-pre4 nfs problem Stephan von Krawczynski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=15432.4299.720181.998342@charged.uio.no \
    --to=trond.myklebust@fys.uio.no \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    --cc=viro@math.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®