OSDN Git Service

blk-mq: add the blk_mq_alloc_disk APIs
authorChristoph Hellwig <hch@lst.de>
Wed, 2 Jun 2021 06:53:18 +0000 (09:53 +0300)
committerJens Axboe <axboe@kernel.dk>
Fri, 11 Jun 2021 17:53:02 +0000 (11:53 -0600)
commitb461dfc49eb6fbabc60b9dad476e787ada56b7b4
tree8858c13ab206fcfaa8bb8828b1e40d84341f788c
parent26a9750aa875126e4b7fc5ee6de652a529c5b7ee
blk-mq: add the blk_mq_alloc_disk APIs

Add a new API to allocate a gendisk including the request_queue for use
with blk-mq based drivers.  This is to avoid boilerplate code in drivers.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Link: https://lore.kernel.org/r/20210602065345.355274-4-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq.c
include/linux/blk-mq.h