ufs_getfrag_block(): we only grab ->truncate_mutex on block creation path

Cc: stable@vger.kernel.org
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro 2017-06-08 23:28:53 -04:00
Родитель 940ef1a0ed
Коммит 006351ac8e
1 изменённых файлов: 3 добавлений и 1 удалений

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

@ -403,7 +403,9 @@ static int ufs_getfrag_block(struct inode *inode, sector_t fragment, struct buff
if (!create) {
phys64 = ufs_frag_map(inode, offsets, depth);
goto out;
if (phys64)
map_bh(bh_result, sb, phys64 + frag);
return 0;
}
/* This code entered only while writing ....? */