Lines Matching refs:mirror
158 static inline u32 sb_zone_number(int shift, int mirror) in sb_zone_number() argument
162 ASSERT(mirror < BTRFS_SUPER_MIRROR_MAX); in sb_zone_number()
163 switch (mirror) { in sb_zone_number()
863 int btrfs_sb_log_location_bdev(struct block_device *bdev, int mirror, int rw, in btrfs_sb_log_location_bdev() argument
875 *bytenr_ret = btrfs_sb_offset(mirror); in btrfs_sb_log_location_bdev()
888 sb_zone = sb_zone_number(zone_sectors_shift + SECTOR_SHIFT, mirror); in btrfs_sb_log_location_bdev()
903 int btrfs_sb_log_location(struct btrfs_device *device, int mirror, int rw, in btrfs_sb_log_location() argument
916 *bytenr_ret = btrfs_sb_offset(mirror); in btrfs_sb_log_location()
920 zone_num = sb_zone_number(zinfo->zone_size_shift, mirror); in btrfs_sb_log_location()
925 &zinfo->sb_zones[BTRFS_NR_SB_LOG_ZONES * mirror], in btrfs_sb_log_location()
930 int mirror) in is_sb_log_zone() argument
937 zone_num = sb_zone_number(zinfo->zone_size_shift, mirror); in is_sb_log_zone()
947 int btrfs_advance_sb_log(struct btrfs_device *device, int mirror) in btrfs_advance_sb_log() argument
953 if (!is_sb_log_zone(zinfo, mirror)) in btrfs_advance_sb_log()
956 zone = &zinfo->sb_zones[BTRFS_NR_SB_LOG_ZONES * mirror]; in btrfs_advance_sb_log()
999 int btrfs_reset_sb_log_zones(struct block_device *bdev, int mirror) in btrfs_reset_sb_log_zones() argument
1012 sb_zone = sb_zone_number(zone_sectors_shift + SECTOR_SHIFT, mirror); in btrfs_reset_sb_log_zones()