summaryrefslogtreecommitdiffstats
path: root/module/spl/spl-vnode.c
diff options
context:
space:
mode:
Diffstat (limited to 'module/spl/spl-vnode.c')
-rw-r--r--module/spl/spl-vnode.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/module/spl/spl-vnode.c b/module/spl/spl-vnode.c
index a914e046c..addc61155 100644
--- a/module/spl/spl-vnode.c
+++ b/module/spl/spl-vnode.c
@@ -352,7 +352,8 @@ spl_kern_path_locked(const char *name, struct path *path)
if (rc)
return (ERR_PTR(rc));
- spl_inode_lock(parent.dentry->d_inode);
+ /* use I_MUTEX_PARENT because vfs_unlink needs it */
+ spl_inode_lock_nested(parent.dentry->d_inode, I_MUTEX_PARENT);
dentry = lookup_one_len(basename, parent.dentry, len);
if (IS_ERR(dentry)) {