函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\bfq-iosched.c Create Date:2022-07-27 19:32:29
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:__bfq_dispatch_request

函数原型:static struct request *__bfq_dispatch_request(struct blk_mq_hw_ctx *hctx)

返回类型:struct request

参数:

类型参数名称
struct blk_mq_hw_ctx *hctx
4655  bfqd等于elevator_data
4656  struct request * rq = NULL
4657  struct bfq_queue * bfqq = NULL
4659  如果非链表为空
4660  rq等于list_first_entry - get the first element from a list*@ptr: the list head to take the element from.*@type: the type of the struct this is embedded in.*@member: the name of the list_head within the struct.* Note, that list is expected to be not empty.( & dispatch queue , structrequest, queuelist)
4662  删除链表项并重新初始化
4664  bfqq等于RQ_BFQQ(rq)
4666  如果bfqq
4675  转到:inc_in_driver_start_rq
4701  转到:start_rq
4704  bfq_log(bfqd, "dispatch requests: %d busy queues", bfq_tot_busy_queues(bfqd))
4707  如果bfq_tot_busy_queues(bfqd)恒等于0则转到:exit
4722  如果* Force device idling whenever needed to provide accurate * service guarantees, without caring about throughput * issues. CAVEAT: this may even increase latencies, in case * of useless idling for processes that did stop doing I/O. number of requests dispatched and waiting for completion 大于0则转到:exit
4725  bfqq等于Select a queue for service. If we have a current queue in service,* check whether to continue servicing it, or retrieve and set a new one.
4726  如果非bfqq则转到:exit
4729  rq等于Dispatch next request from bfqq.
4731  如果rq
4732  inc_in_driver_start_rq :
4733  number of requests dispatched and waiting for completion 自加
4734  start_rq :
4735  rq_flags或等于drive already may have started this one
4737  exit :
4738  返回:rq
调用者
名称描述
bfq_dispatch_request