diff options
author | Bart Van Assche <bvanassche@acm.org> | 2021-06-18 02:44:52 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-06-21 23:03:40 +0200 |
commit | d672d325b1492f5b0e54b7226f01e2d57b58bfb4 (patch) | |
tree | a9a5dea29e7aac94a5dfd5d3b2f3b36457c04eab /Makefile | |
parent | block/mq-deadline: Reserve 25% of scheduler tags for synchronous requests (diff) | |
download | linux-d672d325b1492f5b0e54b7226f01e2d57b58bfb4.tar.xz linux-d672d325b1492f5b0e54b7226f01e2d57b58bfb4.zip |
block/mq-deadline: Micro-optimize the batching algorithm
When dispatching the first request of a batch, the deadline_move_request()
call clears .next_rq[] for the opposite data direction. .next_rq[] is not
restored when changing data direction. Fix this by not clearing .next_rq[]
and by keeping track of the data direction of a batch in a variable instead.
This patch is a micro-optimization because:
- The number of deadline_next_request() calls for the read direction is
halved.
- The number of times that deadline_next_request() returns NULL is reduced.
Cc: Damien Le Moal <damien.lemoal@wdc.com>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Ming Lei <ming.lei@redhat.com>
Cc: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Cc: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link: https://lore.kernel.org/r/20210618004456.7280-13-bvanassche@acm.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'Makefile')
0 files changed, 0 insertions, 0 deletions