aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r--fs/ext4/inode.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index e80fc513eac..9f7f9e49914 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -39,6 +39,7 @@
39#include <linux/bio.h> 39#include <linux/bio.h>
40#include <linux/workqueue.h> 40#include <linux/workqueue.h>
41#include <linux/kernel.h> 41#include <linux/kernel.h>
42#include <linux/printk.h>
42#include <linux/slab.h> 43#include <linux/slab.h>
43#include <linux/ratelimit.h> 44#include <linux/ratelimit.h>
44 45
@@ -3379,7 +3380,7 @@ int ext4_alloc_da_blocks(struct inode *inode)
3379 * doing I/O at all. 3380 * doing I/O at all.
3380 * 3381 *
3381 * We could call write_cache_pages(), and then redirty all of 3382 * We could call write_cache_pages(), and then redirty all of
3382 * the pages by calling redirty_page_for_writeback() but that 3383 * the pages by calling redirty_page_for_writepage() but that
3383 * would be ugly in the extreme. So instead we would need to 3384 * would be ugly in the extreme. So instead we would need to
3384 * replicate parts of the code in the above functions, 3385 * replicate parts of the code in the above functions,
3385 * simplifying them becuase we wouldn't actually intend to 3386 * simplifying them becuase we wouldn't actually intend to
@@ -3737,7 +3738,7 @@ static int ext4_set_bh_endio(struct buffer_head *bh, struct inode *inode)
3737retry: 3738retry:
3738 io_end = ext4_init_io_end(inode, GFP_ATOMIC); 3739 io_end = ext4_init_io_end(inode, GFP_ATOMIC);
3739 if (!io_end) { 3740 if (!io_end) {
3740 pr_warning_ratelimited("%s: allocation fail\n", __func__); 3741 pr_warn_ratelimited("%s: allocation fail\n", __func__);
3741 schedule(); 3742 schedule();
3742 goto retry; 3743 goto retry;
3743 } 3744 }
@@ -3761,9 +3762,9 @@ retry:
3761 * preallocated extents, and those write extend the file, no need to 3762 * preallocated extents, and those write extend the file, no need to
3762 * fall back to buffered IO. 3763 * fall back to buffered IO.
3763 * 3764 *
3764 * For holes, we fallocate those blocks, mark them as unintialized 3765 * For holes, we fallocate those blocks, mark them as uninitialized
3765 * If those blocks were preallocated, we mark sure they are splited, but 3766 * If those blocks were preallocated, we mark sure they are splited, but
3766 * still keep the range to write as unintialized. 3767 * still keep the range to write as uninitialized.
3767 * 3768 *
3768 * The unwrritten extents will be converted to written when DIO is completed. 3769 * The unwrritten extents will be converted to written when DIO is completed.
3769 * For async direct IO, since the IO may still pending when return, we 3770 * For async direct IO, since the IO may still pending when return, we