Files
linux/drivers/block
Dongli Zhang c301c5d382 virtio-blk: limit number of hw queues by nr_cpu_ids
[ Upstream commit bf348f9b78 ]

When tag_set->nr_maps is 1, the block layer limits the number of hw queues
by nr_cpu_ids. No matter how many hw queues are used by virtio-blk, as it
has (tag_set->nr_maps == 1), it can use at most nr_cpu_ids hw queues.

In addition, specifically for pci scenario, when the 'num-queues' specified
by qemu is more than maxcpus, virtio-blk would not be able to allocate more
than maxcpus vectors in order to have a vector for each queue. As a result,
it falls back into MSI-X with one vector for config and one shared for
queues.

Considering above reasons, this patch limits the number of hw queues used
by virtio-blk by nr_cpu_ids.

Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Dongli Zhang <dongli.zhang@oracle.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-05-10 17:52:09 +02:00
..
2016-06-27 12:26:08 -07:00
2016-06-27 12:26:08 -07:00
2011-08-08 11:40:15 +02:00
2016-03-14 09:06:01 -06:00
2016-03-15 15:59:47 -07:00
2016-06-27 12:26:08 -07:00
2016-06-27 12:26:08 -07:00
2013-11-08 09:10:30 -07:00
2009-03-26 21:15:27 +01:00
2018-11-13 11:16:49 -08:00
2016-08-07 14:41:02 -06:00