diff options
author | Chao Yu <chao2.yu@samsung.com> | 2014-08-04 10:11:17 +0800 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2014-08-04 13:02:03 -0700 |
commit | 497a0930bb4bd148451e1af239a082e3916b681b (patch) | |
tree | 1079d0b9749f7de0e77d0f18269b6235cdf60445 /fs/f2fs | |
parent | 002a41cabb5829d59c0337dcb5fa3893e0bb15fd (diff) |
f2fs: add f2fs_balance_fs for expand_inode_data
This patch adds f2fs_balance_fs in expand_inode_data to avoid allocation failure
with segment.
Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs')
-rw-r--r-- | fs/f2fs/file.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c index 2a91a7d1760c..208f1a9bd569 100644 --- a/fs/f2fs/file.c +++ b/fs/f2fs/file.c @@ -672,6 +672,8 @@ static int expand_inode_data(struct inode *inode, loff_t offset, loff_t off_start, off_end; int ret = 0; + f2fs_balance_fs(sbi); + ret = inode_newsize_ok(inode, (len + offset)); if (ret) return ret; |