diff options
Diffstat (limited to 'drivers/md/raid1.c')
-rw-r--r-- | drivers/md/raid1.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c index 08c66afea494..54f60c9e5f85 100644 --- a/drivers/md/raid1.c +++ b/drivers/md/raid1.c | |||
@@ -861,7 +861,7 @@ static int make_request(mddev_t *mddev, struct bio * bio) | |||
861 | } | 861 | } |
862 | r1_bio->read_disk = rdisk; | 862 | r1_bio->read_disk = rdisk; |
863 | 863 | ||
864 | read_bio = bio_clone(bio, GFP_NOIO); | 864 | read_bio = bio_clone_mddev(bio, GFP_NOIO, mddev); |
865 | 865 | ||
866 | r1_bio->bios[rdisk] = read_bio; | 866 | r1_bio->bios[rdisk] = read_bio; |
867 | 867 | ||
@@ -950,7 +950,7 @@ static int make_request(mddev_t *mddev, struct bio * bio) | |||
950 | if (!r1_bio->bios[i]) | 950 | if (!r1_bio->bios[i]) |
951 | continue; | 951 | continue; |
952 | 952 | ||
953 | mbio = bio_clone(bio, GFP_NOIO); | 953 | mbio = bio_clone_mddev(bio, GFP_NOIO, mddev); |
954 | r1_bio->bios[i] = mbio; | 954 | r1_bio->bios[i] = mbio; |
955 | 955 | ||
956 | mbio->bi_sector = r1_bio->sector + conf->mirrors[i].rdev->data_offset; | 956 | mbio->bi_sector = r1_bio->sector + conf->mirrors[i].rdev->data_offset; |
@@ -1640,7 +1640,8 @@ static void raid1d(mddev_t *mddev) | |||
1640 | mddev->ro ? IO_BLOCKED : NULL; | 1640 | mddev->ro ? IO_BLOCKED : NULL; |
1641 | r1_bio->read_disk = disk; | 1641 | r1_bio->read_disk = disk; |
1642 | bio_put(bio); | 1642 | bio_put(bio); |
1643 | bio = bio_clone(r1_bio->master_bio, GFP_NOIO); | 1643 | bio = bio_clone_mddev(r1_bio->master_bio, |
1644 | GFP_NOIO, mddev); | ||
1644 | r1_bio->bios[r1_bio->read_disk] = bio; | 1645 | r1_bio->bios[r1_bio->read_disk] = bio; |
1645 | rdev = conf->mirrors[disk].rdev; | 1646 | rdev = conf->mirrors[disk].rdev; |
1646 | if (printk_ratelimit()) | 1647 | if (printk_ratelimit()) |