md/raid1/10: remove unused queue
authorLidong Zhong <lidong.zhong@suse.com>
Fri, 21 Apr 2017 07:21:38 +0000 (15:21 +0800)
committerShaohua Li <shli@fb.com>
Sun, 23 Apr 2017 23:59:13 +0000 (16:59 -0700)
A queue is declared and get from the disk of the array, but it's not
used anywhere. So removing it from the source.

Signed-off-by: Lidong Zhong <lzhong@suse.com>
Acted-by: Guoqing Jiang <gqjiang@suse.com>
Signed-off-by: Shaohua Li <shli@fb.com>
drivers/md/raid1.c
drivers/md/raid10.c

index 57611f43ed6c54dacf76ee295051473ac89b7bde..14a9d36b25b8f681549055cec283643bb3a5c756 100644 (file)
@@ -2961,7 +2961,6 @@ static struct r1conf *setup_conf(struct mddev *mddev)
        err = -EINVAL;
        spin_lock_init(&conf->device_lock);
        rdev_for_each(rdev, mddev) {
-               struct request_queue *q;
                int disk_idx = rdev->raid_disk;
                if (disk_idx >= mddev->raid_disks
                    || disk_idx < 0)
@@ -2974,8 +2973,6 @@ static struct r1conf *setup_conf(struct mddev *mddev)
                if (disk->rdev)
                        goto abort;
                disk->rdev = rdev;
-               q = bdev_get_queue(rdev->bdev);
-
                disk->head_position = 0;
                disk->seq_start = MaxSector;
        }
index acb3f46f522f792a3315fdf165fa7cb67c2bd77d..5de951bcd24c035833b751ce9e2771d2efb011f9 100644 (file)
@@ -3644,7 +3644,6 @@ static int raid10_run(struct mddev *mddev)
 
        rdev_for_each(rdev, mddev) {
                long long diff;
-               struct request_queue *q;
 
                disk_idx = rdev->raid_disk;
                if (disk_idx < 0)
@@ -3663,7 +3662,6 @@ static int raid10_run(struct mddev *mddev)
                                goto out_free_conf;
                        disk->rdev = rdev;
                }
-               q = bdev_get_queue(rdev->bdev);
                diff = (rdev->new_data_offset - rdev->data_offset);
                if (!mddev->reshape_backwards)
                        diff = -diff;