summaryrefslogtreecommitdiff
path: root/certs
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2019-10-25 09:50:10 -0700
committerJens Axboe <axboe@kernel.dk>2019-10-25 14:12:20 -0600
commitf7e76dbc24df695f1b8e88ed3201be22215ec969 (patch)
tree7ffba72420872347d8a556ea42f8c41edc389ebd /certs
parentac0d6b926e741f328b23c8af0134312af7c032d9 (diff)
block: Reduce the amount of memory used for tag sets
Instead of allocating an array of size nr_cpu_ids for set->tags, allocate an array of size set->nr_hw_queues. This patch improves behavior that was introduced by commit 868f2f0b7206 ("blk-mq: dynamic h/w context count"). Reallocating tag sets from inside __blk_mq_update_nr_hw_queues() is safe because: - All request queues that share the tag sets are frozen before the tag sets are reallocated. - blk_mq_queue_tag_busy_iter() holds q->q_usage_counter while active and hence is serialized against __blk_mq_update_nr_hw_queues(). Cc: Keith Busch <keith.busch@intel.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Ming Lei <ming.lei@redhat.com> Cc: Hannes Reinecke <hare@suse.com> Cc: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'certs')
0 files changed, 0 insertions, 0 deletions