summaryrefslogtreecommitdiff
path: root/sys/arch/i386/i386/microtime.s
diff options
context:
space:
mode:
authorThomas Nordin <nordin@cvs.openbsd.org>2002-07-06 19:14:21 +0000
committerThomas Nordin <nordin@cvs.openbsd.org>2002-07-06 19:14:21 +0000
commitadb28585e4802d642142e770be7ef276683bb58f (patch)
tree6016909e7ec82b58a471cd40838fb68a0d275d3d /sys/arch/i386/i386/microtime.s
parent4f23015d08ae2c991a6560c6d70151190bec00b8 (diff)
Remove kernel support for NTP. ok deraadt@ and tholo@
Diffstat (limited to 'sys/arch/i386/i386/microtime.s')
-rw-r--r--sys/arch/i386/i386/microtime.s32
1 files changed, 3 insertions, 29 deletions
diff --git a/sys/arch/i386/i386/microtime.s b/sys/arch/i386/i386/microtime.s
index eb0667d9d6b..22ad3b82224 100644
--- a/sys/arch/i386/i386/microtime.s
+++ b/sys/arch/i386/i386/microtime.s
@@ -1,4 +1,4 @@
-/* $OpenBSD: microtime.s,v 1.14 2001/09/20 17:02:30 mpech Exp $ */
+/* $OpenBSD: microtime.s,v 1.15 2002/07/06 19:14:20 nordin Exp $ */
/* $NetBSD: microtime.s,v 1.16 1995/04/17 12:06:47 cgd Exp $ */
/*-
@@ -48,13 +48,7 @@
#ifndef HZ
ENTRY(microtime)
-#if (defined(I586_CPU) || defined(I686_CPU)) && defined(NTP)
- movl _pentium_mhz, %ecx
- testl %ecx, %ecx
- jne pentium_microtime
-#else
xorl %ecx,%ecx
-#endif
movb $(TIMER_SEL0|TIMER_LATCH),%al
pushfl
@@ -140,32 +134,12 @@ common_microtime:
ret
#if defined(I586_CPU) || defined(I686_CPU)
+ # XXX: Move to machdep.c?
+
.data
.globl _pentium_base_tsc
.comm _pentium_base_tsc,8
.text
-
-#if defined (NTP)
- .align 2, 0x90
-pentium_microtime:
- pushfl
- cli
- .byte 0x0f, 0x31 # RDTSC
- subl _pentium_base_tsc,%eax
- sbbl _pentium_base_tsc+4,%edx
- /*
- * correct the high word first so we won't
- * receive a result overflow aka div/0 fault
- */
- pushl %eax
- movl %edx, %eax
- shll $16, %edx
- divw %cx
- movzwl %dx, %edx
- popl %eax
- divl %ecx
- jmp common_microtime
-#endif
#endif
#endif