summaryrefslogtreecommitdiff
path: root/sys/arch/i386/include/cpu.h
diff options
context:
space:
mode:
authorThomas Nordin <nordin@cvs.openbsd.org>2002-09-24 00:06:24 +0000
committerThomas Nordin <nordin@cvs.openbsd.org>2002-09-24 00:06:24 +0000
commitab4b95ffcece79129777c12ef6f57359cad0ac57 (patch)
treeb668d32e880f909117fb0b77520f400df7e72f1e /sys/arch/i386/include/cpu.h
parentbd4cd4bc31f25cda237420e9652344299167b4cf (diff)
Restore pentium_microtime, testing by henning@, millert@. ok deraadt@
Diffstat (limited to 'sys/arch/i386/include/cpu.h')
-rw-r--r--sys/arch/i386/include/cpu.h17
1 files changed, 4 insertions, 13 deletions
diff --git a/sys/arch/i386/include/cpu.h b/sys/arch/i386/include/cpu.h
index 7c73020e71f..4e6f61855b2 100644
--- a/sys/arch/i386/include/cpu.h
+++ b/sys/arch/i386/include/cpu.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: cpu.h,v 1.42 2002/06/07 21:33:43 nordin Exp $ */
+/* $OpenBSD: cpu.h,v 1.43 2002/09/24 00:06:23 nordin Exp $ */
/* $NetBSD: cpu.h,v 1.35 1996/05/05 19:29:26 christos Exp $ */
/*-
@@ -101,23 +101,14 @@ void delay(int);
void calibrate_cyclecounter(void);
#ifndef HZ
extern u_quad_t pentium_base_tsc;
-#define CPU_CLOCKUPDATE(otime, ntime) \
+#define CPU_CLOCKUPDATE() \
do { \
if (pentium_mhz) { \
__asm __volatile("cli\n" \
- "movl (%3), %%eax\n" \
- "movl %%eax, (%2)\n" \
- "movl 4(%3), %%eax\n" \
- "movl %%eax, 4(%2)\n" \
".byte 0xf, 0x31\n" \
"sti\n" \
- "#%0 %1 %2 %3" \
- : "=m" (*otime), \
- "=A" (pentium_base_tsc) \
- : "c" (otime), "b" (ntime)); \
- } \
- else { \
- *(otime) = *(ntime); \
+ : "=A" (pentium_base_tsc) \
+ : ); \
} \
} while (0)
#endif