函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:adjust_historical_crosststamp - adjust crosstimestamp previous to current interval*@history: Snapshot representing start of history*@partial_history_cycles: Cycle offset into history (fractional part)*@total_history_cycles: Total history length in

函数原型:static int adjust_historical_crosststamp(struct system_time_snapshot *history, u64 partial_history_cycles, u64 total_history_cycles, bool discontinuity, struct system_device_crosststamp *ts)

返回类型:int

参数:

类型参数名称
struct system_time_snapshot *history
u64partial_history_cycles
u64total_history_cycles
booldiscontinuity
struct system_device_crosststamp *ts
1038  tk等于timekeeper
1043  如果total_history_cycles恒等于0或partial_history_cycles恒等于0则返回:0
1047  interp_forward等于partial_history_cycles大于total_history_cycles除2
1048  partial_history_cycles等于如果interp_forwardtotal_history_cyclespartial_history_cycles否则partial_history_cycles
1056  corr_raw等于Convert ktime_t to nanoseconds
1058  ret等于Scale base by mult/div checking for overflow
1060  如果ret则返回:ret
1070  如果discontinuity
1071  corr_real等于mul_u64_u32_div(corr_raw, mult, mult)
1073  否则
1074  corr_real等于Convert ktime_t to nanoseconds
1076  ret等于Scale base by mult/div checking for overflow
1078  如果ret则返回:ret
1083  如果interp_forward
1084  sys_monoraw等于Add a ktime_t variable and a scalar nanosecond value.* res = kt + nsval:(raw, corr_raw)
1085  sys_realtime等于Add a ktime_t variable and a scalar nanosecond value.* res = kt + nsval:(real, corr_real)
1086  否则
1087  sys_monoraw等于Subtract a scalar nanosecod from a ktime_t variable* res = kt - nsval:(sys_monoraw, corr_raw)
1088  sys_realtime等于Subtract a scalar nanosecod from a ktime_t variable* res = kt - nsval:(sys_realtime, corr_real)
1091  返回:0
调用者
名称描述
get_device_system_crosststampget_device_system_crosststamp - Synchronously capture system/device timestamp*@get_time_fn: Callback to get simultaneous device time and* system counter from the device driver*@ctx: Context passed to get_time_fn()*@history_begin: Historical reference