Commit 8b01f931 authored by Filipe Manana's avatar Filipe Manana Committed by David Sterba

btrfs: return block group directly at btrfs_next_block_group()

At btrfs_next_block_group(), we have this long line with two statements:

  cache = btrfs_lookup_first_block_group(...); return cache;

This makes it a bit harder to read due to two statements on the same
line, so change that to directly return the result of the call to
btrfs_lookup_first_block_group().
Reviewed-by: default avatarNikolay Borisov <nborisov@suse.com>
Signed-off-by: default avatarFilipe Manana <fdmanana@suse.com>
Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 16b0c258
...@@ -271,7 +271,7 @@ struct btrfs_block_group *btrfs_next_block_group( ...@@ -271,7 +271,7 @@ struct btrfs_block_group *btrfs_next_block_group(
read_unlock(&fs_info->block_group_cache_lock); read_unlock(&fs_info->block_group_cache_lock);
btrfs_put_block_group(cache); btrfs_put_block_group(cache);
cache = btrfs_lookup_first_block_group(fs_info, next_bytenr); return cache; return btrfs_lookup_first_block_group(fs_info, next_bytenr);
} }
node = rb_next(&cache->cache_node); node = rb_next(&cache->cache_node);
btrfs_put_block_group(cache); btrfs_put_block_group(cache);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment