Thread (12 messages) flat view 12 messages, 4 authors, 2021-11-12

Re: [PATCH] blk-mq: setup blk_mq_alloc_data.cmd_flags after submit_bio_checks() is done

From: Christoph Hellwig <hch@lst.de>
Date: 2021-11-12 08:21:44

On Fri, Nov 12, 2021 at 04:11:37PM +0800, Ming Lei wrote:
quoted hunk ↗ jump to hunk
@@ -2564,13 +2564,15 @@ static inline struct request *blk_mq_get_request(struct request_queue *q,
 			if (blk_mq_attempt_bio_merge(q, bio, nsegs,
 						same_queue_rq))
 				return NULL;
+			if (bio->bi_opf != rq->cmd_flags)
+				goto fallback;
I think this deserves a comment, as this means a read prealloc
can only be used for reads, and no fua can be set if the preallocating
I/O didn't use fua, etc.

What are the pitfalls of just chanigng cmd_flags?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help