diff options
author | Christoph Hellwig <hch@lst.de> | 2017-07-18 11:04:40 -0400 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2017-07-24 12:01:31 -0400 |
commit | 76451d79bde6bed17e113f057e58e1fa5fb79e78 (patch) | |
tree | a3f4f97325b8facb92dea6ac8c05ba987c5704d9 /block/blk-mq-cpumap.c | |
parent | 765e40b675a9566459ddcb8358ad16f3b8344bbe (diff) |
blk-mq: map queues to all present CPUs
We already do this for PCI mappings, and the higher level code now
expects that CPU on/offlining doesn't have an affect on the queue
mappings.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Tested-by: Max Gurtovoy <maxg@mellanox.com>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-mq-cpumap.c')
-rw-r--r-- | block/blk-mq-cpumap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/block/blk-mq-cpumap.c b/block/blk-mq-cpumap.c index 4891f042a22f..9f8cffc8a701 100644 --- a/block/blk-mq-cpumap.c +++ b/block/blk-mq-cpumap.c | |||
@@ -17,9 +17,9 @@ | |||
17 | static int cpu_to_queue_index(unsigned int nr_queues, const int cpu) | 17 | static int cpu_to_queue_index(unsigned int nr_queues, const int cpu) |
18 | { | 18 | { |
19 | /* | 19 | /* |
20 | * Non online CPU will be mapped to queue index 0. | 20 | * Non present CPU will be mapped to queue index 0. |
21 | */ | 21 | */ |
22 | if (!cpu_online(cpu)) | 22 | if (!cpu_present(cpu)) |
23 | return 0; | 23 | return 0; |
24 | return cpu % nr_queues; | 24 | return cpu % nr_queues; |
25 | } | 25 | } |