btrfs: remove cached space_info in btrfs_statfs()
authorJohannes Thumshirn <jthumshirn@suse.de>
Thu, 24 Oct 2019 15:44:54 +0000 (17:44 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 18 Nov 2019 16:51:45 +0000 (17:51 +0100)
commitf5389f330d6f28d648c51624f059b0bfdd9b1806
treea995b50d287e8cfe172b2a68351522d06ccef889
parentb3470b5dbe1300dea94191ae4b7d070be9a5cdc9
btrfs: remove cached space_info in btrfs_statfs()

In btrfs_statfs() we cache fs_info::space_info in a local variable only
to use it once in a list_for_each_rcu() statement.

Not only is the local variable unnecessary it even makes the code harder
to follow as it's not clear which list it is iterating.

Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/super.c