Movatterモバイル変換


[0]ホーム

URL:


blk_attempt_plug_merge
Prev Chapter 14. Block Devices Next

Name

blk_attempt_plug_merge — try to merge withcurrent's plugged list

Synopsis

boolblk_attempt_plug_merge(struct request_queue *q,
 struct bio *bio,
 unsigned int *request_count,
 struct request **same_queue_rq);
 

Arguments

struct request_queue * q

request_queue new bio is being queued at

struct bio * bio

new bio being queued

unsigned int * request_count

out parameter for number of traversed plugged requests

struct request ** same_queue_rq

pointer tostruct request that gets filled in when another request associated withq is found on the plug list (optional, may beNULL)

Description

Determine whetherbio being queued onq can be merged with a request oncurrent's plugged list. Returnstrue if merge was successful, otherwisefalse.

Plugging coalesces IOs from the same issuer for the same purpose without going throughq->queue_lock. As such it's more of an issuing mechanism than scheduling, and the request, while may have elvpriv data, is not added on the elevator at this point. In addition, we don't have reliable access to the elevator outside queue lock. Only check basic merging parameters without querying the elevator.

Caller must ensure !blk_queue_nomerges(q) beforehand.


Prev Up Next
get_request Home blk_cloned_rq_check_limits

[8]ページ先頭

©2009-2025 Movatter.jp