函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\time\clocksource.c Create Date:2022-07-27 11:44:01
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:locks_calc_max_nsecs - Returns maximum nanoseconds that can be converted*@mult: cycle to nanosecond multiplier*@shift: cycle to nanosecond divisor (power of two)*@maxadj: maximum adjustment value to mult (~11%)*@mask: bitmask for two's complement

函数原型:u64 clocks_calc_max_nsecs(unsigned int mult, unsigned int shift, unsigned int maxadj, u64 mask, u64 *max_cyc)

返回类型:u64

参数:

类型参数名称
unsigned intmult
unsigned intshift
unsigned intmaxadj
u64mask
u64 *max_cyc
674  max_cycles等于ULLONG_MAX
675  do_div() is NOT a C function(max_cycles, mult + maxadj)
683  max_cycles等于两数取小(max_cycles, mask)
684  max_nsecs等于locksource_cyc2ns - converts clocksource cycles to nanoseconds*@cycles: cycles*@mult: cycle to nanosecond multiplier*@shift: cycle to nanosecond divisor (power of two)* Converts clocksource cycles to nanoseconds, using the given @mult and @shift
687  如果max_cycmax_cyc等于max_cycles
691  max_nsecs右移等于1位
693  返回:max_nsecs
调用者
名称描述
clocksource_update_max_defermentlocksource_update_max_deferment - Updates the clocksource max_idle_ns & max_cycles*@cs: Pointer to clocksource to be updated
sched_clock_register