ocfs2_rename() was being too aggressive with the rename lock - we only need
it for certain forms of directory rename.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
This commit is contained in:
Jan Kara 2008-02-21 18:00:00 +01:00 коммит произвёл Mark Fasheh
Родитель 58dadcdbc2
Коммит 5dabd69515
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -997,7 +997,7 @@ static int ocfs2_rename(struct inode *old_dir,
*
* And that's why, just like the VFS, we need a file system
* rename lock. */
if (old_dentry != new_dentry) {
if (old_dir != new_dir && S_ISDIR(old_inode->i_mode)) {
status = ocfs2_rename_lock(osb);
if (status < 0) {
mlog_errno(status);