FreeBSD kernel kern code
|
#include <sys/cdefs.h>
#include "opt_ntp.h"
#include "opt_ffclock.h"
#include <sys/param.h>
#include <sys/kernel.h>
#include <sys/limits.h>
#include <sys/lock.h>
#include <sys/mutex.h>
#include <sys/proc.h>
#include <sys/sbuf.h>
#include <sys/sleepqueue.h>
#include <sys/sysctl.h>
#include <sys/syslog.h>
#include <sys/systm.h>
#include <sys/timeffc.h>
#include <sys/timepps.h>
#include <sys/timetc.h>
#include <sys/timex.h>
#include <sys/vdso.h>
#include "opt_ddb.h"
Go to the source code of this file.
Data Structures | |
struct | timehands |
Macros | |
#define | LARGE_STEP 200 |
#define | GETTHBINTIME(dst, member) |
#define | GETTHMEMBER(dst, member) |
Functions | |
__FBSDID ("$FreeBSD$") | |
static u_int | dummy_get_timecount (struct timecounter *tc) |
static int | sysctl_kern_boottime (SYSCTL_HANDLER_ARGS) |
SYSCTL_PROC (_kern, KERN_BOOTTIME, boottime, CTLTYPE_STRUCT|CTLFLAG_RD|CTLFLAG_MPSAFE, NULL, 0, sysctl_kern_boottime, "S,timeval", "Estimated system boottime") | |
SYSCTL_NODE (_kern, OID_AUTO, timecounter, CTLFLAG_RW|CTLFLAG_MPSAFE, 0, "") | |
static | SYSCTL_NODE (_kern_timecounter, OID_AUTO, tc, CTLFLAG_RW|CTLFLAG_MPSAFE, 0, "") |
SYSCTL_INT (_kern_timecounter, OID_AUTO, stepwarnings, CTLFLAG_RWTUN, ×tepwarnings, 0, "Log time steps") | |
SYSCTL_INT (_kern_timecounter, OID_AUTO, timehands_count, CTLFLAG_RDTUN|CTLFLAG_NOFETCH, &timehands_count, 0, "Count of timehands in rotation") | |
static int | sysctl_kern_timecounter_adjprecision (SYSCTL_HANDLER_ARGS) |
SYSCTL_PROC (_kern_timecounter, OID_AUTO, alloweddeviation, CTLTYPE_INT|CTLFLAG_RWTUN|CTLFLAG_MPSAFE, 0, 0, sysctl_kern_timecounter_adjprecision, "I", "Allowed time interval deviation in percents") | |
static void | tc_windup (struct bintime *new_boottimebin) |
static void | cpu_tick_calibrate (int) |
void | dtrace_getnanotime (struct timespec *tsp) |
void | dtrace_getnanouptime (struct timespec *tsp) |
static int | sysctl_kern_timecounter_get (SYSCTL_HANDLER_ARGS) |
static int | sysctl_kern_timecounter_freq (SYSCTL_HANDLER_ARGS) |
static __inline u_int | tc_delta (struct timehands *th) |
static __inline void | bintime_add_tc_delta (struct bintime *bt, uint64_t scale, uint64_t large_delta, uint64_t delta) |
static __inline void | bintime_off (struct bintime *bt, u_int off) |
static __inline void | getthmember (void *out, size_t out_size, u_int off) |
void | binuptime (struct bintime *bt) |
void | nanouptime (struct timespec *tsp) |
void | microuptime (struct timeval *tvp) |
void | bintime (struct bintime *bt) |
void | nanotime (struct timespec *tsp) |
void | microtime (struct timeval *tvp) |
void | getbinuptime (struct bintime *bt) |
void | getnanouptime (struct timespec *tsp) |
void | getmicrouptime (struct timeval *tvp) |
void | getbintime (struct bintime *bt) |
void | getnanotime (struct timespec *tsp) |
void | getmicrotime (struct timeval *tvp) |
void | getboottime (struct timeval *boottime) |
void | getboottimebin (struct bintime *boottimebin) |
void | sysclock_getsnapshot (struct sysclock_snap *clock_snap, int fast) |
int | sysclock_snap2bintime (struct sysclock_snap *cs, struct bintime *bt, int whichclock, uint32_t flags) |
void | tc_init (struct timecounter *tc) |
uint64_t | tc_getfrequency (void) |
static bool | sleeping_on_old_rtc (struct thread *td) |
MTX_SYSINIT (tc_setclock_init, &tc_setclock_mtx, "tcsetc", MTX_SPIN) | |
void | tc_setclock (struct timespec *ts) |
static void | recalculate_scaling_factor_and_large_delta (struct timehands *th) |
static int | sysctl_kern_timecounter_hardware (SYSCTL_HANDLER_ARGS) |
SYSCTL_PROC (_kern_timecounter, OID_AUTO, hardware, CTLTYPE_STRING|CTLFLAG_RWTUN|CTLFLAG_NOFETCH|CTLFLAG_MPSAFE, 0, 0, sysctl_kern_timecounter_hardware, "A", "Timecounter hardware selected") | |
static int | sysctl_kern_timecounter_choice (SYSCTL_HANDLER_ARGS) |
SYSCTL_PROC (_kern_timecounter, OID_AUTO, choice, CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE, 0, 0, sysctl_kern_timecounter_choice, "A", "Timecounter hardware detected") | |
static int | abi_aware (struct pps_state *pps, int vers) |
static int | pps_fetch (struct pps_fetch_args *fapi, struct pps_state *pps) |
int | pps_ioctl (u_long cmd, caddr_t data, struct pps_state *pps) |
void | pps_init (struct pps_state *pps) |
void | pps_init_abi (struct pps_state *pps) |
void | pps_capture (struct pps_state *pps) |
void | pps_event (struct pps_state *pps, int event) |
SYSCTL_INT (_kern_timecounter, OID_AUTO, tick, CTLFLAG_RD, &tc_tick, 0, "Approximate number of hardclock ticks in a millisecond") | |
void | tc_ticktock (int cnt) |
static void __inline | tc_adjprecision (void) |
static void | inittimehands (void *dummy) |
SYSINIT (timehands, SI_SUB_TUNABLES, SI_ORDER_ANY, inittimehands, NULL) | |
static void | inittimecounter (void *dummy) |
SYSINIT (timecounter, SI_SUB_CLOCKS, SI_ORDER_SECOND, inittimecounter, NULL) | |
DPCPU_DEFINE_STATIC (uint64_t, tc_cpu_ticks_base) | |
DPCPU_DEFINE_STATIC (unsigned, tc_cpu_ticks_last) | |
static uint64_t | tc_cpu_ticks (void) |
void | cpu_tick_calibration (void) |
void | set_cputicker (cpu_tick_f *func, uint64_t freq, unsigned var) |
uint64_t | cpu_tickrate (void) |
uint64_t | cputick2usec (uint64_t tick) |
static int | sysctl_fast_gettime (SYSCTL_HANDLER_ARGS) |
SYSCTL_PROC (_kern_timecounter, OID_AUTO, fast_gettime, CTLTYPE_INT|CTLFLAG_RW|CTLFLAG_MPSAFE, NULL, 0, sysctl_fast_gettime, "I", "Enable fast time of day") | |
uint32_t | tc_fill_vdso_timehands (struct vdso_timehands *vdso_th) |
#define GETTHBINTIME | ( | dst, | |
member | |||
) |
#define GETTHMEMBER | ( | dst, | |
member | |||
) |
__FBSDID | ( | "$FreeBSD$" | ) |
|
inlinestatic |
Definition at line 1585 of file kern_tc.c.
Referenced by pps_fetch().
void bintime | ( | struct bintime * | bt | ) |
Definition at line 415 of file kern_tc.c.
References bt, and GETTHBINTIME.
Referenced by bintime_off(), cpu_tick_calibrate(), devstat_end_transaction(), dtrace_getnanouptime(), filt_timervalidate(), getboottime(), getmicrouptime(), getnanouptime(), init_va_filerev(), kqtimer_proc_continue(), lockstat_nsecs(), microtime(), microuptime(), nanotime(), nanouptime(), pps_event(), sysclock_getsnapshot(), sysclock_snap2bintime(), tc_setclock(), tc_windup(), umtx_abs_timeout_getsbt(), unp_internalize(), and uuid_time().
|
static |
Definition at line 217 of file kern_tc.c.
References bt.
Referenced by bintime_off(), and tc_windup().
|
static |
Definition at line 240 of file kern_tc.c.
References bintime(), bintime_add_tc_delta(), bt, tc_delta(), timehands::th_generation, timehands::th_large_delta, timehands::th_scale, and timehands.
void binuptime | ( | struct bintime * | bt | ) |
Definition at line 390 of file kern_tc.c.
References bt, and GETTHBINTIME.
Referenced by devstat_add_entry(), devstat_end_transaction(), devstat_new_entry(), devstat_start_transaction(), devstat_start_transaction_bio(), lockstat_nsecs(), microuptime(), nanouptime(), and tc_setclock().
|
static |
Definition at line 2084 of file kern_tc.c.
References bintime(), bootverbose, cpu_tick_frequency, cpu_tick_variable, cpu_ticks, getbinuptime(), and printf().
Referenced by cpu_tick_calibration(), and tc_setclock().
void cpu_tick_calibration | ( | void | ) |
Definition at line 2065 of file kern_tc.c.
References cpu_tick_calibrate(), and time_uptime.
Referenced by hardclock().
uint64_t cpu_tickrate | ( | void | ) |
Definition at line 2144 of file kern_tc.c.
References cpu_tick_frequency, cpu_ticks, tc_cpu_ticks(), and tc_getfrequency().
Referenced by cputick2usec(), kern_clock_getres(), and lim_cb().
uint64_t cputick2usec | ( | uint64_t | tick | ) |
Definition at line 2163 of file kern_tc.c.
References cpu_tickrate(), and tick.
Referenced by boottrace_display(), calcru1(), cputick2timespec(), fill_kinfo_proc_only(), and fill_kinfo_thread().
DPCPU_DEFINE_STATIC | ( | uint64_t | , |
tc_cpu_ticks_base | |||
) |
DPCPU_DEFINE_STATIC | ( | unsigned | , |
tc_cpu_ticks_last | |||
) |
void dtrace_getnanotime | ( | struct timespec * | tsp | ) |
Definition at line 1013 of file kern_tc.c.
References GETTHMEMBER.
void dtrace_getnanouptime | ( | struct timespec * | tsp | ) |
Definition at line 1025 of file kern_tc.c.
References bintime(), bt, and GETTHMEMBER.
|
static |
void getbintime | ( | struct bintime * | bt | ) |
Definition at line 465 of file kern_tc.c.
References bt, and GETTHMEMBER.
void getbinuptime | ( | struct bintime * | bt | ) |
Definition at line 440 of file kern_tc.c.
References bt, and GETTHMEMBER.
Referenced by cpu_tick_calibrate(), and init_va_filerev().
void getboottime | ( | struct timeval * | boottime | ) |
Definition at line 487 of file kern_tc.c.
References bintime(), and getboottimebin().
Referenced by acct_process(), fill_kinfo_proc_only(), procdesc_stat(), and sysctl_kern_boottime().
void getboottimebin | ( | struct bintime * | boottimebin | ) |
Definition at line 496 of file kern_tc.c.
References GETTHMEMBER.
Referenced by filt_timervalidate(), getboottime(), kqtimer_proc_continue(), sysclock_snap2bintime(), and umtx_abs_timeout_getsbt().
void getmicrotime | ( | struct timeval * | tvp | ) |
Definition at line 479 of file kern_tc.c.
References GETTHMEMBER.
Referenced by ttydisc_read_raw_read_timer().
void getmicrouptime | ( | struct timeval * | tvp | ) |
Definition at line 456 of file kern_tc.c.
References bintime(), bt, and GETTHMEMBER.
Referenced by ratecheck(), and realitexpire().
void getnanotime | ( | struct timespec * | tsp | ) |
Definition at line 472 of file kern_tc.c.
References GETTHMEMBER.
Referenced by clock_dbgprint_hdr(), kern_clock_gettime(), kern_sem_wait(), mqueue_receive(), mqueue_send(), pipe_timestamp(), realtimer_clocktime(), resettodr(), settime_task_func(), and vfs_timestamp().
void getnanouptime | ( | struct timespec * | tsp | ) |
Definition at line 447 of file kern_tc.c.
References bintime(), bt, and GETTHMEMBER.
Referenced by kern_clock_gettime(), kern_sigtimedwait(), print_uptime(), realtimer_clocktime(), and vn_generic_copy_file_range().
|
static |
Definition at line 269 of file kern_tc.c.
References timehands::th_generation, and timehands.
|
static |
Definition at line 1997 of file kern_tc.c.
References hz, printf(), tc_adjprecision(), tc_setclock_mtx, tc_tick, tc_tick_bt, tc_tick_sbt, tc_windup(), tick_bt, tick_sbt, and timecounter.
|
static |
Definition at line 1974 of file kern_tc.c.
References tc_from_tunable, tc_lock, timehands::th_next, ths, and timehands_count.
void microtime | ( | struct timeval * | tvp | ) |
Definition at line 431 of file kern_tc.c.
Referenced by settime(), sys_gettimeofday(), unp_internalize(), and vfs_timestamp().
void microuptime | ( | struct timeval * | tvp | ) |
Definition at line 406 of file kern_tc.c.
References bintime(), binuptime(), and bt.
Referenced by acct_process(), do_fork(), hardclock_device_poll(), itimer_proc_continue(), kern_getitimer(), kern_setitimer(), netisr_poll(), netisr_pollmore(), proc0_post(), realitexpire(), and tty_info().
MTX_SYSINIT | ( | tc_setclock_init | , |
& | tc_setclock_mtx, | ||
"tcsetc" | , | ||
MTX_SPIN | |||
) |
void nanotime | ( | struct timespec * | tsp | ) |
Definition at line 422 of file kern_tc.c.
Referenced by kern_clock_gettime(), ntp_gettime1(), tc_setclock(), unp_internalize(), and vfs_timestamp().
void nanouptime | ( | struct timespec * | tsp | ) |
Definition at line 397 of file kern_tc.c.
References bintime(), binuptime(), and bt.
Referenced by kern_clock_gettime(), and unp_internalize().
void pps_capture | ( | struct pps_state * | pps | ) |
Definition at line 1761 of file kern_tc.c.
References timehands::th_counter, timehands::th_generation, and timehands.
void pps_event | ( | struct pps_state * | pps, |
int | event | ||
) |
|
static |
Definition at line 1592 of file kern_tc.c.
References abi_aware(), and tvtohz().
Referenced by pps_ioctl().
void pps_init | ( | struct pps_state * | pps | ) |
Definition at line 1736 of file kern_tc.c.
Referenced by pps_init_abi().
void pps_init_abi | ( | struct pps_state * | pps | ) |
Definition at line 1750 of file kern_tc.c.
References pps_init().
int pps_ioctl | ( | u_long | cmd, |
caddr_t | data, | ||
struct pps_state * | pps | ||
) |
Definition at line 1650 of file kern_tc.c.
References data, and pps_fetch().
|
static |
Definition at line 1344 of file kern_tc.c.
References timehands::th_adjustment, timehands::th_counter, timehands::th_large_delta, and timehands::th_scale.
Referenced by tc_windup().
void set_cputicker | ( | cpu_tick_f * | func, |
uint64_t | freq, | ||
unsigned | var | ||
) |
Definition at line 2131 of file kern_tc.c.
References cpu_tick_frequency, cpu_tick_variable, cpu_ticks, and tc_cpu_ticks().
|
static |
Definition at line 1265 of file kern_tc.c.
References rtc_generation.
Referenced by tc_setclock().
void sysclock_getsnapshot | ( | struct sysclock_snap * | clock_snap, |
int | fast | ||
) |
Definition at line 1048 of file kern_tc.c.
References bintime(), bt, sysclock_active, tc_delta(), timehands::th_generation, timehands::th_offset, timehands::th_scale, time_esterror, time_status, and timehands.
int sysclock_snap2bintime | ( | struct sysclock_snap * | cs, |
struct bintime * | bt, | ||
int | whichclock, | ||
uint32_t | flags | ||
) |
|
static |
Definition at line 2178 of file kern_tc.c.
References sysctl_handle_int(), and vdso_th_enable.
SYSCTL_INT | ( | _kern_timecounter | , |
OID_AUTO | , | ||
stepwarnings | , | ||
CTLFLAG_RWTUN | , | ||
& | timestepwarnings, | ||
0 | , | ||
"Log time steps" | |||
) |
SYSCTL_INT | ( | _kern_timecounter | , |
OID_AUTO | , | ||
tick | , | ||
CTLFLAG_RD | , | ||
& | tc_tick, | ||
0 | , | ||
"Approximate number of hardclock ticks in a millisecond" | |||
) |
SYSCTL_INT | ( | _kern_timecounter | , |
OID_AUTO | , | ||
timehands_count | , | ||
CTLFLAG_RDTUN| | CTLFLAG_NOFETCH, | ||
& | timehands_count, | ||
0 | , | ||
"Count of timehands in rotation" | |||
) |
|
static |
Definition at line 161 of file kern_tc.c.
References getboottime().
|
static |
Definition at line 1956 of file kern_tc.c.
References sysctl_handle_int(), tc_adjprecision(), and tc_timepercentage.
|
static |
Definition at line 1549 of file kern_tc.c.
References sbuf_delete(), sbuf_finish(), sbuf_new_for_sysctl(), sbuf_printf(), sbuf_putc(), sysctl_wire_old_buffer(), tc_lock, timecounter, and timecounters.
|
static |
Definition at line 193 of file kern_tc.c.
References sysctl_handle_64(), and timecounter.
Referenced by tc_init().
|
static |
Definition at line 183 of file kern_tc.c.
References sysctl_handle_int(), and timecounter.
Referenced by tc_init().
|
static |
Definition at line 1498 of file kern_tc.c.
References sysctl_handle_string(), tc_chosen, tc_lock, timecounter, and timecounters.
SYSCTL_NODE | ( | _kern | , |
OID_AUTO | , | ||
timecounter | , | ||
CTLFLAG_RW| | CTLFLAG_MPSAFE, | ||
0 | , | ||
"" | |||
) |
|
static |
SYSCTL_PROC | ( | _kern | , |
KERN_BOOTTIME | , | ||
boottime | , | ||
CTLTYPE_STRUCT|CTLFLAG_RD| | CTLFLAG_MPSAFE, | ||
NULL | , | ||
0 | , | ||
sysctl_kern_boottime | , | ||
" | S, | ||
timeval" | , | ||
"Estimated system boottime" | |||
) |
SYSCTL_PROC | ( | _kern_timecounter | , |
OID_AUTO | , | ||
alloweddeviation | , | ||
CTLTYPE_INT|CTLFLAG_RWTUN| | CTLFLAG_MPSAFE, | ||
0 | , | ||
0 | , | ||
sysctl_kern_timecounter_adjprecision | , | ||
"I" | , | ||
"Allowed time interval deviation in percents" | |||
) |
SYSCTL_PROC | ( | _kern_timecounter | , |
OID_AUTO | , | ||
choice | , | ||
CTLTYPE_STRING|CTLFLAG_RD| | CTLFLAG_MPSAFE, | ||
0 | , | ||
0 | , | ||
sysctl_kern_timecounter_choice | , | ||
"A" | , | ||
"Timecounter hardware detected" | |||
) |
SYSCTL_PROC | ( | _kern_timecounter | , |
OID_AUTO | , | ||
fast_gettime | , | ||
CTLTYPE_INT|CTLFLAG_RW| | CTLFLAG_MPSAFE, | ||
NULL | , | ||
0 | , | ||
sysctl_fast_gettime | , | ||
"I" | , | ||
"Enable fast time of day" | |||
) |
SYSCTL_PROC | ( | _kern_timecounter | , |
OID_AUTO | , | ||
hardware | , | ||
CTLTYPE_STRING|CTLFLAG_RWTUN|CTLFLAG_NOFETCH| | CTLFLAG_MPSAFE, | ||
0 | , | ||
0 | , | ||
sysctl_kern_timecounter_hardware | , | ||
"A" | , | ||
"Timecounter hardware selected" | |||
) |
SYSINIT | ( | timecounter | , |
SI_SUB_CLOCKS | , | ||
SI_ORDER_SECOND | , | ||
inittimecounter | , | ||
NULL | |||
) |
SYSINIT | ( | timehands | , |
SI_SUB_TUNABLES | , | ||
SI_ORDER_ANY | , | ||
inittimehands | , | ||
NULL | |||
) |
|
static |
Definition at line 1934 of file kern_tc.c.
References bt_tickthreshold, bt_timethreshold, hz, sbt_tickthreshold, sbt_timethreshold, tc_precexp, tc_tick, and tc_timepercentage.
Referenced by inittimecounter(), and sysctl_kern_timecounter_adjprecision().
|
static |
Definition at line 2045 of file kern_tc.c.
References res, timehands::th_counter, and timecounter.
Referenced by cpu_tickrate(), and set_cputicker().
|
static |
Definition at line 207 of file kern_tc.c.
References timehands::th_counter, timehands::th_offset_count, and timecounter.
Referenced by bintime_off(), sysclock_getsnapshot(), and tc_windup().
uint32_t tc_fill_vdso_timehands | ( | struct vdso_timehands * | vdso_th | ) |
Definition at line 2194 of file kern_tc.c.
References timehands::th_boottime, timehands::th_counter, timehands::th_offset, timehands::th_offset_count, timehands::th_scale, timehands, and vdso_th_enable.
Referenced by timehands_update().
uint64_t tc_getfrequency | ( | void | ) |
Definition at line 1258 of file kern_tc.c.
References timehands::th_counter.
Referenced by cpu_tickrate(), and kern_clock_getres().
void tc_init | ( | struct timecounter * | tc | ) |
Definition at line 1181 of file kern_tc.c.
References bootverbose, hz, printf(), sysctl_kern_timecounter_freq(), sysctl_kern_timecounter_get(), tc_chosen, tc_from_tunable, tc_lock, timecounter, and timecounters.
void tc_setclock | ( | struct timespec * | ts | ) |
Definition at line 1292 of file kern_tc.c.
References bintime(), binuptime(), bt, cpu_tick_calibrate(), log(), nanotime(), rtc_generation, sleeping_on_old_rtc(), sleepq_chains_remove_matching(), tc_setclock_mtx, tc_windup(), timestepwarnings, and ts.
Referenced by inittodr(), and settime().
void tc_ticktock | ( | int | cnt | ) |
Definition at line 1919 of file kern_tc.c.
References count, tc_setclock_mtx, tc_tick, and tc_windup().
Referenced by hardclock().
|
static |
Definition at line 1361 of file kern_tc.c.
References bintime(), bintime_add_tc_delta(), bt, cpu_disable_c2_sleep, LARGE_STEP, ntp_update_second(), recalculate_scaling_factor_and_large_delta(), sysclock_active, tc_delta(), tc_min_ticktock_freq, timehands::th_adjustment, timehands::th_bintime, timehands::th_boottime, timehands::th_counter, timehands::th_generation, timehands::th_large_delta, timehands::th_microtime, timehands::th_nanotime, timehands::th_next, timehands::th_offset, timehands::th_offset_count, timehands::th_scale, time_second, time_uptime, timecounter, timehands, and timekeep_push_vdso().
Referenced by inittimecounter(), tc_setclock(), and tc_ticktock().
struct bintime bt_tickthreshold |
Definition at line 136 of file kern_tc.c.
Referenced by tc_adjprecision().
struct bintime bt_timethreshold |
Definition at line 135 of file kern_tc.c.
Referenced by tc_adjprecision().
|
static |
Definition at line 2039 of file kern_tc.c.
Referenced by cpu_tick_calibrate(), cpu_tickrate(), and set_cputicker().
|
static |
Definition at line 2038 of file kern_tc.c.
Referenced by cpu_tick_calibrate(), and set_cputicker().
cpu_tick_f* cpu_ticks = tc_cpu_ticks |
Definition at line 2174 of file kern_tc.c.
Referenced by calcru(), cpu_tick_calibrate(), cpu_tickrate(), dotrace(), kern_process_cputime(), kern_thread_cputime(), mi_switch(), proc0_post(), rufetchtd(), sched_ap_entry(), set_cputicker(), statclock(), and thread_exit().
|
static |
volatile int rtc_generation = 1 |
Definition at line 149 of file kern_tc.c.
Referenced by kern_clock_nanosleep(), sleeping_on_old_rtc(), sleepq_switch(), tc_setclock(), and umtxq_sleep().
sbintime_t sbt_tickthreshold |
Definition at line 138 of file kern_tc.c.
Referenced by callout_when(), and tc_adjprecision().
sbintime_t sbt_timethreshold |
Definition at line 137 of file kern_tc.c.
Referenced by realitexpire(), and tc_adjprecision().
int sysclock_active = SYSCLOCK_FBCK |
Definition at line 1037 of file kern_tc.c.
Referenced by sysclock_getsnapshot(), and tc_windup().
|
static |
Definition at line 151 of file kern_tc.c.
Referenced by sysctl_kern_timecounter_hardware(), and tc_init().
|
static |
Definition at line 152 of file kern_tc.c.
Referenced by inittimehands(), and tc_init().
|
static |
Definition at line 101 of file kern_tc.c.
Referenced by init_turnstiles(), inittimehands(), sysctl_kern_timecounter_choice(), sysctl_kern_timecounter_hardware(), and tc_init().
int tc_min_ticktock_freq = 1 |
Definition at line 103 of file kern_tc.c.
Referenced by getnextcpuevent(), and tc_windup().
int tc_precexp |
Definition at line 141 of file kern_tc.c.
Referenced by callout_when(), kern_clock_nanosleep(), kern_poll_kfds(), kern_select(), kern_setitimer(), kqueue_scan(), realitexpire_reset_callout(), selsocket(), and tc_adjprecision().
|
static |
Definition at line 1284 of file kern_tc.c.
Referenced by inittimecounter(), tc_setclock(), and tc_ticktock().
|
static |
Definition at line 1914 of file kern_tc.c.
Referenced by inittimecounter(), tc_adjprecision(), and tc_ticktock().
struct bintime tc_tick_bt |
Definition at line 139 of file kern_tc.c.
Referenced by inittimecounter().
sbintime_t tc_tick_sbt |
Definition at line 140 of file kern_tc.c.
Referenced by inittimecounter(), kern_clock_nanosleep(), kern_poll_kfds(), kern_select(), kqueue_scan(), selsocket(), and umtx_abs_timeout_getsbt().
int tc_timepercentage = TC_DEFAULTPERC |
Definition at line 142 of file kern_tc.c.
Referenced by sysctl_kern_timecounter_adjprecision(), and tc_adjprecision().
|
static |
Definition at line 86 of file kern_tc.c.
Referenced by inittimehands().
|
extern |
Definition at line 157 of file kern_ntptime.c.
Referenced by kern_ntp_adjtime(), ntp_gettime1(), and sysclock_getsnapshot().
volatile time_t time_second = 1 |
Definition at line 105 of file kern_tc.c.
Referenced by dump_init_header(), kern_clock_gettime(), kern_msgctl(), kern_msgrcv(), kern_msgsnd(), kern_semctl(), kern_shmat_locked(), kern_shmctl_locked(), shm_delete_mapping(), shmget_allocate_segment(), sys_msgget(), sys_semget(), sys_semop(), tc_windup(), vfs_timestamp(), and vpanic().
|
extern |
Definition at line 151 of file kern_ntptime.c.
Referenced by hardupdate(), kern_ntp_adjtime(), ntp_gettime1(), ntp_update_second(), periodic_resettodr(), shutdown_resettodr(), and sysclock_getsnapshot().
volatile time_t time_uptime = 1 |
Definition at line 106 of file kern_tc.c.
Referenced by cpu_tick_calibration(), hardupdate(), msgbuf_addstr(), sched_sync(), and tc_windup().
struct timecounter* timecounter = &dummy_timecounter |
Definition at line 97 of file kern_tc.c.
Referenced by clockcalib(), inittimecounter(), sysctl_kern_timecounter_choice(), sysctl_kern_timecounter_freq(), sysctl_kern_timecounter_get(), sysctl_kern_timecounter_hardware(), tc_cpu_ticks(), tc_delta(), tc_init(), and tc_windup().
|
static |
Definition at line 98 of file kern_tc.c.
Referenced by sysctl_kern_timecounter_choice(), sysctl_kern_timecounter_hardware(), and tc_init().
Definition at line 96 of file kern_tc.c.
Referenced by bintime_off(), getthmember(), pps_capture(), sysclock_getsnapshot(), tc_fill_vdso_timehands(), and tc_windup().
|
static |
Definition at line 130 of file kern_tc.c.
Referenced by inittimehands().
|
static |
Definition at line 126 of file kern_tc.c.
Referenced by tc_setclock().
|
static |
Definition at line 2176 of file kern_tc.c.
Referenced by sysctl_fast_gettime(), and tc_fill_vdso_timehands().