1 ext4: don't allocate io_end for writeback from ext4_writepage()
3 From: Jan Kara <jack@suse.cz>
5 ext4_writepage() writes out only mapped buffers with allocated
6 underlying blocks. Thus there's no need for io_end structure
7 and we can avoid allocating it.
9 Signed-off-by: Jan Kara <jack@suse.cz>
10 Signed-off-by: Theodore Ts'o <tytso@mit.edu>
12 fs/ext4/inode.c | 8 --------
13 1 file changed, 8 deletions(-)
15 diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
16 index 4247d8d25687..baa87e7d1426 100644
19 @@ -2107,16 +2107,8 @@ static int ext4_writepage(struct page *page,
20 return __ext4_journalled_writepage(page, len);
22 ext4_io_submit_init(&io_submit, wbc);
23 - io_submit.io_end = ext4_init_io_end(inode, GFP_NOFS);
24 - if (!io_submit.io_end) {
25 - redirty_page_for_writepage(wbc, page);
29 ret = ext4_bio_write_page(&io_submit, page, len, wbc, keep_towrite);
30 ext4_io_submit(&io_submit);
31 - /* Drop io_end reference we got from init */
32 - ext4_put_io_end_defer(io_submit.io_end);