Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/i386/isa Recalculate delaytab[]. We need to round ...



details:   https://anonhg.NetBSD.org/src/rev/7b8c31c7d9cd
branches:  trunk
changeset: 467810:7b8c31c7d9cd
user:      mycroft <mycroft%NetBSD.org@localhost>
date:      Mon Mar 29 17:54:34 1999 +0000

description:
Recalculate delaytab[].  We need to round up in case we were on the edge of a
tick and the hardware mysteriously responds fast enough that the delay ends
up being 1 tick short.  An unlikely event, but just in case anything actually
relies on this...

diffstat:

 sys/arch/i386/isa/clock.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (24 lines):

diff -r 2caa4eeb83c7 -r 7b8c31c7d9cd sys/arch/i386/isa/clock.c
--- a/sys/arch/i386/isa/clock.c Mon Mar 29 17:33:29 1999 +0000
+++ b/sys/arch/i386/isa/clock.c Mon Mar 29 17:54:34 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clock.c,v 1.60 1999/03/29 17:33:29 mycroft Exp $       */
+/*     $NetBSD: clock.c,v 1.61 1999/03/29 17:54:34 mycroft Exp $       */
 
 /*-
  * Copyright (c) 1993, 1994 Charles M. Hannum.
@@ -322,10 +322,10 @@
        int n;
 {
        int tick, otick;
-       static int delaytab[26] = {
-                0,  1,  2,  4,  5,  6,  7,  8, 10, 11,
-               12, 13, 14, 16, 17, 18, 19, 20, 21, 23,
-               24, 25, 26, 27, 29, 30,
+       static const int delaytab[26] = {
+                0,  2,  3,  4,  5,  6,  7,  9, 10, 11,
+               12, 13, 15, 16, 17, 18, 19, 21, 22, 23,
+               24, 25, 27, 28, 29, 30,
        };
 
        /* allow DELAY() to be used before startrtclock() */



Home | Main Index | Thread Index | Old Index