diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/kern_tc.c | 7 | ||||
-rw-r--r-- | sys/sys/timetc.h | 4 |
2 files changed, 6 insertions, 5 deletions
diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c index 93b50a0..44d8986 100644 --- a/sys/kern/kern_tc.c +++ b/sys/kern/kern_tc.c @@ -12,6 +12,7 @@ #include "opt_ntp.h" #include <sys/param.h> +#include <sys/stdint.h> #include <sys/kernel.h> #include <sys/sysctl.h> #include <sys/systm.h> @@ -282,8 +283,8 @@ tc_init(struct timecounter *tc) { unsigned u; - printf("Timecounter \"%s\" frequency %lu Hz", - tc->tc_name, (u_long)tc->tc_frequency); + printf("Timecounter \"%s\" frequency %ju Hz", + tc->tc_name, (intmax_t)tc->tc_frequency); u = tc->tc_frequency / tc->tc_counter_mask; if (u > hz) { @@ -299,7 +300,7 @@ tc_init(struct timecounter *tc) } /* Report the frequency of the current timecounter. */ -u_int32_t +u_int64_t tc_getfrequency(void) { diff --git a/sys/sys/timetc.h b/sys/sys/timetc.h index f0d70d5..bc6a472 100644 --- a/sys/sys/timetc.h +++ b/sys/sys/timetc.h @@ -47,7 +47,7 @@ struct timecounter { */ u_int tc_counter_mask; /* This mask should mask off any unimplemented bits. */ - u_int32_t tc_frequency; + u_int64_t tc_frequency; /* Frequency of the counter in Hz. */ char *tc_name; /* Name of the timecounter. */ @@ -59,7 +59,7 @@ struct timecounter { extern struct timecounter *timecounter; -u_int32_t tc_getfrequency(void); +u_int64_t tc_getfrequency(void); void tc_init(struct timecounter *tc); void tc_setclock(struct timespec *ts); void tc_ticktock(void); |