block: pass a queue_limits argument to blk_mq_init_queue
authorChristoph Hellwig <hch@lst.de>
Tue, 13 Feb 2024 07:34:19 +0000 (08:34 +0100)
committerJens Axboe <axboe@kernel.dk>
Tue, 13 Feb 2024 15:56:59 +0000 (08:56 -0700)
commit9ac4dd8c47d533eb420af6a679e66ec74771125c
tree6b5b5e8709f382368160756db5ac5629d59e94cd
parentad751ba1f8d5d4f4f4b429b552a154e888524a93
block: pass a queue_limits argument to blk_mq_init_queue

Pass a queue_limits to blk_mq_init_queue and apply it if non-NULL.  This
will allow allocating queues with valid queue limits instead of setting
the values one at a time later.

Also rename the function to blk_mq_alloc_queue as that is a much better
name for a function that allocates a queue and always pass the queuedata
argument instead of having a separate version for the extra argument.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Keith Busch <kbusch@kernel.org>
Reviewed-by: John Garry <john.g.garry@oracle.com>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Reviewed-by: Ming Lei <ming.lei@redhat.com>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Link: https://lore.kernel.org/r/20240213073425.1621680-10-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq.c
block/bsg-lib.c
drivers/nvme/host/apple.c
drivers/nvme/host/core.c
drivers/scsi/scsi_scan.c
drivers/ufs/core/ufshcd.c
include/linux/blk-mq.h