Unionfs ODF: Move around locking order in unionfs_dir_llseek
authorRachita Kothiyal <rachita@dewey.fsl.cs.sunysb.edu>
Sun, 18 May 2008 07:35:49 +0000 (03:35 -0400)
committerRachita Kothiyal <rachita@dewey.fsl.cs.sunysb.edu>
Sun, 18 May 2008 07:35:49 +0000 (03:35 -0400)
Signed-off-by: Rachita Kothiyal <rachita@fsl.cs.sunysb.edu>
fs/unionfs/dirfops.c

index 3926972f2a8e1461a59d17964a6b969ab3a8e19e..8e578af511d0fd082282ed2536877d9dbb6bc041 100644 (file)
@@ -146,12 +146,12 @@ static loff_t unionfs_dir_llseek(struct file *file, loff_t offset, int origin)
        unionfs_lock_dentry(dentry, UNIONFS_DMUTEX_CHILD);
 
        err = unionfs_file_revalidate(file, false);
+       unionfs_unlock_dentry(dentry);
        if (unlikely(err))
                goto out;
 
        err = generic_file_llseek(file, offset, origin);
 out:
-       unionfs_unlock_dentry(dentry);
        unionfs_read_unlock(dentry->d_sb);
        return err;
 }