提交 216d5d06 编写于 作者: T Trond Myklebust

NFSv4: Use NFSv2/v3 rules for negative dentries in nfs_open_revalidate

Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
上级 0a5ebc14
......@@ -1037,8 +1037,12 @@ static int nfs_open_revalidate(struct dentry *dentry, struct nameidata *nd)
/* We can't create new files in nfs_open_revalidate(), so we
* optimize away revalidation of negative dentries.
*/
if (inode == NULL)
if (inode == NULL) {
if (!nfs_neg_need_reval(dir, dentry, nd))
ret = 1;
goto out;
}
/* NFS only supports OPEN on regular files */
if (!S_ISREG(inode->i_mode))
goto no_open;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册