diff options
Diffstat (limited to 'drivers/md/raid10.c')
-rw-r--r-- | drivers/md/raid10.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c index 25a96c42bdb0..fc6607acb6e4 100644 --- a/drivers/md/raid10.c +++ b/drivers/md/raid10.c | |||
@@ -611,36 +611,6 @@ static void raid10_unplug(struct request_queue *q) | |||
611 | md_wakeup_thread(mddev->thread); | 611 | md_wakeup_thread(mddev->thread); |
612 | } | 612 | } |
613 | 613 | ||
614 | static int raid10_issue_flush(struct request_queue *q, struct gendisk *disk, | ||
615 | sector_t *error_sector) | ||
616 | { | ||
617 | mddev_t *mddev = q->queuedata; | ||
618 | conf_t *conf = mddev_to_conf(mddev); | ||
619 | int i, ret = 0; | ||
620 | |||
621 | rcu_read_lock(); | ||
622 | for (i=0; i<mddev->raid_disks && ret == 0; i++) { | ||
623 | mdk_rdev_t *rdev = rcu_dereference(conf->mirrors[i].rdev); | ||
624 | if (rdev && !test_bit(Faulty, &rdev->flags)) { | ||
625 | struct block_device *bdev = rdev->bdev; | ||
626 | struct request_queue *r_queue = bdev_get_queue(bdev); | ||
627 | |||
628 | if (!r_queue->issue_flush_fn) | ||
629 | ret = -EOPNOTSUPP; | ||
630 | else { | ||
631 | atomic_inc(&rdev->nr_pending); | ||
632 | rcu_read_unlock(); | ||
633 | ret = r_queue->issue_flush_fn(r_queue, bdev->bd_disk, | ||
634 | error_sector); | ||
635 | rdev_dec_pending(rdev, mddev); | ||
636 | rcu_read_lock(); | ||
637 | } | ||
638 | } | ||
639 | } | ||
640 | rcu_read_unlock(); | ||
641 | return ret; | ||
642 | } | ||
643 | |||
644 | static int raid10_congested(void *data, int bits) | 614 | static int raid10_congested(void *data, int bits) |
645 | { | 615 | { |
646 | mddev_t *mddev = data; | 616 | mddev_t *mddev = data; |
@@ -2118,7 +2088,6 @@ static int run(mddev_t *mddev) | |||
2118 | mddev->resync_max_sectors = size << conf->chunk_shift; | 2088 | mddev->resync_max_sectors = size << conf->chunk_shift; |
2119 | 2089 | ||
2120 | mddev->queue->unplug_fn = raid10_unplug; | 2090 | mddev->queue->unplug_fn = raid10_unplug; |
2121 | mddev->queue->issue_flush_fn = raid10_issue_flush; | ||
2122 | mddev->queue->backing_dev_info.congested_fn = raid10_congested; | 2091 | mddev->queue->backing_dev_info.congested_fn = raid10_congested; |
2123 | mddev->queue->backing_dev_info.congested_data = mddev; | 2092 | mddev->queue->backing_dev_info.congested_data = mddev; |
2124 | 2093 | ||