Commit 4379534c authored by Dmitry Monakhov's avatar Dmitry Monakhov Committed by Greg Kroah-Hartman

ext4: convert write_begin methods to stable_page_writes semantics

commit 7afe5aa5 upstream.

Use wait_for_stable_page() instead of wait_on_page_writeback()
Signed-off-by: default avatarDmitry Monakhov <dmonakhov@openvz.org>
Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
Reviewed-by: default avatarJan Kara <jack@suse.cz>
Cc: Alex Shi <alex.shi@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a72719d7
......@@ -1032,7 +1032,8 @@ static int ext4_write_begin(struct file *file, struct address_space *mapping,
ext4_journal_stop(handle);
goto retry_grab;
}
wait_on_page_writeback(page);
/* In case writeback began while the page was unlocked */
wait_for_stable_page(page);
if (ext4_should_dioread_nolock(inode))
ret = __block_write_begin(page, pos, len, ext4_get_block_write);
......@@ -2729,7 +2730,7 @@ static int ext4_da_write_begin(struct file *file, struct address_space *mapping,
goto retry_grab;
}
/* In case writeback began while the page was unlocked */
wait_on_page_writeback(page);
wait_for_stable_page(page);
ret = __block_write_begin(page, pos, len, ext4_da_get_block_prep);
if (ret < 0) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment