diff options
author | Ross Zwisler <zwisler@chromium.org> | 2019-06-20 17:26:26 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-07-28 08:27:23 +0200 |
commit | 20fea43edf9473eb5b113f0ccac9ae81801a7300 (patch) | |
tree | 53dee2562c382e9402caa0ceab9a5f526bc27d01 /fs/ext4/move_extent.c | |
parent | dcb3ec8480c3879ffa8a6e710e2b145de5a4df32 (diff) | |
download | linux-stable-20fea43edf9473eb5b113f0ccac9ae81801a7300.tar.gz linux-stable-20fea43edf9473eb5b113f0ccac9ae81801a7300.tar.bz2 linux-stable-20fea43edf9473eb5b113f0ccac9ae81801a7300.zip |
ext4: use jbd2_inode dirty range scoping
commit 73131fbb003b3691cfcf9656f234b00da497fcd6 upstream.
Use the newly introduced jbd2_inode dirty range scoping to prevent us
from waiting forever when trying to complete a journal transaction.
Signed-off-by: Ross Zwisler <zwisler@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Jan Kara <jack@suse.cz>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/ext4/move_extent.c')
-rw-r--r-- | fs/ext4/move_extent.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ext4/move_extent.c b/fs/ext4/move_extent.c index 1083a9f3f16a..c7ded4e2adff 100644 --- a/fs/ext4/move_extent.c +++ b/fs/ext4/move_extent.c @@ -390,7 +390,8 @@ data_copy: /* Even in case of data=writeback it is reasonable to pin * inode to transaction, to prevent unexpected data loss */ - *err = ext4_jbd2_inode_add_write(handle, orig_inode); + *err = ext4_jbd2_inode_add_write(handle, orig_inode, + (loff_t)orig_page_offset << PAGE_SHIFT, replaced_size); unlock_pages: unlock_page(pagep[0]); |