Lines Matching +full:wait +full:- +full:monitoring +full:- +full:ns
1 // SPDX-License-Identifier: GPL-2.0
26 * struct ntp_data - Structure holding all NTP related state
40 * @ntp_tick_adj: Constant boot-param configurable NTP tick adjustment (upscaled)
49 * @pps_freq: PPS frequency offset in scaled ns/s
50 * @pps_stabil: PPS current stability in scaled ns/s
108 * The following variables are used when a pulse-per-second (PPS) signal
119 #define PPS_MAXWANDER 100000 /* max PPS freq wander (ns/s) */
127 if (ntpdata->time_status & STA_PPSTIME && ntpdata->time_status & STA_PPSSIGNAL) in ntp_offset_chunk()
130 return shift_right(offset, SHIFT_PLL + ntpdata->time_constant); in ntp_offset_chunk()
136 ntpdata->pps_shift = PPS_INTMIN; in pps_reset_freq_interval()
137 ntpdata->pps_intcnt = 0; in pps_reset_freq_interval()
141 * pps_clear - Clears the PPS state variables
147 ntpdata->pps_tf[0] = 0; in pps_clear()
148 ntpdata->pps_tf[1] = 0; in pps_clear()
149 ntpdata->pps_tf[2] = 0; in pps_clear()
150 ntpdata->pps_fbase.tv_sec = ntpdata->pps_fbase.tv_nsec = 0; in pps_clear()
151 ntpdata->pps_freq = 0; in pps_clear()
160 if (ntpdata->pps_valid > 0) { in pps_dec_valid()
161 ntpdata->pps_valid--; in pps_dec_valid()
163 ntpdata->time_status &= ~(STA_PPSSIGNAL | STA_PPSJITTER | in pps_dec_valid()
171 ntpdata->pps_freq = ntpdata->time_freq; in pps_set_freq()
199 txc->ppsfreq = shift_right((ntpdata->pps_freq >> PPM_SCALE_INV_SHIFT) * in pps_fill_timex()
201 txc->jitter = ntpdata->pps_jitter; in pps_fill_timex()
202 if (!(ntpdata->time_status & STA_NANO)) in pps_fill_timex()
203 txc->jitter = ntpdata->pps_jitter / NSEC_PER_USEC; in pps_fill_timex()
204 txc->shift = ntpdata->pps_shift; in pps_fill_timex()
205 txc->stabil = ntpdata->pps_stabil; in pps_fill_timex()
206 txc->jitcnt = ntpdata->pps_jitcnt; in pps_fill_timex()
207 txc->calcnt = ntpdata->pps_calcnt; in pps_fill_timex()
208 txc->errcnt = ntpdata->pps_errcnt; in pps_fill_timex()
209 txc->stbcnt = ntpdata->pps_stbcnt; in pps_fill_timex()
216 return shift_right(offset, SHIFT_PLL + ntpdata->time_constant); in ntp_offset_chunk()
232 txc->ppsfreq = 0; in pps_fill_timex()
233 txc->jitter = 0; in pps_fill_timex()
234 txc->shift = 0; in pps_fill_timex()
235 txc->stabil = 0; in pps_fill_timex()
236 txc->jitcnt = 0; in pps_fill_timex()
237 txc->calcnt = 0; in pps_fill_timex()
238 txc->errcnt = 0; in pps_fill_timex()
239 txc->stbcnt = 0; in pps_fill_timex()
250 u64 second_length, new_base, tick_usec = (u64)ntpdata->tick_usec; in ntp_update_frequency()
254 second_length += ntpdata->ntp_tick_adj; in ntp_update_frequency()
255 second_length += ntpdata->time_freq; in ntp_update_frequency()
260 * Don't wait for the next second_overflow, apply the change to the in ntp_update_frequency()
263 ntpdata->tick_length += new_base - ntpdata->tick_length_base; in ntp_update_frequency()
264 ntpdata->tick_length_base = new_base; in ntp_update_frequency()
269 ntpdata->time_status &= ~STA_MODE; in ntp_update_offset_fll()
274 if (!(ntpdata->time_status & STA_FLL) && (secs <= MAXSEC)) in ntp_update_offset_fll()
277 ntpdata->time_status |= STA_MODE; in ntp_update_offset_fll()
279 return div64_long(offset64 << (NTP_SCALE_SHIFT - SHIFT_FLL), secs); in ntp_update_offset_fll()
287 if (!(ntpdata->time_status & STA_PLL)) in ntp_update_offset()
290 if (!(ntpdata->time_status & STA_NANO)) { in ntp_update_offset()
292 offset = clamp(offset, -USEC_PER_SEC, USEC_PER_SEC); in ntp_update_offset()
297 offset = clamp(offset, -MAXPHASE, MAXPHASE); in ntp_update_offset()
304 secs = (long)(real_secs - ntpdata->time_reftime); in ntp_update_offset()
305 if (unlikely(ntpdata->time_status & STA_FREQHOLD)) in ntp_update_offset()
308 ntpdata->time_reftime = real_secs; in ntp_update_offset()
318 if (unlikely(secs > 1 << (SHIFT_PLL + 1 + ntpdata->time_constant))) in ntp_update_offset()
319 secs = 1 << (SHIFT_PLL + 1 + ntpdata->time_constant); in ntp_update_offset()
322 (NTP_SCALE_SHIFT - 2 * (SHIFT_PLL + 2 + ntpdata->time_constant)); in ntp_update_offset()
324 freq_adj = min(freq_adj + ntpdata->time_freq, MAXFREQ_SCALED); in ntp_update_offset()
326 ntpdata->time_freq = max(freq_adj, -MAXFREQ_SCALED); in ntp_update_offset()
328 ntpdata->time_offset = div_s64(offset64 << NTP_SCALE_SHIFT, NTP_INTERVAL_FREQ); in ntp_update_offset()
334 ntpdata->time_adjust = 0; in __ntp_clear()
335 ntpdata->time_status |= STA_UNSYNC; in __ntp_clear()
336 ntpdata->time_maxerror = NTP_PHASE_LIMIT; in __ntp_clear()
337 ntpdata->time_esterror = NTP_PHASE_LIMIT; in __ntp_clear()
341 ntpdata->tick_length = ntpdata->tick_length_base; in __ntp_clear()
342 ntpdata->time_offset = 0; in __ntp_clear()
344 ntpdata->ntp_next_leap_sec = TIME64_MAX; in __ntp_clear()
350 * ntp_clear - Clears the NTP state variables
364 * ntp_get_next_leap - Returns the next leapsecond in CLOCK_REALTIME ktime_t
374 if ((ntpdata->time_state == TIME_INS) && (ntpdata->time_status & STA_INS)) in ntp_get_next_leap()
375 return ktime_set(ntpdata->ntp_next_leap_sec, 0); in ntp_get_next_leap()
398 * Leap second processing. If in leap-insert state at the end of the in second_overflow()
399 * day, the system clock is set back one second; if in leap-delete in second_overflow()
402 switch (ntpdata->time_state) { in second_overflow()
404 if (ntpdata->time_status & STA_INS) { in second_overflow()
405 ntpdata->time_state = TIME_INS; in second_overflow()
407 ntpdata->ntp_next_leap_sec = secs + SECS_PER_DAY - rem; in second_overflow()
408 } else if (ntpdata->time_status & STA_DEL) { in second_overflow()
409 ntpdata->time_state = TIME_DEL; in second_overflow()
411 ntpdata->ntp_next_leap_sec = secs + SECS_PER_DAY - rem; in second_overflow()
415 if (!(ntpdata->time_status & STA_INS)) { in second_overflow()
416 ntpdata->ntp_next_leap_sec = TIME64_MAX; in second_overflow()
417 ntpdata->time_state = TIME_OK; in second_overflow()
418 } else if (secs == ntpdata->ntp_next_leap_sec) { in second_overflow()
419 leap = -1; in second_overflow()
420 ntpdata->time_state = TIME_OOP; in second_overflow()
425 if (!(ntpdata->time_status & STA_DEL)) { in second_overflow()
426 ntpdata->ntp_next_leap_sec = TIME64_MAX; in second_overflow()
427 ntpdata->time_state = TIME_OK; in second_overflow()
428 } else if (secs == ntpdata->ntp_next_leap_sec) { in second_overflow()
430 ntpdata->ntp_next_leap_sec = TIME64_MAX; in second_overflow()
431 ntpdata->time_state = TIME_WAIT; in second_overflow()
436 ntpdata->ntp_next_leap_sec = TIME64_MAX; in second_overflow()
437 ntpdata->time_state = TIME_WAIT; in second_overflow()
440 if (!(ntpdata->time_status & (STA_INS | STA_DEL))) in second_overflow()
441 ntpdata->time_state = TIME_OK; in second_overflow()
446 ntpdata->time_maxerror += MAXFREQ / NSEC_PER_USEC; in second_overflow()
447 if (ntpdata->time_maxerror > NTP_PHASE_LIMIT) { in second_overflow()
448 ntpdata->time_maxerror = NTP_PHASE_LIMIT; in second_overflow()
449 ntpdata->time_status |= STA_UNSYNC; in second_overflow()
453 ntpdata->tick_length = ntpdata->tick_length_base; in second_overflow()
455 delta = ntp_offset_chunk(ntpdata, ntpdata->time_offset); in second_overflow()
456 ntpdata->time_offset -= delta; in second_overflow()
457 ntpdata->tick_length += delta; in second_overflow()
462 if (!ntpdata->time_adjust) in second_overflow()
465 if (ntpdata->time_adjust > MAX_TICKADJ) { in second_overflow()
466 ntpdata->time_adjust -= MAX_TICKADJ; in second_overflow()
467 ntpdata->tick_length += MAX_TICKADJ_SCALED; in second_overflow()
471 if (ntpdata->time_adjust < -MAX_TICKADJ) { in second_overflow()
472 ntpdata->time_adjust += MAX_TICKADJ; in second_overflow()
473 ntpdata->tick_length -= MAX_TICKADJ_SCALED; in second_overflow()
477 ntpdata->tick_length += (s64)(ntpdata->time_adjust * NSEC_PER_USEC / NTP_INTERVAL_FREQ) in second_overflow()
479 ntpdata->time_adjust = 0; in second_overflow()
503 exp = ktime_add_ns(exp, 2ULL * NSEC_PER_SEC - offset_nsec); in sched_sync_hw_clock()
505 exp = ktime_add_ns(exp, SYNC_PERIOD_NS - offset_nsec); in sched_sync_hw_clock()
516 * tsched t1 write(t2.tv_sec - 1sec)) t2 RTC increments seconds
519 * tsched = t2 - set_offset_nsec
520 * newval = t2 - NSEC_PER_SEC
522 * ==> neval = tsched + set_offset_nsec - NSEC_PER_SEC
527 * abs(now - tsched) < FUZZ
535 /* Allowed error in tv_nsec, arbitrarily set to 5 jiffies in ns. */ in rtc_tv_nsec_ok()
537 struct timespec64 delay = {.tv_sec = -1, in rtc_tv_nsec_ok()
542 if (to_set->tv_nsec < TIME_SET_NSEC_FUZZ) { in rtc_tv_nsec_ok()
543 to_set->tv_nsec = 0; in rtc_tv_nsec_ok()
547 if (to_set->tv_nsec > NSEC_PER_SEC - TIME_SET_NSEC_FUZZ) { in rtc_tv_nsec_ok()
548 to_set->tv_sec++; in rtc_tv_nsec_ok()
549 to_set->tv_nsec = 0; in rtc_tv_nsec_ok()
558 return -ENODEV; in update_persistent_clock64()
563 return -ENODEV; in update_persistent_clock64()
573 int err = -ENODEV; in update_rtc()
577 return -ENODEV; in update_rtc()
579 if (!rtc->ops || !rtc->ops->set_time) in update_rtc()
583 if (*offset_nsec == rtc->set_offset_nsec) { in update_rtc()
584 rtc_time64_to_tm(to_set->tv_sec, &tm); in update_rtc()
588 *offset_nsec = rtc->set_offset_nsec; in update_rtc()
589 err = -EAGAIN; in update_rtc()
598 return -ENODEV; in update_rtc()
603 * ntp_synced - Tells whether the NTP status is not UNSYNC
628 int res = -EAGAIN; in sync_hw_clock()
633 * work being able to rearm the timer. Wait for the timer to expire. in sync_hw_clock()
645 to_set.tv_sec -= (sys_tz.tz_minuteswest * 60); in sync_hw_clock()
649 if (res != -ENODEV) in sync_hw_clock()
654 if (res == -ENODEV) in sync_hw_clock()
689 * Propagate a new txc->status value into the NTP state:
693 if ((ntpdata->time_status & STA_PLL) && !(txc->status & STA_PLL)) { in process_adj_status()
694 ntpdata->time_state = TIME_OK; in process_adj_status()
695 ntpdata->time_status = STA_UNSYNC; in process_adj_status()
696 ntpdata->ntp_next_leap_sec = TIME64_MAX; in process_adj_status()
705 if (!(ntpdata->time_status & STA_PLL) && (txc->status & STA_PLL)) in process_adj_status()
706 ntpdata->time_reftime = __ktime_get_real_seconds(); in process_adj_status()
709 ntpdata->time_status &= STA_RONLY; in process_adj_status()
710 ntpdata->time_status |= txc->status & ~STA_RONLY; in process_adj_status()
716 if (txc->modes & ADJ_STATUS) in process_adjtimex_modes()
719 if (txc->modes & ADJ_NANO) in process_adjtimex_modes()
720 ntpdata->time_status |= STA_NANO; in process_adjtimex_modes()
722 if (txc->modes & ADJ_MICRO) in process_adjtimex_modes()
723 ntpdata->time_status &= ~STA_NANO; in process_adjtimex_modes()
725 if (txc->modes & ADJ_FREQUENCY) { in process_adjtimex_modes()
726 ntpdata->time_freq = txc->freq * PPM_SCALE; in process_adjtimex_modes()
727 ntpdata->time_freq = min(ntpdata->time_freq, MAXFREQ_SCALED); in process_adjtimex_modes()
728 ntpdata->time_freq = max(ntpdata->time_freq, -MAXFREQ_SCALED); in process_adjtimex_modes()
733 if (txc->modes & ADJ_MAXERROR) in process_adjtimex_modes()
734 ntpdata->time_maxerror = clamp(txc->maxerror, 0, NTP_PHASE_LIMIT); in process_adjtimex_modes()
736 if (txc->modes & ADJ_ESTERROR) in process_adjtimex_modes()
737 ntpdata->time_esterror = clamp(txc->esterror, 0, NTP_PHASE_LIMIT); in process_adjtimex_modes()
739 if (txc->modes & ADJ_TIMECONST) { in process_adjtimex_modes()
740 ntpdata->time_constant = clamp(txc->constant, 0, MAXTC); in process_adjtimex_modes()
741 if (!(ntpdata->time_status & STA_NANO)) in process_adjtimex_modes()
742 ntpdata->time_constant += 4; in process_adjtimex_modes()
743 ntpdata->time_constant = clamp(ntpdata->time_constant, 0, MAXTC); in process_adjtimex_modes()
746 if (txc->modes & ADJ_TAI && txc->constant >= 0 && txc->constant <= MAX_TAI_OFFSET) in process_adjtimex_modes()
747 *time_tai = txc->constant; in process_adjtimex_modes()
749 if (txc->modes & ADJ_OFFSET) in process_adjtimex_modes()
750 ntp_update_offset(ntpdata, txc->offset); in process_adjtimex_modes()
752 if (txc->modes & ADJ_TICK) in process_adjtimex_modes()
753 ntpdata->tick_usec = txc->tick; in process_adjtimex_modes()
755 if (txc->modes & (ADJ_TICK|ADJ_FREQUENCY|ADJ_OFFSET)) in process_adjtimex_modes()
761 * kernel time-keeping variables. used by xntpd.
769 if (txc->modes & ADJ_ADJTIME) { in __do_adjtimex()
770 long save_adjust = ntpdata->time_adjust; in __do_adjtimex()
772 if (!(txc->modes & ADJ_OFFSET_READONLY)) { in __do_adjtimex()
774 ntpdata->time_adjust = txc->offset; in __do_adjtimex()
778 audit_ntp_set_new(ad, AUDIT_NTP_ADJUST, ntpdata->time_adjust); in __do_adjtimex()
780 txc->offset = save_adjust; in __do_adjtimex()
783 if (txc->modes) { in __do_adjtimex()
784 audit_ntp_set_old(ad, AUDIT_NTP_OFFSET, ntpdata->time_offset); in __do_adjtimex()
785 audit_ntp_set_old(ad, AUDIT_NTP_FREQ, ntpdata->time_freq); in __do_adjtimex()
786 audit_ntp_set_old(ad, AUDIT_NTP_STATUS, ntpdata->time_status); in __do_adjtimex()
788 audit_ntp_set_old(ad, AUDIT_NTP_TICK, ntpdata->tick_usec); in __do_adjtimex()
792 audit_ntp_set_new(ad, AUDIT_NTP_OFFSET, ntpdata->time_offset); in __do_adjtimex()
793 audit_ntp_set_new(ad, AUDIT_NTP_FREQ, ntpdata->time_freq); in __do_adjtimex()
794 audit_ntp_set_new(ad, AUDIT_NTP_STATUS, ntpdata->time_status); in __do_adjtimex()
796 audit_ntp_set_new(ad, AUDIT_NTP_TICK, ntpdata->tick_usec); in __do_adjtimex()
799 txc->offset = shift_right(ntpdata->time_offset * NTP_INTERVAL_FREQ, NTP_SCALE_SHIFT); in __do_adjtimex()
800 if (!(ntpdata->time_status & STA_NANO)) in __do_adjtimex()
801 txc->offset = div_s64(txc->offset, NSEC_PER_USEC); in __do_adjtimex()
804 result = ntpdata->time_state; in __do_adjtimex()
805 if (is_error_status(ntpdata->time_status)) in __do_adjtimex()
808 txc->freq = shift_right((ntpdata->time_freq >> PPM_SCALE_INV_SHIFT) * in __do_adjtimex()
810 txc->maxerror = ntpdata->time_maxerror; in __do_adjtimex()
811 txc->esterror = ntpdata->time_esterror; in __do_adjtimex()
812 txc->status = ntpdata->time_status; in __do_adjtimex()
813 txc->constant = ntpdata->time_constant; in __do_adjtimex()
814 txc->precision = 1; in __do_adjtimex()
815 txc->tolerance = MAXFREQ_SCALED / PPM_SCALE; in __do_adjtimex()
816 txc->tick = ntpdata->tick_usec; in __do_adjtimex()
817 txc->tai = *time_tai; in __do_adjtimex()
822 txc->time.tv_sec = ts->tv_sec; in __do_adjtimex()
823 txc->time.tv_usec = ts->tv_nsec; in __do_adjtimex()
824 if (!(ntpdata->time_status & STA_NANO)) in __do_adjtimex()
825 txc->time.tv_usec = ts->tv_nsec / NSEC_PER_USEC; in __do_adjtimex()
828 if (unlikely(ts->tv_sec >= ntpdata->ntp_next_leap_sec)) { in __do_adjtimex()
829 if ((ntpdata->time_state == TIME_INS) && (ntpdata->time_status & STA_INS)) { in __do_adjtimex()
831 txc->tai++; in __do_adjtimex()
832 txc->time.tv_sec--; in __do_adjtimex()
834 if ((ntpdata->time_state == TIME_DEL) && (ntpdata->time_status & STA_DEL)) { in __do_adjtimex()
836 txc->tai--; in __do_adjtimex()
837 txc->time.tv_sec++; in __do_adjtimex()
839 if ((ntpdata->time_state == TIME_OOP) && (ts->tv_sec == ntpdata->ntp_next_leap_sec)) in __do_adjtimex()
851 * pps_normtime.nsec has a range of ( -NSEC_PER_SEC / 2, NSEC_PER_SEC / 2 ]
861 * [ -NSEC_PER_SEC / 2, NSEC_PER_SEC / 2 ] interval
871 norm.nsec -= NSEC_PER_SEC; in pps_normalize_ts()
881 *jitter = ntpdata->pps_tf[0] - ntpdata->pps_tf[1]; in pps_phase_filter_get()
883 *jitter = -*jitter; in pps_phase_filter_get()
886 return ntpdata->pps_tf[0]; in pps_phase_filter_get()
892 ntpdata->pps_tf[2] = ntpdata->pps_tf[1]; in pps_phase_filter_add()
893 ntpdata->pps_tf[1] = ntpdata->pps_tf[0]; in pps_phase_filter_add()
894 ntpdata->pps_tf[0] = err; in pps_phase_filter_add()
903 if (--ntpdata->pps_intcnt <= -PPS_INTCOUNT) { in pps_dec_freq_interval()
904 ntpdata->pps_intcnt = -PPS_INTCOUNT; in pps_dec_freq_interval()
905 if (ntpdata->pps_shift > PPS_INTMIN) { in pps_dec_freq_interval()
906 ntpdata->pps_shift--; in pps_dec_freq_interval()
907 ntpdata->pps_intcnt = 0; in pps_dec_freq_interval()
918 if (++ntpdata->pps_intcnt >= PPS_INTCOUNT) { in pps_inc_freq_interval()
919 ntpdata->pps_intcnt = PPS_INTCOUNT; in pps_inc_freq_interval()
920 if (ntpdata->pps_shift < PPS_INTMAX) { in pps_inc_freq_interval()
921 ntpdata->pps_shift++; in pps_inc_freq_interval()
922 ntpdata->pps_intcnt = 0; in pps_inc_freq_interval()
943 if (freq_norm.sec > (2 << ntpdata->pps_shift)) { in hardpps_update_freq()
944 ntpdata->time_status |= STA_PPSERROR; in hardpps_update_freq()
945 ntpdata->pps_errcnt++; in hardpps_update_freq()
947 printk_deferred(KERN_ERR "hardpps: PPSERROR: interval too long - %lld s\n", in hardpps_update_freq()
957 ftemp = div_s64(((s64)(-freq_norm.nsec)) << NTP_SCALE_SHIFT, in hardpps_update_freq()
959 delta = shift_right(ftemp - ntpdata->pps_freq, NTP_SCALE_SHIFT); in hardpps_update_freq()
960 ntpdata->pps_freq = ftemp; in hardpps_update_freq()
961 if (delta > PPS_MAXWANDER || delta < -PPS_MAXWANDER) { in hardpps_update_freq()
963 ntpdata->time_status |= STA_PPSWANDER; in hardpps_update_freq()
964 ntpdata->pps_stbcnt++; in hardpps_update_freq()
973 * frequency changes, but is used only for performance monitoring in hardpps_update_freq()
977 delta_mod = -delta_mod; in hardpps_update_freq()
978 ntpdata->pps_stabil += (div_s64(((s64)delta_mod) << (NTP_SCALE_SHIFT - SHIFT_USEC), in hardpps_update_freq()
979 NSEC_PER_USEC) - ntpdata->pps_stabil) >> PPS_INTMIN; in hardpps_update_freq()
982 if ((ntpdata->time_status & STA_PPSFREQ) && !(ntpdata->time_status & STA_FREQHOLD)) { in hardpps_update_freq()
983 ntpdata->time_freq = ntpdata->pps_freq; in hardpps_update_freq()
993 long correction = -error; in hardpps_update_phase()
1005 if (jitter > (ntpdata->pps_jitter << PPS_POPCORN)) { in hardpps_update_phase()
1007 jitter, (ntpdata->pps_jitter << PPS_POPCORN)); in hardpps_update_phase()
1008 ntpdata->time_status |= STA_PPSJITTER; in hardpps_update_phase()
1009 ntpdata->pps_jitcnt++; in hardpps_update_phase()
1010 } else if (ntpdata->time_status & STA_PPSTIME) { in hardpps_update_phase()
1012 ntpdata->time_offset = div_s64(((s64)correction) << NTP_SCALE_SHIFT, in hardpps_update_phase()
1015 ntpdata->time_adjust = 0; in hardpps_update_phase()
1018 ntpdata->pps_jitter += (jitter - ntpdata->pps_jitter) >> PPS_INTMIN; in hardpps_update_phase()
1022 * __hardpps() - discipline CPU clock oscillator to external PPS signal
1041 ntpdata->time_status &= ~(STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR); in __hardpps()
1044 ntpdata->time_status |= STA_PPSSIGNAL; in __hardpps()
1045 ntpdata->pps_valid = PPS_VALID; in __hardpps()
1051 if (unlikely(ntpdata->pps_fbase.tv_sec == 0)) { in __hardpps()
1052 ntpdata->pps_fbase = *raw_ts; in __hardpps()
1057 freq_norm = pps_normalize_ts(timespec64_sub(*raw_ts, ntpdata->pps_fbase)); in __hardpps()
1061 * [1s - MAXFREQ us, 1s + MAXFREQ us], otherwise reject it in __hardpps()
1064 (freq_norm.nsec < -MAXFREQ * freq_norm.sec)) { in __hardpps()
1065 ntpdata->time_status |= STA_PPSJITTER; in __hardpps()
1067 ntpdata->pps_fbase = *raw_ts; in __hardpps()
1073 if (freq_norm.sec >= (1 << ntpdata->pps_shift)) { in __hardpps()
1074 ntpdata->pps_calcnt++; in __hardpps()
1076 ntpdata->pps_fbase = *raw_ts; in __hardpps()