btrfs: move extent bit and page cleanup into cow_file_range_inline
authorJosef Bacik <josef@toxicpanda.com>
Wed, 20 Mar 2024 21:24:13 +0000 (17:24 -0400)
committerDavid Sterba <dsterba@suse.com>
Tue, 7 May 2024 19:31:09 +0000 (21:31 +0200)
commit0586d0a89e77d717da14df42648ace4a9fd67981
treefd70b524270e6bcc9bc126d66527dc2abbf25267
parent0332967b4d657754c914b2a1951ae2d4ed3d99bd
btrfs: move extent bit and page cleanup into cow_file_range_inline

We duplicate the extent cleanup for cow_file_range_inline() in the cow
and compressed case.  The encoded case doesn't need to do cleanup the
same way, so rename cow_file_range_inline to __cow_file_range_inline and
then make cow_file_range_inline handle the extent cleanup appropriately,
and update the callers.

Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/inode.c