Commit e4fc5a74 authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Song Liu

md: stop using ->queuedata

Pointer to mddev is already available in private_data.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarSong Liu <songliubraving@fb.com>
parent c91114c2
...@@ -467,7 +467,7 @@ static blk_qc_t md_make_request(struct request_queue *q, struct bio *bio) ...@@ -467,7 +467,7 @@ static blk_qc_t md_make_request(struct request_queue *q, struct bio *bio)
{ {
const int rw = bio_data_dir(bio); const int rw = bio_data_dir(bio);
const int sgrp = op_stat_group(bio_op(bio)); const int sgrp = op_stat_group(bio_op(bio));
struct mddev *mddev = q->queuedata; struct mddev *mddev = bio->bi_disk->private_data;
unsigned int sectors; unsigned int sectors;
if (unlikely(test_bit(MD_BROKEN, &mddev->flags)) && (rw == WRITE)) { if (unlikely(test_bit(MD_BROKEN, &mddev->flags)) && (rw == WRITE)) {
...@@ -5644,7 +5644,6 @@ static int md_alloc(dev_t dev, char *name) ...@@ -5644,7 +5644,6 @@ static int md_alloc(dev_t dev, char *name)
mddev->queue = blk_alloc_queue(md_make_request, NUMA_NO_NODE); mddev->queue = blk_alloc_queue(md_make_request, NUMA_NO_NODE);
if (!mddev->queue) if (!mddev->queue)
goto abort; goto abort;
mddev->queue->queuedata = mddev;
blk_set_stacking_limits(&mddev->queue->limits); blk_set_stacking_limits(&mddev->queue->limits);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment