Thread (9 messages) 9 messages, 4 authors, 2018-08-06

Re: [PATCH 2/3] block: kill QUEUE_FLAG_NO_SG_MERGE

From: Ming Lei <hidden>
Date: 2018-08-01 23:11:12

On Wed, Aug 01, 2018 at 04:54:02PM +0200, Christoph Hellwig wrote:
We still hit __blk_recalc_rq_segments at least once per submission,
don't we?  Either rather wait with this until we have multi-page bvecs.
No.

Please see blk_queue_split(), where the physical segment number is
always updated, and the flag of BIO_SEG_VALID is set meantime.

And for callers of blk_recount_segments(), it will check the VALID flag
first, and blk_recount_segments() is only run when this flag isn't set.

blk_recount_segments
    bio_phys_segments
        ll_new_hw_segment
            ll_back_merge_fn
            ll_front_merge_fn 
        blk_rq_bio_prep
            blk_rq_append_bio
            blk_init_request_from_bio
    bio_add_pc_page
    ll_back_merge_fn
    ll_front_merge_fn


Thanks,
Ming
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help