/linux-4.4.14/drivers/md/ |
D | md.c | 79 static int remove_and_add_spares(struct mddev *mddev, 81 static void mddev_detach(struct mddev *mddev); 104 static inline int speed_min(struct mddev *mddev) in speed_min() argument 106 return mddev->sync_speed_min ? in speed_min() 107 mddev->sync_speed_min : sysctl_speed_limit_min; in speed_min() 110 static inline int speed_max(struct mddev *mddev) in speed_max() argument 112 return mddev->sync_speed_max ? in speed_max() 113 mddev->sync_speed_max : sysctl_speed_limit_max; in speed_max() 165 struct mddev *mddev) in bio_alloc_mddev() argument 169 if (!mddev || !mddev->bio_set) in bio_alloc_mddev() [all …]
|
D | md.h | 45 struct mddev *mddev; /* RAID array if running */ member 220 struct mddev { struct 465 void (*sync_super)(struct mddev *mddev, struct md_rdev *rdev); argument 469 static inline int __must_check mddev_lock(struct mddev *mddev) in mddev_lock() argument 471 return mutex_lock_interruptible(&mddev->reconfig_mutex); in mddev_lock() 477 static inline void mddev_lock_nointr(struct mddev *mddev) in mddev_lock_nointr() argument 479 mutex_lock(&mddev->reconfig_mutex); in mddev_lock_nointr() 482 static inline int mddev_is_locked(struct mddev *mddev) in mddev_is_locked() argument 484 return mutex_is_locked(&mddev->reconfig_mutex); in mddev_is_locked() 487 static inline int mddev_trylock(struct mddev *mddev) in mddev_trylock() argument [all …]
|
D | raid0.c | 28 static int raid0_congested(struct mddev *mddev, int bits) in raid0_congested() argument 30 struct r0conf *conf = mddev->private; in raid0_congested() 46 static void dump_zones(struct mddev *mddev) in dump_zones() argument 52 struct r0conf *conf = mddev->private; in dump_zones() 55 mdname(mddev), in dump_zones() 76 static int create_strip_zones(struct mddev *mddev, struct r0conf **private_conf) in create_strip_zones() argument 90 rdev_for_each(rdev1, mddev) { in create_strip_zones() 92 mdname(mddev), in create_strip_zones() 98 sector_div(sectors, mddev->chunk_sectors); in create_strip_zones() 99 rdev1->sectors = sectors * mddev->chunk_sectors; in create_strip_zones() [all …]
|
D | md-cluster.h | 8 struct mddev; 12 int (*join)(struct mddev *mddev, int nodes); 13 int (*leave)(struct mddev *mddev); 14 int (*slot_number)(struct mddev *mddev); 15 int (*resync_info_update)(struct mddev *mddev, sector_t lo, sector_t hi); 16 int (*metadata_update_start)(struct mddev *mddev); 17 int (*metadata_update_finish)(struct mddev *mddev); 18 void (*metadata_update_cancel)(struct mddev *mddev); 19 int (*resync_start)(struct mddev *mddev); 20 int (*resync_finish)(struct mddev *mddev); [all …]
|
D | linear.c | 30 static inline struct dev_info *which_dev(struct mddev *mddev, sector_t sector) in which_dev() argument 36 hi = mddev->raid_disks - 1; in which_dev() 37 conf = mddev->private; in which_dev() 55 static int linear_congested(struct mddev *mddev, int bits) in linear_congested() argument 60 conf = mddev->private; in linear_congested() 62 for (i = 0; i < mddev->raid_disks && !ret ; i++) { in linear_congested() 70 static sector_t linear_size(struct mddev *mddev, sector_t sectors, int raid_disks) in linear_size() argument 75 conf = mddev->private; in linear_size() 83 static struct linear_conf *linear_conf(struct mddev *mddev, int raid_disks) in linear_conf() argument 98 rdev_for_each(rdev, mddev) { in linear_conf() [all …]
|
D | md-cluster.c | 30 struct mddev *mddev; /* pointing back to mddev. */ member 120 static struct dlm_lock_resource *lockres_init(struct mddev *mddev, in lockres_init() argument 125 struct md_cluster_info *cinfo = mddev->cluster_info; in lockres_init() 132 res->mddev = mddev; in lockres_init() 208 static struct suspend_info *read_resync_info(struct mddev *mddev, struct dlm_lock_resource *lockres) in read_resync_info() argument 231 struct mddev *mddev = thread->mddev; in recover_bitmaps() local 232 struct md_cluster_info *cinfo = mddev->cluster_info; in recover_bitmaps() 252 bm_lockres = lockres_init(mddev, str, NULL, 1); in recover_bitmaps() 264 ret = bitmap_copy_from_slot(mddev, slot, &lo, &hi, true); in recover_bitmaps() 271 set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); in recover_bitmaps() [all …]
|
D | multipath.c | 61 struct mddev *mddev = mp_bh->mddev; in multipath_reschedule_retry() local 62 struct mpconf *conf = mddev->private; in multipath_reschedule_retry() 67 md_wakeup_thread(mddev->thread); in multipath_reschedule_retry() 78 struct mpconf *conf = mp_bh->mddev->private; in multipath_end_bh_io() 88 struct mpconf *conf = mp_bh->mddev->private; in multipath_end_request() 98 md_error (mp_bh->mddev, rdev); in multipath_end_request() 105 rdev_dec_pending(rdev, conf->mddev); in multipath_end_request() 108 static void multipath_make_request(struct mddev *mddev, struct bio * bio) in multipath_make_request() argument 110 struct mpconf *conf = mddev->private; in multipath_make_request() 115 md_flush_request(mddev, bio); in multipath_make_request() [all …]
|
D | bitmap.c | 35 return bitmap->mddev ? mdname(bitmap->mddev) : "mdX"; in bmname() 145 static int read_sb_page(struct mddev *mddev, loff_t offset, in read_sb_page() argument 154 rdev_for_each(rdev, mddev) { in read_sb_page() 171 static struct md_rdev *next_active_rdev(struct md_rdev *rdev, struct mddev *mddev) in next_active_rdev() argument 189 rdev = list_entry(&mddev->disks, struct md_rdev, same_set); in next_active_rdev() 192 rdev_dec_pending(rdev, mddev); in next_active_rdev() 194 list_for_each_entry_continue_rcu(rdev, &mddev->disks, same_set) { in next_active_rdev() 211 struct mddev *mddev = bitmap->mddev; in write_sb_page() local 215 if (mddev_is_clustered(bitmap->mddev)) in write_sb_page() 218 while ((rdev = next_active_rdev(rdev, mddev)) != NULL) { in write_sb_page() [all …]
|
D | raid1.c | 124 if (test_bit(MD_RECOVERY_REQUESTED, &pi->mddev->recovery)) in r1buf_pool_alloc() 136 if (!test_bit(MD_RECOVERY_REQUESTED, &pi->mddev->recovery)) { in r1buf_pool_alloc() 195 struct r1conf *conf = r1_bio->mddev->private; in free_r1bio() 203 struct r1conf *conf = r1_bio->mddev->private; in put_buf() 209 rdev_dec_pending(conf->mirrors[i].rdev, r1_bio->mddev); in put_buf() 220 struct mddev *mddev = r1_bio->mddev; in reschedule_retry() local 221 struct r1conf *conf = mddev->private; in reschedule_retry() 229 md_wakeup_thread(mddev->thread); in reschedule_retry() 241 struct r1conf *conf = r1_bio->mddev->private; in call_bio_endio() 293 struct r1conf *conf = r1_bio->mddev->private; in update_head_pos() [all …]
|
D | raid10.c | 102 static sector_t reshape_request(struct mddev *mddev, sector_t sector_nr, 104 static void reshape_request_write(struct mddev *mddev, struct r10bio *r10_bio); 151 if (test_bit(MD_RECOVERY_SYNC, &conf->mddev->recovery) || in r10buf_pool_alloc() 152 test_bit(MD_RECOVERY_RESHAPE, &conf->mddev->recovery)) in r10buf_pool_alloc() 181 &conf->mddev->recovery)) { in r10buf_pool_alloc() 259 struct r10conf *conf = r10_bio->mddev->private; in free_r10bio() 267 struct r10conf *conf = r10_bio->mddev->private; in put_buf() 277 struct mddev *mddev = r10_bio->mddev; in reschedule_retry() local 278 struct r10conf *conf = mddev->private; in reschedule_retry() 288 md_wakeup_thread(mddev->thread); in reschedule_retry() [all …]
|
D | raid5.c | 267 md_wakeup_thread(conf->mddev->thread); in raid5_wakeup_stripe_thread() 311 md_wakeup_thread(conf->mddev->thread); in do_release_stripe() 317 md_wakeup_thread(conf->mddev->thread); in do_release_stripe() 376 md_wakeup_thread(conf->mddev->thread); in release_inactive_stripe_list() 424 if (unlikely(!conf->mddev->thread) || in raid5_release_stripe() 429 md_wakeup_thread(conf->mddev->thread); in raid5_release_stripe() 647 if (conf->mddev->reshape_position == MaxSector) in has_failed() 648 return conf->mddev->degraded > conf->max_degraded; in has_failed() 841 md_wakeup_thread(conf->mddev->thread); in stripe_add_to_batch_list() 969 if (!conf->mddev->external && in ops_run_io() [all …]
|
D | faulty.c | 173 static void make_request(struct mddev *mddev, struct bio *bio) in make_request() argument 175 struct faulty_conf *conf = mddev->private; in make_request() 217 struct bio *b = bio_clone_mddev(bio, GFP_NOIO, mddev); in make_request() 229 static void status(struct seq_file *seq, struct mddev *mddev) in status() argument 231 struct faulty_conf *conf = mddev->private; in status() 262 static int reshape(struct mddev *mddev) in reshape() argument 264 int mode = mddev->new_layout & ModeMask; in reshape() 265 int count = mddev->new_layout >> ModeShift; in reshape() 266 struct faulty_conf *conf = mddev->private; in reshape() 268 if (mddev->new_layout < 0) in reshape() [all …]
|
D | dm-raid.c | 69 struct mddev md; 241 rs->dev[i].rdev.mddev = &rs->md; in dev_parms() 798 md_error(rdev->mddev, rdev); in read_disk_sb() 807 static void super_sync(struct mddev *mddev, struct md_rdev *rdev) in super_sync() argument 812 struct raid_set *rs = container_of(mddev, struct raid_set, md); in super_sync() 817 for (i = 0; i < mddev->raid_disks; i++) in super_sync() 827 sb->num_devices = cpu_to_le32(mddev->raid_disks); in super_sync() 830 sb->events = cpu_to_le64(mddev->events); in super_sync() 834 sb->array_resync_offset = cpu_to_le64(mddev->recovery_cp); in super_sync() 836 sb->level = cpu_to_le32(mddev->level); in super_sync() [all …]
|
D | bitmap.h | 194 struct mddev *mddev; /* the md device that the bitmap is for */ member 238 struct bitmap *bitmap_create(struct mddev *mddev, int slot); 239 int bitmap_load(struct mddev *mddev); 240 void bitmap_flush(struct mddev *mddev); 241 void bitmap_destroy(struct mddev *mddev); 263 void bitmap_daemon_work(struct mddev *mddev); 267 int bitmap_copy_from_slot(struct mddev *mddev, int slot,
|
D | raid1.h | 27 struct mddev *mddev; member 32 struct mddev *mddev; member 141 struct mddev *mddev; member
|
D | multipath.h | 9 struct mddev *mddev; member 25 struct mddev *mddev; member
|
D | raid5-cache.c | 216 md_error(log->rdev->mddev, log->rdev); in r5l_log_endio() 230 md_wakeup_thread(log->rdev->mddev->thread); in r5l_log_endio() 604 md_error(log->rdev->mddev, log->rdev); in r5l_log_flush_endio() 657 struct mddev *mddev; in r5l_write_super_and_discard_space() local 664 mddev = log->rdev->mddev; in r5l_write_super_and_discard_space() 675 set_bit(MD_CHANGE_DEVS, &mddev->flags); in r5l_write_super_and_discard_space() 676 set_bit(MD_CHANGE_PENDING, &mddev->flags); in r5l_write_super_and_discard_space() 677 md_wakeup_thread(mddev->thread); in r5l_write_super_and_discard_space() 678 wait_event(mddev->sb_wait, in r5l_write_super_and_discard_space() 679 !test_bit(MD_CHANGE_PENDING, &mddev->flags) || in r5l_write_super_and_discard_space() [all …]
|
D | raid10.h | 15 struct mddev *mddev; member 105 struct mddev *mddev; member
|
D | raid5.h | 439 struct mddev *mddev; member 620 extern int raid5_set_cache_size(struct mddev *mddev, int size);
|