Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:bfq_insert_request

Proto:static void bfq_insert_request(struct blk_mq_hw_ctx *hctx, struct request *rq, bool at_head)

Type:void

Parameter:

TypeParameterName
struct blk_mq_hw_ctx *hctx
struct request *rq
boolat_head
5493  q = @queue: Pointer to the request queue that owns this hardware context.
5494  bfqd = elevator_data
5496  bool idle_timer_disabled = false
5503  spin_lock_irq( & lock)
5504  If blk_mq_sched_try_insert_merge(q, rq) Then
5505  spin_unlock_irq( & lock)
5506  Return
5509  spin_unlock_irq( & lock)
5511  blk_mq_sched_request_inserted(rq)
5513  spin_lock_irq( & lock)
5514  bfqq = bfq_init_rq(rq)
5515  If Not bfqq || at_head || blk_rq_is_passthrough(rq) Then
5516  If at_head Then list_add - add a new entry*@new: new entry to be added*@head: list head to add it after* Insert a new entry after the specified head.* This is good for implementing stacks.
5518  Else list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
5520  Else
5521  idle_timer_disabled = rns true if it causes the idle timer to be disabled
5527  bfqq = RQ_BFQQ(rq)
5529  If rq_mergeable(rq) Then
5530  elv_rqhash_add(q, rq)
5531  If Not last_merge Then last_merge = rq
5541  cmd_flags = op and common flags
5543  spin_unlock_irq( & lock)
5545  bfq_update_insert_stats(q, bfqq, idle_timer_disabled, cmd_flags)
Caller
NameDescribe
bfq_insert_requests