aboutsummaryrefslogtreecommitdiffstats
path: root/fs/namei.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/namei.c')
-rw-r--r--fs/namei.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/namei.c b/fs/namei.c
index 0223c41fb114..5c867dd1c0b3 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -433,6 +433,8 @@ static int unlazy_walk(struct nameidata *nd, struct dentry *dentry)
433 goto err_parent; 433 goto err_parent;
434 BUG_ON(nd->inode != parent->d_inode); 434 BUG_ON(nd->inode != parent->d_inode);
435 } else { 435 } else {
436 if (dentry->d_parent != parent)
437 goto err_parent;
436 spin_lock_nested(&dentry->d_lock, DENTRY_D_LOCK_NESTED); 438 spin_lock_nested(&dentry->d_lock, DENTRY_D_LOCK_NESTED);
437 if (!__d_rcu_to_refcount(dentry, nd->seq)) 439 if (!__d_rcu_to_refcount(dentry, nd->seq))
438 goto err_child; 440 goto err_child;