aboutsummaryrefslogtreecommitdiffstats
path: root/fs/f2fs/data.c
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk@kernel.org>2014-08-14 19:32:54 -0400
committerJaegeuk Kim <jaegeuk@kernel.org>2014-08-21 16:57:01 -0400
commit764aa3e978020121cbb86111b5d8f42830015a06 (patch)
treedf2e0f43245a452010aa184042e7da2306ed2e4b /fs/f2fs/data.c
parent14f4e690857715d5e0cbe403b4cb8e8c904a6c15 (diff)
f2fs: avoid double lock in truncate_blocks
The init_inode_metadata calls truncate_blocks when error is occurred. The callers holds f2fs_lock_op, so we should not call it again in truncate_blocks. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/data.c')
-rw-r--r--fs/f2fs/data.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c
index 6ba52a393063..76de83e25a89 100644
--- a/fs/f2fs/data.c
+++ b/fs/f2fs/data.c
@@ -936,7 +936,7 @@ static void f2fs_write_failed(struct address_space *mapping, loff_t to)
936 936
937 if (to > inode->i_size) { 937 if (to > inode->i_size) {
938 truncate_pagecache(inode, inode->i_size); 938 truncate_pagecache(inode, inode->i_size);
939 truncate_blocks(inode, inode->i_size); 939 truncate_blocks(inode, inode->i_size, true);
940 } 940 }
941} 941}
942 942