summaryrefslogtreecommitdiff
path: root/sys/arch/amd64/isa
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2004-06-25 11:03:29 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2004-06-25 11:03:29 +0000
commit1738a99caa862954a176f61a5b39322cb4d236a9 (patch)
tree8174d0a279102d74dc7834b5f2bbfeb6475e7664 /sys/arch/amd64/isa
parent553a08a83999f0198ea42221d73ef0c373884e6a (diff)
SMP support. Big parts from NetBSD, but with some really serious debugging
done by me, niklas and others. Especially wrt. NXE support. Still needs some polishing, especially in dmesg messages, but we're now building kernel faster than ever.
Diffstat (limited to 'sys/arch/amd64/isa')
-rw-r--r--sys/arch/amd64/isa/clock.c31
1 files changed, 5 insertions, 26 deletions
diff --git a/sys/arch/amd64/isa/clock.c b/sys/arch/amd64/isa/clock.c
index fcf6db666e5..2132a6e5b63 100644
--- a/sys/arch/amd64/isa/clock.c
+++ b/sys/arch/amd64/isa/clock.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: clock.c,v 1.3 2004/03/22 19:43:29 nordin Exp $ */
+/* $OpenBSD: clock.c,v 1.4 2004/06/25 11:03:28 art Exp $ */
/* $NetBSD: clock.c,v 1.1 2003/04/26 18:39:50 fvdl Exp $ */
/*-
@@ -184,7 +184,7 @@ mc146818_write(sc, reg, datum)
DELAY(1);
}
-static u_long rtclock_tval;
+u_long rtclock_tval;
/* minimal initialization, enough for delay() */
void
@@ -313,28 +313,7 @@ int
clockintr(void *arg)
{
struct clockframe *frame = arg;
-#if defined(I586_CPU) || defined(I686_CPU)
- static int microset_iter; /* call cc_microset once/sec */
- struct cpu_info *ci = curcpu();
-
- /*
- * If we have a cycle counter, do the microset thing.
- */
- if (ci->ci_feature_flags & CPUID_TSC) {
- if (
-#if defined(MULTIPROCESSOR)
- CPU_IS_PRIMARY(ci) &&
-#endif
- (microset_iter--) == 0) {
- cc_microset_time = time;
- microset_iter = hz - 1;
-#if defined(MULTIPROCESSOR)
- x86_broadcast_ipi(X86_IPI_MICROSET);
-#endif
- cc_microset(ci);
- }
- }
-#endif
+
hardclock(frame);
return 1;
@@ -383,7 +362,7 @@ gettick()
* wave' mode counts at 2:1).
*/
void
-delay(int n)
+i8254_delay(int n)
{
int limit, tick, otick;
static const int delaytab[26] = {
@@ -518,7 +497,7 @@ rtcdrain(void *v)
}
void
-cpu_initclocks()
+i8254_initclocks()
{
static struct timeout rtcdrain_timeout;