X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=fs%2Fbtrfs%2Fordered-data.h;h=5f2b0ca287058438159cffb1a9d6917fa2b966bd;hb=08289086b0ab0379f54e1590ceb5e1b04d239c07;hp=451507776ff59f87fdc286db823f4d08ff71899a;hpb=92cf44e284d0c2e456d43c0951107a4ec046ef1c;p=karo-tx-linux.git diff --git a/fs/btrfs/ordered-data.h b/fs/btrfs/ordered-data.h index 451507776ff5..5f2b0ca28705 100644 --- a/fs/btrfs/ordered-data.h +++ b/fs/btrfs/ordered-data.h @@ -145,10 +145,10 @@ struct btrfs_ordered_extent { * calculates the total size you need to allocate for an ordered sum * structure spanning 'bytes' in the file */ -static inline int btrfs_ordered_sum_size(struct btrfs_root *root, +static inline int btrfs_ordered_sum_size(struct btrfs_fs_info *fs_info, unsigned long bytes) { - int num_sectors = (int)DIV_ROUND_UP(bytes, root->sectorsize); + int num_sectors = (int)DIV_ROUND_UP(bytes, fs_info->sectorsize); return sizeof(struct btrfs_ordered_sum) + num_sectors * sizeof(u32); }