aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext4')
-rw-r--r--fs/ext4/inode.c20
1 files changed, 1 insertions, 19 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index 52f7ff2f2e7e..cf5d30a7cce3 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -1636,15 +1636,6 @@ static void mpage_da_map_and_submit(struct mpage_da_data *mpd)
1636 1636
1637 for (i = 0; i < map.m_len; i++) 1637 for (i = 0; i < map.m_len; i++)
1638 unmap_underlying_metadata(bdev, map.m_pblk + i); 1638 unmap_underlying_metadata(bdev, map.m_pblk + i);
1639
1640 if (ext4_should_order_data(mpd->inode)) {
1641 err = ext4_jbd2_file_inode(handle, mpd->inode);
1642 if (err) {
1643 /* Only if the journal is aborted */
1644 mpd->retval = err;
1645 goto submit_io;
1646 }
1647 }
1648 } 1639 }
1649 1640
1650 /* 1641 /*
@@ -2592,17 +2583,8 @@ static int ext4_da_write_end(struct file *file,
2592 if (copied && new_i_size > EXT4_I(inode)->i_disksize) { 2583 if (copied && new_i_size > EXT4_I(inode)->i_disksize) {
2593 if (ext4_da_should_update_i_disksize(page, end)) { 2584 if (ext4_da_should_update_i_disksize(page, end)) {
2594 down_write(&EXT4_I(inode)->i_data_sem); 2585 down_write(&EXT4_I(inode)->i_data_sem);
2595 if (new_i_size > EXT4_I(inode)->i_disksize) { 2586 if (new_i_size > EXT4_I(inode)->i_disksize)
2596 /*
2597 * Updating i_disksize when extending file
2598 * without needing block allocation
2599 */
2600 if (ext4_should_order_data(inode))
2601 ret = ext4_jbd2_file_inode(handle,
2602 inode);
2603
2604 EXT4_I(inode)->i_disksize = new_i_size; 2587 EXT4_I(inode)->i_disksize = new_i_size;
2605 }
2606 up_write(&EXT4_I(inode)->i_data_sem); 2588 up_write(&EXT4_I(inode)->i_data_sem);
2607 /* We need to mark inode dirty even if 2589 /* We need to mark inode dirty even if
2608 * new_i_size is less that inode->i_size 2590 * new_i_size is less that inode->i_size