diff options
Diffstat (limited to 'fs/btrfs/volumes.h')
-rw-r--r-- | fs/btrfs/volumes.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/fs/btrfs/volumes.h b/fs/btrfs/volumes.h index 12f297eb0559..35dec3efd78c 100644 --- a/fs/btrfs/volumes.h +++ b/fs/btrfs/volumes.h | |||
@@ -18,12 +18,16 @@ | |||
18 | 18 | ||
19 | #ifndef __BTRFS_VOLUMES_ | 19 | #ifndef __BTRFS_VOLUMES_ |
20 | #define __BTRFS_VOLUMES_ | 20 | #define __BTRFS_VOLUMES_ |
21 | |||
21 | struct btrfs_device { | 22 | struct btrfs_device { |
22 | struct list_head dev_list; | 23 | struct list_head dev_list; |
23 | struct btrfs_root *dev_root; | 24 | struct btrfs_root *dev_root; |
25 | spinlock_t io_lock; | ||
24 | 26 | ||
25 | struct block_device *bdev; | 27 | struct block_device *bdev; |
26 | 28 | ||
29 | u64 total_ios; | ||
30 | |||
27 | char *name; | 31 | char *name; |
28 | 32 | ||
29 | /* the internal btrfs device id */ | 33 | /* the internal btrfs device id */ |
@@ -68,9 +72,9 @@ struct btrfs_fs_devices { | |||
68 | int btrfs_alloc_dev_extent(struct btrfs_trans_handle *trans, | 72 | int btrfs_alloc_dev_extent(struct btrfs_trans_handle *trans, |
69 | struct btrfs_device *device, | 73 | struct btrfs_device *device, |
70 | u64 owner, u64 num_bytes, u64 *start); | 74 | u64 owner, u64 num_bytes, u64 *start); |
71 | int btrfs_map_block(struct btrfs_mapping_tree *map_tree, | 75 | int btrfs_map_block(struct btrfs_mapping_tree *map_tree, int rw, int stripe_nr, |
72 | u64 logical, u64 *phys, u64 *length, | 76 | u64 logical, u64 *phys, u64 *length, |
73 | struct btrfs_device **dev); | 77 | struct btrfs_device **dev, int *total_stripes); |
74 | int btrfs_read_sys_array(struct btrfs_root *root); | 78 | int btrfs_read_sys_array(struct btrfs_root *root); |
75 | int btrfs_read_chunk_tree(struct btrfs_root *root); | 79 | int btrfs_read_chunk_tree(struct btrfs_root *root); |
76 | int btrfs_alloc_chunk(struct btrfs_trans_handle *trans, | 80 | int btrfs_alloc_chunk(struct btrfs_trans_handle *trans, |
@@ -80,9 +84,6 @@ void btrfs_mapping_init(struct btrfs_mapping_tree *tree); | |||
80 | void btrfs_mapping_tree_free(struct btrfs_mapping_tree *tree); | 84 | void btrfs_mapping_tree_free(struct btrfs_mapping_tree *tree); |
81 | int btrfs_map_bio(struct btrfs_root *root, int rw, struct bio *bio); | 85 | int btrfs_map_bio(struct btrfs_root *root, int rw, struct bio *bio); |
82 | int btrfs_read_super_device(struct btrfs_root *root, struct extent_buffer *buf); | 86 | int btrfs_read_super_device(struct btrfs_root *root, struct extent_buffer *buf); |
83 | int btrfs_map_block(struct btrfs_mapping_tree *map_tree, | ||
84 | u64 logical, u64 *phys, u64 *length, | ||
85 | struct btrfs_device **dev); | ||
86 | int btrfs_open_devices(struct btrfs_fs_devices *fs_devices, | 87 | int btrfs_open_devices(struct btrfs_fs_devices *fs_devices, |
87 | int flags, void *holder); | 88 | int flags, void *holder); |
88 | int btrfs_scan_one_device(const char *path, int flags, void *holder, | 89 | int btrfs_scan_one_device(const char *path, int flags, void *holder, |