函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:iolatency_check_latencies

函数原型:static void iolatency_check_latencies(struct iolatency_grp *iolat, u64 now)

返回类型:void

参数:

类型参数名称
struct iolatency_grp *iolat
u64now
522  blkg等于lat_to_blkg(iolat)
529  latency_stat_init(iolat, & stat)
530  禁止抢占()
531  遍历在线CPU(cpu)
533  s等于per_cpu_ptr(stats, cpu)
534  latency_stat_sum(iolat, & stat, s)
535  latency_stat_init(iolat, s)
537  禁用抢占和中断()
539  parent等于blkg_to_lat( all non-root blkcg_gq's are guaranteed to have access to parent )
540  如果非parent则返回
543  lat_info等于child_lat
545  iolat_update_total_lat_avg(iolat, & stat)
548  如果latency_sum_ok(iolat, & stat)且atomic_read( & Cookie to tell if we need to scale up or down. )恒等于DEFAULT_SCALE_COOKIE则返回
553  spin_lock_irqsave( & lock, flags)
555  latency_stat_sum(iolat, & cur_stat, & stat)
556  Total io's from all of our children for the last summation. 减等于 Our current number of IO's for the last summation.
557  Total io's from all of our children for the last summation. 加等于latency_stat_samples(iolat, & cur_stat)
558  Our current number of IO's for the last summation. 等于latency_stat_samples(iolat, & cur_stat)
560  如果 Last time we adjusted the scale of everybody. 大于等于nownow Last time we adjusted the scale of everybody. 小于BLKIOLATENCY_MIN_ADJUST_TIME则转到:out
564  如果latency_sum_ok(iolat, & cur_stat)且latency_sum_ok(iolat, & stat)则
566  如果latency_stat_samples(iolat, & cur_stat)小于BLKIOLATENCY_MIN_GOOD_SAMPLES则转到:out
573  否则如果 The latency that we missed. 恒等于0或 The latency that we missed. 大于等于min_lat_nsec
575  Last time we adjusted the scale of everybody. 等于now
581  We scale the qd down faster than we scale up, so we need to use this helper* to adjust the scale_cookie accordingly so we don't prematurely get* scale_cookie at DEFAULT_SCALE_COOKIE and unthrottle too much
583  latency_stat_init(iolat, & cur_stat)
584  out :
585  spin_unlock_irqrestore( & lock, flags)
调用者
名称描述
blkcg_iolatency_done_bio