mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-26 05:34:13 +08:00
f2fs: fix to call f2fs_unlock_op
This patch fixes to call f2fs_unlock_op, which was missing before. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
9ba69cf987
commit
13fd8f89f6
@ -494,7 +494,7 @@ int truncate_blocks(struct inode *inode, u64 from, bool lock)
|
|||||||
/* writepage can convert inline_data under get_donde_of_data */
|
/* writepage can convert inline_data under get_donde_of_data */
|
||||||
if (f2fs_has_inline_data(inode)) {
|
if (f2fs_has_inline_data(inode)) {
|
||||||
f2fs_put_dnode(&dn);
|
f2fs_put_dnode(&dn);
|
||||||
goto done;
|
goto unlock_done;
|
||||||
}
|
}
|
||||||
|
|
||||||
count = ADDRS_PER_PAGE(dn.node_page, F2FS_I(inode));
|
count = ADDRS_PER_PAGE(dn.node_page, F2FS_I(inode));
|
||||||
@ -510,6 +510,7 @@ int truncate_blocks(struct inode *inode, u64 from, bool lock)
|
|||||||
f2fs_put_dnode(&dn);
|
f2fs_put_dnode(&dn);
|
||||||
free_next:
|
free_next:
|
||||||
err = truncate_inode_blocks(inode, free_from);
|
err = truncate_inode_blocks(inode, free_from);
|
||||||
|
unlock_done:
|
||||||
if (lock)
|
if (lock)
|
||||||
f2fs_unlock_op(sbi);
|
f2fs_unlock_op(sbi);
|
||||||
done:
|
done:
|
||||||
|
Loading…
Reference in New Issue
Block a user