diff options
author | Christoph Hellwig <hch@lst.de> | 2021-06-02 09:53:31 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-06-11 11:53:03 -0600 |
commit | 6560ec961a080944f8d5e1fef17b771bfaf189cb (patch) | |
tree | d62ba5f09243b65a339789191d46d2180bc5190a /drivers/block/aoe/aoedev.c | |
parent | blk-mq: remove blk_mq_init_sq_queue (diff) | |
download | linux-dev-6560ec961a080944f8d5e1fef17b771bfaf189cb.tar.xz linux-dev-6560ec961a080944f8d5e1fef17b771bfaf189cb.zip |
aoe: use blk_mq_alloc_disk and blk_cleanup_disk
Use blk_mq_alloc_disk and blk_cleanup_disk to simplify the gendisk and
request_queue allocation.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Link: https://lore.kernel.org/r/20210602065345.355274-17-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/block/aoe/aoedev.c')
-rw-r--r-- | drivers/block/aoe/aoedev.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/block/aoe/aoedev.c b/drivers/block/aoe/aoedev.c index e2ea2356da06..c5753c6bfe80 100644 --- a/drivers/block/aoe/aoedev.c +++ b/drivers/block/aoe/aoedev.c @@ -277,9 +277,8 @@ freedev(struct aoedev *d) if (d->gd) { aoedisk_rm_debugfs(d); del_gendisk(d->gd); - put_disk(d->gd); + blk_cleanup_disk(d->gd); blk_mq_free_tag_set(&d->tag_set); - blk_cleanup_queue(d->blkq); } t = d->targets; e = t + d->ntargets; |