From: Olaf Kirch <okir@suse.de>
To: Greg Banks <gnb@melbourne.sgi.com>
Cc: Trond Myklebust <trond.myklebust@fys.uio.no>, nfs@lists.sourceforge.net
Subject: Re: Marking inodes as stale can be wrong
Date: Fri, 30 Apr 2004 10:34:45 +0200 [thread overview]
Message-ID: <20040430083445.GB29672@suse.de> (raw)
In-Reply-To: <4091B12C.FBB1FF34@melbourne.sgi.com>
[-- Attachment #1: Type: text/plain, Size: 333 bytes --]
Here's a minimalistic fix. It may be better to change nfsd_acceptable
to return 0 on success and negative error code on error, but I'm not
sure this is really needed as long as the only acceptance test
in nfsd_acceptable is the subtree check.
Olaf
--
Olaf Kirch | The Hardware Gods hate me.
okir@suse.de |
---------------+
[-- Attachment #2: subtreecheck-nostale.patch --]
[-- Type: text/plain, Size: 657 bytes --]
--- linux-2.6.5/fs/exportfs/expfs.c.nostale 2004-04-04 05:37:44.000000000 +0200
+++ linux-2.6.5/fs/exportfs/expfs.c 2004-04-30 10:32:19.000000000 +0200
@@ -278,7 +278,15 @@
/* drat - I just cannot find anything acceptable */
dput(result);
- return ERR_PTR(-ESTALE);
+
+ /* Originally, we would return ESTALE here. This is not
+ * correct, however, as the file handle is valid; it just
+ * failed our acceptance test.
+ * This will lead to unexpected results in the client if
+ * there are two processes accessing the same file; one
+ * with proper permissions and one without.
+ */
+ return ERR_PTR(-EACCES);
err_target:
dput(target_dir);
next prev parent reply other threads:[~2004-04-30 8:34 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-04-29 14:40 Marking inodes as stale can be wrong Olaf Kirch
2004-04-29 16:44 ` Trond Myklebust
2004-04-29 16:58 ` Olaf Kirch
2004-04-29 17:09 ` Trond Myklebust
2004-04-29 21:28 ` Olaf Kirch
2004-04-29 23:50 ` Greg Banks
2004-04-30 0:43 ` Trond Myklebust
2004-04-30 1:51 ` Greg Banks
2004-04-30 8:34 ` Olaf Kirch [this message]
2004-04-30 8:47 ` Greg Banks
2004-04-30 8:58 ` Olaf Kirch
2004-04-29 17:21 ` Trond Myklebust
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=20040430083445.GB29672@suse.de \
--to=okir@suse.de \
--cc=gnb@melbourne.sgi.com \
--cc=nfs@lists.sourceforge.net \
--cc=trond.myklebust@fys.uio.no \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.