diff options
author | 2004-07-23 21:00:09 +0000 | |
---|---|---|
committer | 2004-07-23 21:00:09 +0000 | |
commit | 4314af0051d639105db46f9bbf49b3b7e210489f (patch) | |
tree | d91b6e010cd039589b2fe78f71d5f5453cbccbfc | |
parent | add a manpage for /etc/defaultdomain (diff) | |
download | wireguard-openbsd-4314af0051d639105db46f9bbf49b3b7e210489f.tar.xz wireguard-openbsd-4314af0051d639105db46f9bbf49b3b7e210489f.zip |
Better delay code for MVME188. Should make console and network much more
reactive.
-rw-r--r-- | sys/arch/mvme88k/dev/clock.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/arch/mvme88k/dev/clock.c b/sys/arch/mvme88k/dev/clock.c index 0cf6d10a38c..cb2e4061e38 100644 --- a/sys/arch/mvme88k/dev/clock.c +++ b/sys/arch/mvme88k/dev/clock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clock.c,v 1.31 2004/07/02 14:00:42 miod Exp $ */ +/* $OpenBSD: clock.c,v 1.32 2004/07/23 21:00:09 miod Exp $ */ /* * Copyright (c) 1999 Steve Murphree, Jr. * Copyright (c) 1995 Theo de Raadt @@ -597,10 +597,13 @@ void delay(int us) { if (brdtyp == BRD_188) { + extern int cpuspeed; + /* * Unable to use a real timer, use a tight loop. + * XXX not accurate! */ - volatile int c = (25 * us) / 3; /* XXX not accurate! */ + volatile int c = (3 * us) / (cpuspeed == 25 ? 4 : 5); while (--c > 0) ; } else { |