btrfs: merge submit_compressed_extents and async_cow_submit
authorChristoph Hellwig <hch@lst.de>
Wed, 28 Jun 2023 15:31:35 +0000 (17:31 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 21 Aug 2023 12:52:15 +0000 (14:52 +0200)
commit00d31d17663c55de99c1fc1224d06009c4799fc1
treee81135cc4bd5bfa347fe53d4550e9fd3622add11
parentc15d8cf29551ea35a42b4c16cfd08388680be59c
btrfs: merge submit_compressed_extents and async_cow_submit

The code in submit_compressed_extents just loops over the async_extents,
and doesn't need to be conditional on an inode being present, as there
won't be any async_extent in the list if we created and inline extent.
Merge the two functions to simplify the logic.

Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/inode.c