diff options
author | Nikolay Borisov <nborisov@suse.com> | 2020-08-31 14:42:42 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2020-10-07 12:12:18 +0200 |
commit | 6fee248d2beb3591f6f50aeeac843b366b116e3b (patch) | |
tree | d16f8b583477b9f5dd8c270b18bfc9b6cbd1ab9a /fs/btrfs/reflink.c | |
parent | 90c0304c6307a68e1e4af637d56d6613ed026875 (diff) |
btrfs: convert btrfs_inode_sectorsize to take btrfs_inode
It's counterintuitive to have a function named btrfs_inode_xxx which
takes a generic inode. Also move the function to btrfs_inode.h so that
it has access to the definition of struct btrfs_inode.
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/reflink.c')
-rw-r--r-- | fs/btrfs/reflink.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/reflink.c b/fs/btrfs/reflink.c index 5cd02514cf4d..7126f94cf216 100644 --- a/fs/btrfs/reflink.c +++ b/fs/btrfs/reflink.c @@ -52,7 +52,7 @@ static int copy_inline_to_page(struct inode *inode, const u64 datal, const u8 comp_type) { - const u64 block_size = btrfs_inode_sectorsize(inode); + const u64 block_size = btrfs_inode_sectorsize(BTRFS_I(inode)); const u64 range_end = file_offset + block_size - 1; const size_t inline_size = size - btrfs_file_extent_calc_inline_size(0); char *data_start = inline_data + btrfs_file_extent_calc_inline_size(0); |