函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:bfq_completed_request

函数原型:static void bfq_completed_request(struct bfq_queue *bfqq, struct bfq_data *bfqd)

返回类型:void

参数:

类型参数名称
struct bfq_queue *bfqq
struct bfq_data *bfqd
5607  bfq_update_hw_tag(bfqd)
5609  number of requests dispatched and waiting for completion 自减
5610  umber of requests on the dispatch list or inside driver 自减
5612  如果非umber of requests on the dispatch list or inside driver 且非bfq_bfqq_busy(bfqq)则
5619  udget expiration (in jiffies) 等于jiffies
5621  Invoke __bfq_weights_tree_remove on bfqq and decrement the number* of active groups for each queue's inactive parent entity.
5624  now_ns等于ktime_get_ns()
5626  completion time of the last request 等于now_ns
5632  delta_us等于div_u64 - unsigned 64bit divide with 32bit divisor*@dividend: unsigned 64bit dividend*@divisor: unsigned 32bit divisor* This is the most common 64bit divide and should be used if possible,* as many 32bit archs can optimize this variant better than a full
5650  如果delta_us大于Below this threshold (in ns), we consider thinktime immediate. NSEC_PER_USEC max rq size seen during current observation interval (sectors) 左移Shift used for peak-rate fixed precision calculations位的值除delta_us小于1UL左移Shift used for peak-rate fixed precision calculations减10位则bfq_update_rate_reset(bfqd, NULL)
5654  time of last request completion (ns) 等于now_ns
5655  bfqq owning the last completed rq 等于bfqq
5668  如果bfq_bfqq_softrt_update(bfqq)且umber of requests on the dispatch list or inside driver 恒等于0且RB_EMPTY_ROOT( & sorted list of pending requests )且actor by which the weight of this queue is multiplied 不等于* Maximum factor by which the weight of a weight-raised queue * is multiplied.Minimum time instant such that, only if a new request is* enqueued after this time instant in an idle @bfq_queue with* no outstanding requests, then the task associated with the* queue it is deemed as soft real-time (see the comments on* the function 等于To be deemed as soft real-time, an application must meet two* requirements
5678  如果 bfq_queue in service 恒等于bfqq
5705  返回
5706  否则如果If we expire a queue that is actively waiting (i.e., with the* device idled) for the arrival of a new request, then we may incur* the timestamp misalignment problem described in the body of the* function __bfq_activate_entityq_bfqq_expire - expire a queue.*@bfqd: device owning the queue.*@bfqq: the queue to expire.*@compensate: if true, compensate for the time spent idling.*@reason: the reason causing the expiration.* If the process associated with bfqq does slow I/O (e
5709  否则如果RB_EMPTY_ROOT( & sorted list of pending requests )且umber of requests on the dispatch list or inside driver 恒等于0或非For a queue that becomes empty, device idling is allowed only if* this function returns true for that queue的值则q_bfqq_expire - expire a queue.*@bfqd: device owning the queue.*@bfqq: the queue to expire.*@compensate: if true, compensate for the time spent idling.*@reason: the reason causing the expiration.* If the process associated with bfqq does slow I/O (e
5716  如果非 number of requests dispatched and waiting for completion Scheduler run of queue, if there are requests pending and no one in the* driver that will restart queueing.
调用者
名称描述
bfq_finish_requeue_requestHandle either a requeue or a finish for rq. The things to do are* the same in both cases: all references to rq are to be dropped. In* particular, rq is considered completed from the point of view of* the scheduler.