diff options
author | Christoph Hellwig <hch@lst.de> | 2024-11-13 16:20:46 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2024-11-13 12:04:58 -0700 |
commit | 00e8d290b55f2fa5c5a0500b4dccf9e090650447 (patch) | |
tree | b100d80c6c93497a9dfa0563317f976c20f02e86 | |
parent | e70c301faece15b618e54b613b1fd6ece3dd05b4 (diff) |
block: don't reorder requests in blk_mq_add_to_batch
LIFO ordering for batched completions is a bit unexpected and also
defeats some merging optimizations in e.g. the XFS buffered write
code. Now that we can easily add the request to the tail of the list
do that.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20241113152050.157179-7-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r-- | include/linux/blk-mq.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/blk-mq.h b/include/linux/blk-mq.h index c61e04365677..c596e0e4cb75 100644 --- a/include/linux/blk-mq.h +++ b/include/linux/blk-mq.h @@ -884,7 +884,7 @@ static inline bool blk_mq_add_to_batch(struct request *req, else if (iob->complete != complete) return false; iob->need_ts |= blk_mq_need_time_stamp(req); - rq_list_add_head(&iob->req_list, req); + rq_list_add_tail(&iob->req_list, req); return true; } |