mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-10 23:20:05 +00:00
nfs: add missing rcu-walk check
Signed-off-by: Nick Piggin <npiggin@kernel.dk>
This commit is contained in:
parent
2c6755988a
commit
657e94b673
@ -1410,11 +1410,15 @@ no_open:
|
|||||||
static int nfs_open_revalidate(struct dentry *dentry, struct nameidata *nd)
|
static int nfs_open_revalidate(struct dentry *dentry, struct nameidata *nd)
|
||||||
{
|
{
|
||||||
struct dentry *parent = NULL;
|
struct dentry *parent = NULL;
|
||||||
struct inode *inode = dentry->d_inode;
|
struct inode *inode;
|
||||||
struct inode *dir;
|
struct inode *dir;
|
||||||
struct nfs_open_context *ctx;
|
struct nfs_open_context *ctx;
|
||||||
int openflags, ret = 0;
|
int openflags, ret = 0;
|
||||||
|
|
||||||
|
if (nd->flags & LOOKUP_RCU)
|
||||||
|
return -ECHILD;
|
||||||
|
|
||||||
|
inode = dentry->d_inode;
|
||||||
if (!is_atomic_open(nd) || d_mountpoint(dentry))
|
if (!is_atomic_open(nd) || d_mountpoint(dentry))
|
||||||
goto no_open;
|
goto no_open;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user