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

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

index 1e2aa5ae27963c3fe72fecd2e11a4b013f63abb2..5498f1cf36b3fe07d54797cc295f2c31d6e6eeee 100644 (file)
@@ -521,7 +521,8 @@ static int mm_check_plugged(struct cardinfo *card)
 
 static blk_qc_t mm_make_request(struct request_queue *q, struct bio *bio)
 {
-       struct cardinfo *card = q->queuedata;
+       struct cardinfo *card = bio->bi_disk->private_data;
+
        pr_debug("mm_make_request %llu %u\n",
                 (unsigned long long)bio->bi_iter.bi_sector,
                 bio->bi_iter.bi_size);
@@ -888,7 +889,6 @@ static int mm_pci_probe(struct pci_dev *dev, const struct pci_device_id *id)
        card->queue = blk_alloc_queue(mm_make_request, NUMA_NO_NODE);
        if (!card->queue)
                goto failed_alloc;
-       card->queue->queuedata = card;
 
        tasklet_init(&card->tasklet, process_page, (unsigned long)card);