函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:calibrate_delay_converge

函数原型:static unsigned long calibrate_delay_converge(void)

返回类型:unsigned long

参数:

191  trials等于0, band等于0, trial_in_band等于0
193  lpj等于1左移12位
196  ticks等于jiffies
197 ticks恒等于jiffies循环
200  ticks等于jiffies
201  循环
202  如果trial_in_band先自加恒等于1左移band位则
203  band先自加
204  trial_in_band等于0
206  __delay(lpj * band)
207  trials加等于band
208 ticks恒等于jiffies循环
213  trials减等于band
214  loopadd_base等于lpjband
215  lpj_base等于lpjtrials
217  recalibrate :
218  lpj等于lpj_base
219  loopadd等于loopadd_base
225  chop_limit等于lpj右移This is the number of bits of precision for the loops_per_jiffy. Each* time we refine our estimate after the first takes 1.5/HZ seconds, so try* to start with a good estimate.* For the boot cpu we can skip the delay calibration and assign it a value
226 loopadd大于chop_limit循环
227  lpj加等于loopadd
228  ticks等于jiffies
229 ticks恒等于jiffies循环
231  ticks等于jiffies
232  __delay(lpj)
233  如果jiffies不等于tickslpj减等于loopadd
235  loopadd右移等于1位
242  如果lpjloopadd乘2恒等于lpj_baseloopadd_base乘2则
243  lpj_base等于lpj
244  loopadd_base左移等于2位
245  转到:recalibrate
248  返回:lpj
调用者
名称描述
calibrate_delay计算CPU需要校准的时间