函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:ktime_get_snapshot - snapshots the realtime/monotonic raw clocks with counter*@systime_snapshot: pointer to struct receiving the system time snapshot

函数原型:void ktime_get_snapshot(struct system_time_snapshot *systime_snapshot)

返回类型:void

参数:

类型参数名称
struct system_time_snapshot *systime_snapshot
969  tk等于timekeeper
977  WARN_ON_ONCE(lag for if timekeeping is suspended )
979  循环
980  seq等于ad_seqcount_begin - begin a seq-read critical section*@s: pointer to seqcount_t* Returns: count to be passed to read_seqcount_retry* read_seqcount_begin opens a read critical section of the given seqcount
981  now等于k_clock_read - atomic clocksource read() helper* This helper is necessary to use in the read paths because, while the* seqlock ensures we don't return a bad value while structures are updated,* it doesn't protect from potential crashes
982  cs_was_changed_seq等于cs_was_changed_seq
983  clock_was_set_seq等于clock_was_set_seq
984  base_real等于计算下一次触发时间(base, offs_real)
986  base_raw等于base
987  nsec_real等于timekeeping_cycles_to_ns( & tkr_mono, now)
988  nsec_raw等于timekeeping_cycles_to_ns( & tkr_raw, now)
989 ad_seqcount_retry - end a seq-read critical section*@s: pointer to seqcount_t*@start: count, from read_seqcount_begin* Returns: 1 if retry is required, else 0* read_seqcount_retry closes a read critical section of the given seqcount循环
991  cycles等于now
992  real等于Add a ktime_t variable and a scalar nanosecond value.* res = kt + nsval:(base_real, nsec_real)
993  raw等于Add a ktime_t variable and a scalar nanosecond value.* res = kt + nsval:(base_raw, nsec_raw)