btrfs: open code and remove btrfs_inode_sectorsize helper
authorJosef Bacik <josef@toxicpanda.com>
Wed, 14 Sep 2022 23:04:48 +0000 (19:04 -0400)
committerDavid Sterba <dsterba@suse.com>
Mon, 26 Sep 2022 10:28:06 +0000 (12:28 +0200)
commitee8ba05cbbcee68113133249fc4f73e00a7ac3f5
treefc763a5138bf7098b822816896dd34a4f8559da1
parent2b6433c7f620b61ba5fac52a63053f6c56483f80
btrfs: open code and remove btrfs_inode_sectorsize helper

This is defined in btrfs_inode.h, and dereferences btrfs_root and
btrfs_fs_info, both of which aren't defined in btrfs_inode.h.
Additionally, in many places we already have root or fs_info, so this
helper often makes the code harder to read.  So delete the helper and
simply open code it in the few places that we use it.

Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/btrfs_inode.h
fs/btrfs/extent_io.c
fs/btrfs/file.c