Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\blk-merge.c Create Date:2022-07-28 17:06:09
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:ll_merge_requests_fn

Proto:static int ll_merge_requests_fn(struct request_queue *q, struct request *req, struct request *next)

Type:int

Parameter:

TypeParameterName
struct request_queue *q
struct request *req
struct request *next
647  If req_gap_back_merge(req, bio) Then Return 0
653  If blk_rq_sectors(req) + blk_rq_sectors(next) > blk_rq_get_max_sectors(req, lk_rq_pos() : the current sector* blk_rq_bytes() : bytes left in the entire request* blk_rq_cur_bytes() : bytes left in the current segment* blk_rq_err_bytes() : bytes left till the next error boundary* blk_rq_sectors() : sectors left in the entire ) Then Return 0
657  total_phys_segments = * Number of scatter-gather DMA addr+len pairs after * physical address coalescing is performed. + * Number of scatter-gather DMA addr+len pairs after * physical address coalescing is performed.
658  If total_phys_segments > queue_max_segments(q) Then Return 0
661  If (blk_integrity_merge_rq(q, req, next) == false) Then Return 0
665  * Number of scatter-gather DMA addr+len pairs after * physical address coalescing is performed. = total_phys_segments
666  Return 1
Caller
NameDescribe
attempt_mergeFor non-mq, this has to be called with the request spinlock acquired.* For mq with scheduling, the appropriate queue wide lock should be held.