]> www.infradead.org Git - users/hch/block.git/commitdiff
dm: stop using ->queuedata queuedata-cleanup
authorChristoph Hellwig <hch@lst.de>
Sun, 29 Mar 2020 17:36:57 +0000 (19:36 +0200)
committerChristoph Hellwig <hch@lst.de>
Fri, 26 Jun 2020 09:25:00 +0000 (11:25 +0200)
Instead of setting up the queuedata as well just use one private data
field.

Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/md/dm.c

index 109e81f33edb2d24a06b19a83bd674b238c075b2..57f4e5a74c8918e680f961a18d7233df205747a0 100644 (file)
@@ -1790,7 +1790,7 @@ static blk_qc_t dm_process_bio(struct mapped_device *md,
 
 static blk_qc_t dm_make_request(struct request_queue *q, struct bio *bio)
 {
-       struct mapped_device *md = q->queuedata;
+       struct mapped_device *md = bio->bi_disk->private_data;
        blk_qc_t ret = BLK_QC_T_NONE;
        int srcu_idx;
        struct dm_table *map;
@@ -1996,7 +1996,6 @@ static struct mapped_device *alloc_dev(int minor)
        md->queue = blk_alloc_queue(dm_make_request, numa_node_id);
        if (!md->queue)
                goto bad;
-       md->queue->queuedata = md;
 
        md->disk = alloc_disk_node(1, md->numa_node_id);
        if (!md->disk)