aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/inode.c
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2021-09-27 15:21:46 +0800
committerDavid Sterba <dsterba@suse.com>2021-10-26 19:08:03 +0200
commit584691748c0fa33866ad97f9e6ea69aa6ba64804 (patch)
tree30556a2f66da2ca9cc5ae30fa53426c3902a0c4e /fs/btrfs/inode.c
parentbtrfs: use async_chunk::async_cow to replace the confusing pending pointer (diff)
downloadlinux-dev-584691748c0fa33866ad97f9e6ea69aa6ba64804.tar.xz
linux-dev-584691748c0fa33866ad97f9e6ea69aa6ba64804.zip
btrfs: don't pass compressed pages to btrfs_writepage_endio_finish_ordered()
Since async_extent holds the compressed page, it would trigger the new ASSERT() in btrfs_mark_ordered_io_finished() which checks that the range is inside the page. Now btrfs_writepage_endio_finish_ordered() can accept @page == NULL, just pass NULL to btrfs_writepage_endio_finish_ordered(). Signed-off-by: Qu Wenruo <wqu@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r--fs/btrfs/inode.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index 82dc636c4b51..9ae417aaea28 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -973,15 +973,12 @@ retry:
async_extent->nr_pages,
async_chunk->write_flags,
async_chunk->blkcg_css)) {
- struct page *p = async_extent->pages[0];
const u64 start = async_extent->start;
const u64 end = start + async_extent->ram_size - 1;
- p->mapping = inode->vfs_inode.i_mapping;
- btrfs_writepage_endio_finish_ordered(inode, p, start,
+ btrfs_writepage_endio_finish_ordered(inode, NULL, start,
end, false);
- p->mapping = NULL;
extent_clear_unlock_delalloc(inode, start, end, NULL, 0,
PAGE_END_WRITEBACK |
PAGE_SET_ERROR);