From ce24f8fa5fc80e3018f42768f3aa1b3f7a5ef30c Mon Sep 17 00:00:00 2001 From: peter Date: Mon, 6 Jan 2003 01:01:08 +0000 Subject: [PATCH] Explicitly have the timecounter init happen after the cpu_initclocks is called. Otherwise (depending on a non-deterministic sort), the timecounter code can be initialized before the clock rate has been set (on ia64) and it assumes hz = 100, rather than the real value of 1024. I'm not sure how much gets upset by this. Glanced at by: phk --- sys/kern/kern_ntptime.c | 2 +- sys/kern/kern_tc.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/kern/kern_ntptime.c b/sys/kern/kern_ntptime.c index 26467d8913e6..016c1d67207d 100644 --- a/sys/kern/kern_ntptime.c +++ b/sys/kern/kern_ntptime.c @@ -596,7 +596,7 @@ ntp_init() #endif /* PPS_SYNC */ } -SYSINIT(ntpclocks, SI_SUB_CLOCKS, SI_ORDER_FIRST, ntp_init, NULL) +SYSINIT(ntpclocks, SI_SUB_CLOCKS, SI_ORDER_MIDDLE, ntp_init, NULL) /* * hardupdate() - local clock update diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c index 13a319036563..bfe154f92231 100644 --- a/sys/kern/kern_tc.c +++ b/sys/kern/kern_tc.c @@ -693,4 +693,4 @@ inittimecounter(void *dummy) (void)timecounter->tc_get_timecount(timecounter); } -SYSINIT(timecounter, SI_SUB_CLOCKS, SI_ORDER_FIRST, inittimecounter, NULL) +SYSINIT(timecounter, SI_SUB_CLOCKS, SI_ORDER_SECOND, inittimecounter, NULL)