aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/raid10.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2010-04-01 00:02:13 -0400
committerNeilBrown <neilb@suse.de>2010-05-18 01:27:55 -0400
commit21a52c6d05c15f862797736393915bfa8cd40ee9 (patch)
tree44ffb633d209457979177a52132761a368fcb976 /drivers/md/raid10.c
parentcca9cf90c504d98644ace52c474770970729f0eb (diff)
md: pass mddev to make_request functions rather than request_queue
We used to pass the personality make_request function direct to the block layer so the first argument had to be a queue. But now we have the intermediary md_make_request so it makes at lot more sense to pass a struct mddev_s. It makes it possible to have an mddev without its own queue too. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/raid10.c')
-rw-r--r--drivers/md/raid10.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c
index ca313d646fd1..a1d727610a49 100644
--- a/drivers/md/raid10.c
+++ b/drivers/md/raid10.c
@@ -788,9 +788,8 @@ static void unfreeze_array(conf_t *conf)
788 spin_unlock_irq(&conf->resync_lock); 788 spin_unlock_irq(&conf->resync_lock);
789} 789}
790 790
791static int make_request(struct request_queue *q, struct bio * bio) 791static int make_request(mddev_t *mddev, struct bio * bio)
792{ 792{
793 mddev_t *mddev = q->queuedata;
794 conf_t *conf = mddev->private; 793 conf_t *conf = mddev->private;
795 mirror_info_t *mirror; 794 mirror_info_t *mirror;
796 r10bio_t *r10_bio; 795 r10bio_t *r10_bio;
@@ -824,9 +823,9 @@ static int make_request(struct request_queue *q, struct bio * bio)
824 */ 823 */
825 bp = bio_split(bio, 824 bp = bio_split(bio,
826 chunk_sects - (bio->bi_sector & (chunk_sects - 1)) ); 825 chunk_sects - (bio->bi_sector & (chunk_sects - 1)) );
827 if (make_request(q, &bp->bio1)) 826 if (make_request(mddev, &bp->bio1))
828 generic_make_request(&bp->bio1); 827 generic_make_request(&bp->bio1);
829 if (make_request(q, &bp->bio2)) 828 if (make_request(mddev, &bp->bio2))
830 generic_make_request(&bp->bio2); 829 generic_make_request(&bp->bio2);
831 830
832 bio_pair_release(bp); 831 bio_pair_release(bp);