summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2002-05-20 00:16:45 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2002-05-20 00:16:45 +0000
commit2174fc097a2387ef38ea68c8c45550adfaf29bf0 (patch)
treed54f7f422ca62a8494bbf6f6181df5208ff2654a /sys
parenta9459ac2e2b3d8c59c51e2e66c263966f8fd72d3 (diff)
hardclock() is not called until clock has been initialized
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/hppa/dev/clock.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/arch/hppa/dev/clock.c b/sys/arch/hppa/dev/clock.c
index 735fff9d9ca..5ac7a5437db 100644
--- a/sys/arch/hppa/dev/clock.c
+++ b/sys/arch/hppa/dev/clock.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: clock.c,v 1.14 2002/05/14 20:41:33 mickey Exp $ */
+/* $OpenBSD: clock.c,v 1.15 2002/05/20 00:16:44 mickey Exp $ */
/*
* Copyright (c) 1998,1999 Michael Shalayeff
@@ -53,6 +53,7 @@
#endif
struct timeval time;
+int cpu_clockok;
void startrtclock(void);
@@ -65,6 +66,8 @@ cpu_initclocks()
/* Start the interval timer. */
mfctl(CR_ITMR, time_inval);
mtctl(time_inval + cpu_hzticks, CR_ITMR);
+
+ cpu_clockok = 1;
}
int
@@ -76,6 +79,9 @@ clock_intr (v)
/* printf ("clock int 0x%x @ 0x%x for %p\n", t,
frame->tf_iioq_head, curproc); */
+ if (!cpu_clockok)
+ return (1);
+
cpu_initclocks();
hardclock(frame);