OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
90cf500
)
NFSv4: Fix return value in nfs_finish_open()
author
Trond Myklebust
<trond.myklebust@hammerspace.com>
Fri, 9 Aug 2019 16:15:07 +0000
(12:15 -0400)
committer
Trond Myklebust
<trond.myklebust@hammerspace.com>
Mon, 19 Aug 2019 12:56:04 +0000
(08:56 -0400)
If the file turns out to be of the wrong type after opening, we want
to revalidate the path and retry, so return EOPENSTALE rather than
ESTALE.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
fs/nfs/dir.c
patch
|
blob
|
history
diff --git
a/fs/nfs/dir.c
b/fs/nfs/dir.c
index
8d50109
..
0adfd88
100644
(file)
--- a/
fs/nfs/dir.c
+++ b/
fs/nfs/dir.c
@@
-1487,7
+1487,7
@@
static int nfs_finish_open(struct nfs_open_context *ctx,
if (S_ISREG(file->f_path.dentry->d_inode->i_mode))
nfs_file_set_open_context(file, ctx);
else
- err = -ESTALE;
+ err = -E
OPEN
STALE;
out:
return err;
}