clock: Use sysclock_t to save value from sys_cputimer->count()
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Wed, 19 Jun 2013 04:21:46 +0000 (12:21 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Wed, 19 Jun 2013 04:21:46 +0000 (12:21 +0800)
sys/platform/pc32/isa/clock.c
sys/platform/pc64/isa/clock.c

index 649d227..066731c 100644 (file)
@@ -349,7 +349,8 @@ i8254_intr_reload(struct cputimer_intr *cti, sysclock_t reload)
 static void
 DODELAY(int n, int doswitch)
 {
-       int delta, prev_tick, tick, ticks_left;
+       ssysclock_t delta, ticks_left;
+       sysclock_t prev_tick, tick;
 
 #ifdef DELAYDEBUG
        int getit_calls = 1;
@@ -522,7 +523,8 @@ static u_int
 calibrate_clocks(void)
 {
        u_int64_t old_tsc;
-       u_int count, prev_count, tot_count;
+       u_int tot_count;
+       sysclock_t count, prev_count;
        int sec, start_sec, timeout;
 
        if (bootverbose)
index f7091ab..9d7b750 100644 (file)
@@ -351,7 +351,8 @@ i8254_intr_reload(struct cputimer_intr *cti, sysclock_t reload)
 static void
 DODELAY(int n, int doswitch)
 {
-       int delta, prev_tick, tick, ticks_left;
+       ssysclock_t delta, ticks_left;
+       sysclock_t prev_tick, tick;
 
 #ifdef DELAYDEBUG
        int getit_calls = 1;
@@ -529,7 +530,8 @@ static u_int
 calibrate_clocks(void)
 {
        u_int64_t old_tsc;
-       u_int count, prev_count, tot_count;
+       u_int tot_count;
+       sysclock_t count, prev_count;
        int sec, start_sec, timeout;
 
        if (bootverbose)