Lines Matching refs:fs_devices

216 		em->bdev = fs_info->fs_devices->latest_bdev;  in btree_get_extent()
231 em->bdev = fs_info->fs_devices->latest_bdev; in btree_get_extent()
536 ASSERT(memcmp_extent_buffer(eb, fs_info->fs_devices->metadata_uuid, in csum_dirty_buffer()
561 struct btrfs_fs_devices *fs_devices = fs_info->fs_devices; in check_tree_block_fsid() local
566 while (fs_devices) { in check_tree_block_fsid()
574 if (fs_devices == fs_info->fs_devices && in check_tree_block_fsid()
576 metadata_uuid = fs_devices->metadata_uuid; in check_tree_block_fsid()
578 metadata_uuid = fs_devices->fsid; in check_tree_block_fsid()
584 fs_devices = fs_devices->seed; in check_tree_block_fsid()
1632 list_for_each_entry_rcu(device, &info->fs_devices->devices, dev_list) { in btrfs_congested_fn()
2150 struct btrfs_fs_devices *fs_devices) in btrfs_init_workqueues() argument
2177 min_t(u64, fs_devices->num_devices, in btrfs_init_workqueues()
2257 struct btrfs_fs_devices *fs_devices) in btrfs_replay_log() argument
2265 if (fs_devices->rw_devices == 0) { in btrfs_replay_log()
2472 if (memcmp(fs_info->fs_devices->metadata_uuid, sb->dev_item.fsid, in validate_super()
2476 fs_info->fs_devices->metadata_uuid, sb->dev_item.fsid); in validate_super()
2593 struct btrfs_fs_devices *fs_devices, in open_ctree() argument
2796 invalidate_bdev(fs_devices->latest_bdev); in open_ctree()
2801 bh = btrfs_read_dev_super(fs_devices->latest_bdev); in open_ctree()
2847 ASSERT(!memcmp(fs_info->fs_devices->fsid, fs_info->super_copy->fsid, in open_ctree()
2851 ASSERT(!memcmp(fs_info->fs_devices->metadata_uuid, in open_ctree()
2970 ret = btrfs_init_workqueues(fs_info, fs_devices); in open_ctree()
2985 memcpy(&sb->s_uuid, fs_info->fs_devices->fsid, BTRFS_FSID_SIZE); in open_ctree()
3027 btrfs_free_extra_devids(fs_devices, 0); in open_ctree()
3029 if (!fs_devices->latest_bdev) { in open_ctree()
3098 btrfs_free_extra_devids(fs_devices, 1); in open_ctree()
3100 ret = btrfs_sysfs_add_fsid(fs_devices, NULL); in open_ctree()
3107 ret = btrfs_sysfs_add_device(fs_devices); in open_ctree()
3150 !fs_info->fs_devices->rotating) { in open_ctree()
3162 ret = btrfsic_mount(fs_info, fs_devices, in open_ctree()
3183 ret = btrfs_replay_log(fs_info, fs_devices); in open_ctree()
3333 btrfs_sysfs_remove_fsid(fs_info->fs_devices); in open_ctree()
3364 btrfs_close_devices(fs_info->fs_devices); in open_ctree()
3673 lockdep_assert_held(&info->fs_devices->device_list_mutex); in barrier_all_devices()
3675 head = &info->fs_devices->devices; in barrier_all_devices()
3775 mutex_lock(&fs_info->fs_devices->device_list_mutex); in write_all_supers()
3776 head = &fs_info->fs_devices->devices; in write_all_supers()
3783 &fs_info->fs_devices->device_list_mutex); in write_all_supers()
3810 memcpy(dev_item->fsid, dev->fs_devices->metadata_uuid, in write_all_supers()
3818 mutex_unlock(&fs_info->fs_devices->device_list_mutex); in write_all_supers()
3831 mutex_unlock(&fs_info->fs_devices->device_list_mutex); in write_all_supers()
3852 mutex_unlock(&fs_info->fs_devices->device_list_mutex); in write_all_supers()
4049 btrfs_sysfs_remove_fsid(fs_info->fs_devices); in close_ctree()
4071 btrfsic_unmount(fs_info->fs_devices); in close_ctree()
4075 btrfs_close_devices(fs_info->fs_devices); in close_ctree()