Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/amd64/amd64 xen needs the TSC funcs too
details: https://anonhg.NetBSD.org/src/rev/c915aca8818e
branches: trunk
changeset: 1010251:c915aca8818e
user: ad <ad%NetBSD.org@localhost>
date: Tue May 19 21:54:10 2020 +0000
description:
xen needs the TSC funcs too
diffstat:
sys/arch/amd64/amd64/cpufunc.S | 40 ++++++++++++++++++++--------------------
1 files changed, 20 insertions(+), 20 deletions(-)
diffs (61 lines):
diff -r f27279e20e53 -r c915aca8818e sys/arch/amd64/amd64/cpufunc.S
--- a/sys/arch/amd64/amd64/cpufunc.S Tue May 19 21:52:04 2020 +0000
+++ b/sys/arch/amd64/amd64/cpufunc.S Tue May 19 21:54:10 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpufunc.S,v 1.53 2020/05/19 21:40:55 ad Exp $ */
+/* $NetBSD: cpufunc.S,v 1.54 2020/05/19 21:54:10 ad Exp $ */
/*
* Copyright (c) 1998, 2007, 2008, 2020 The NetBSD Foundation, Inc.
@@ -167,25 +167,6 @@
STRONG_ALIAS(x86_write_psl,x86_write_flags)
-ENTRY(tsc_get_timecount)
- movq CPUVAR(CURLWP), %rcx
-1:
- movq L_NCSW(%rcx), %rdi
- rdtsc
- shlq $32, %rdx
- orq %rdx, %rax
- addq CPUVAR(CC_SKEW), %rax
- cmpq %rdi, L_NCSW(%rcx)
- jne 2f
- KMSAN_INIT_RET(4)
- ret
-2:
- jmp 1b
-END(tsc_get_timecount)
-
-STRONG_ALIAS(cpu_counter, tsc_get_timecount)
-STRONG_ALIAS(cpu_counter32, tsc_get_timecount)
-
/*
* %rdi = name
* %rsi = sel
@@ -225,6 +206,25 @@
END(x86_hotpatch)
#endif /* !XENPV */
+ENTRY(tsc_get_timecount)
+ movq CPUVAR(CURLWP), %rcx
+1:
+ movq L_NCSW(%rcx), %rdi
+ rdtsc
+ shlq $32, %rdx
+ orq %rdx, %rax
+ addq CPUVAR(CC_SKEW), %rax
+ cmpq %rdi, L_NCSW(%rcx)
+ jne 2f
+ KMSAN_INIT_RET(4)
+ ret
+2:
+ jmp 1b
+END(tsc_get_timecount)
+
+STRONG_ALIAS(cpu_counter, tsc_get_timecount)
+STRONG_ALIAS(cpu_counter32, tsc_get_timecount)
+
ENTRY(rdmsr_safe)
movq CPUVAR(CURLWP), %r8
movq L_PCB(%r8), %r8
Home |
Main Index |
Thread Index |
Old Index