btrfs: stop checking for NULL return from btrfs_get_extent_fiemap()
authorJohannes Thumshirn <johannes.thumshirn@wdc.com>
Fri, 4 Feb 2022 12:06:27 +0000 (04:06 -0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 28 Feb 2022 15:19:50 +0000 (16:19 +0100)
commit212f0f86810c5b5f5d65c4e821802d1322ba0249
tree26e1ed2df40722d0da46c159af4d74055d67691d
parent96f046ad355b87229ed2a1621b6c9d76228c4701
btrfs: stop checking for NULL return from btrfs_get_extent_fiemap()

In get_extent_skip_holes() we're checking the return of
btrfs_get_extent_fiemap() for an error pointer or NULL, but
btrfs_get_extent_fiemap() will never return NULL, only error pointers or
a valid extent_map.

The other caller of btrfs_get_extent_fiemap(), find_desired_extent(),
correctly only checks for error-pointers.

Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent_io.c