Commit 92aff191 authored by Jens Axboe's avatar Jens Axboe

block: prefetch request to be initialized

Now we have the tags available in __blk_mq_alloc_requests_batch(), we
can start fetching the first request cacheline before calling into the
request initialization.
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
Link: https://lore.kernel.org/r/20211019153300.623322-4-axboe@kernel.dkSigned-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent fe6134f6
...@@ -405,6 +405,7 @@ __blk_mq_alloc_requests_batch(struct blk_mq_alloc_data *data, ...@@ -405,6 +405,7 @@ __blk_mq_alloc_requests_batch(struct blk_mq_alloc_data *data,
for (i = 0; tag_mask; i++) { for (i = 0; tag_mask; i++) {
if (!(tag_mask & (1UL << i))) if (!(tag_mask & (1UL << i)))
continue; continue;
prefetch(tags->static_rqs[tag]);
tag = tag_offset + i; tag = tag_offset + i;
tag_mask &= ~(1UL << i); tag_mask &= ~(1UL << i);
rq = blk_mq_rq_ctx_init(data, tags, tag, alloc_time_ns); rq = blk_mq_rq_ctx_init(data, tags, tag, alloc_time_ns);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment