diff options
Diffstat (limited to 'fs/ext3')
-rw-r--r-- | fs/ext3/inode.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ext3/inode.c b/fs/ext3/inode.c index ab034d3053ea..c5ee9f0691e3 100644 --- a/fs/ext3/inode.c +++ b/fs/ext3/inode.c | |||
@@ -1158,7 +1158,7 @@ retry: | |||
1158 | ret = PTR_ERR(handle); | 1158 | ret = PTR_ERR(handle); |
1159 | goto out; | 1159 | goto out; |
1160 | } | 1160 | } |
1161 | if (test_opt(inode->i_sb, NOBH)) | 1161 | if (test_opt(inode->i_sb, NOBH) && ext3_should_writeback_data(inode)) |
1162 | ret = nobh_prepare_write(page, from, to, ext3_get_block); | 1162 | ret = nobh_prepare_write(page, from, to, ext3_get_block); |
1163 | else | 1163 | else |
1164 | ret = block_prepare_write(page, from, to, ext3_get_block); | 1164 | ret = block_prepare_write(page, from, to, ext3_get_block); |
@@ -1244,7 +1244,7 @@ static int ext3_writeback_commit_write(struct file *file, struct page *page, | |||
1244 | if (new_i_size > EXT3_I(inode)->i_disksize) | 1244 | if (new_i_size > EXT3_I(inode)->i_disksize) |
1245 | EXT3_I(inode)->i_disksize = new_i_size; | 1245 | EXT3_I(inode)->i_disksize = new_i_size; |
1246 | 1246 | ||
1247 | if (test_opt(inode->i_sb, NOBH)) | 1247 | if (test_opt(inode->i_sb, NOBH) && ext3_should_writeback_data(inode)) |
1248 | ret = nobh_commit_write(file, page, from, to); | 1248 | ret = nobh_commit_write(file, page, from, to); |
1249 | else | 1249 | else |
1250 | ret = generic_commit_write(file, page, from, to); | 1250 | ret = generic_commit_write(file, page, from, to); |
@@ -1494,7 +1494,7 @@ static int ext3_writeback_writepage(struct page *page, | |||
1494 | goto out_fail; | 1494 | goto out_fail; |
1495 | } | 1495 | } |
1496 | 1496 | ||
1497 | if (test_opt(inode->i_sb, NOBH)) | 1497 | if (test_opt(inode->i_sb, NOBH) && ext3_should_writeback_data(inode)) |
1498 | ret = nobh_writepage(page, ext3_get_block, wbc); | 1498 | ret = nobh_writepage(page, ext3_get_block, wbc); |
1499 | else | 1499 | else |
1500 | ret = block_write_full_page(page, ext3_get_block, wbc); | 1500 | ret = block_write_full_page(page, ext3_get_block, wbc); |