From: Valentin Kleibel <valentin@vrvis.at>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: stable@vger.kernel.org, Jens Axboe <axboe@kernel.dk>,
Justin Sanders <justin@coraid.com>,
linux-block@vger.kernel.org
Subject: [PATCH v2 2/2] aoe: use blk_mq_alloc_disk and blk_cleanup_disk
Date: Thu, 31 Mar 2022 12:01:20 +0200 [thread overview]
Message-ID: <774968b2-5d34-0f36-5ec6-284aaabb4585@vrvis.at> (raw)
In-Reply-To: <b19953f8-2097-6962-eceb-5d41f4639ce4@vrvis.at>
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>
(cherry picked from commit 6560ec961a080944f8d5e1fef17b771bfaf189cb)
Fixes: 3582dd291788 (aoe: convert aoeblk to blk-mq)
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=215647
Signed-off-by: Valentin Kleibel <valentin@vrvis.at>
---
drivers/block/aoe/aoedev.c | 3 +--
1 file changed, 1 insertion(+), 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;
prev parent reply other threads:[~2022-03-31 10:01 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-10 11:53 [PATCH] block: aoe: fix page fault in freedev() Valentin Kleibel
2022-03-10 12:03 ` Greg Kroah-Hartman
2022-03-10 12:24 ` Valentin Kleibel
2022-03-10 12:26 ` Greg Kroah-Hartman
2022-03-10 12:55 ` Valentin Kleibel
2022-03-14 11:12 ` Greg Kroah-Hartman
2022-03-31 9:58 ` [PATCH v2 0/2] " Valentin Kleibel
2022-03-31 10:00 ` [PATCH v2 1/2] block: add blk_alloc_disk and blk_cleanup_disk APIs Valentin Kleibel
2022-04-11 14:43 ` Greg Kroah-Hartman
2022-03-31 10:01 ` Valentin Kleibel [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=774968b2-5d34-0f36-5ec6-284aaabb4585@vrvis.at \
--to=valentin@vrvis.at \
--cc=axboe@kernel.dk \
--cc=gregkh@linuxfoundation.org \
--cc=justin@coraid.com \
--cc=linux-block@vger.kernel.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox