summaryrefslogtreecommitdiff
path: root/fs/btrfs/discard.c
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2024-05-23 10:49:38 +0930
committerDavid Sterba <dsterba@suse.com>2024-07-11 15:52:25 +0200
commita39484371dd29ed9ba67bfd211e51d72b1a35c3d (patch)
treebee027400c2c9b4e65d66a47892dd99ff8180229 /fs/btrfs/discard.c
parentaf61081fb522ab52bc7f7d8304b4a7cc4f606575 (diff)
btrfs: remove the BUG_ON() inside extent_range_clear_dirty_for_io()
Previously we had a BUG_ON() inside extent_range_clear_dirty_for_io(), as we expected all involved folios to be still locked, thus no folio should be missing. However for extent_range_clear_dirty_for_io() itself, we can skip the missing folio and handle the remaining ones, and return an error if there is anything wrong. Remove the BUG_ON() and let the caller to handle the error. In the caller we do not have a quick way to cleanup the error, but all the compression routines would handle the missing folio as an error and properly error out, so we only need to do an ASSERT() for developers, while for non-debug build the compression routine would handle the error correctly. Signed-off-by: Qu Wenruo <wqu@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/discard.c')
0 files changed, 0 insertions, 0 deletions