Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.sbin/cpuctl/arch xgetbv expects XCR0 to be speficied in ...



details:   https://anonhg.NetBSD.org/src/rev/28e77707742a
branches:  trunk
changeset: 806586:28e77707742a
user:      tnn <tnn%NetBSD.org@localhost>
date:      Sun Mar 01 18:02:42 2015 +0000

description:
xgetbv expects XCR0 to be speficied in %ecx, don't leave %ecx undefined

diffstat:

 usr.sbin/cpuctl/arch/i386-asm.S   |  3 ++-
 usr.sbin/cpuctl/arch/x86_64-asm.S |  3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diffs (34 lines):

diff -r 14fc697f9236 -r 28e77707742a usr.sbin/cpuctl/arch/i386-asm.S
--- a/usr.sbin/cpuctl/arch/i386-asm.S   Sun Mar 01 15:37:26 2015 +0000
+++ b/usr.sbin/cpuctl/arch/i386-asm.S   Sun Mar 01 18:02:42 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i386-asm.S,v 1.3 2013/01/07 23:20:42 dsl Exp $ */
+/*     $NetBSD: i386-asm.S,v 1.4 2015/03/01 18:02:42 tnn Exp $ */
 
 /*-
  * Copyright (c) 1998, 2000, 2004, 2006, 2007 The NetBSD Foundation, Inc.
@@ -49,6 +49,7 @@
 END(x86_cpuid2)
 
 ENTRY(x86_xgetbv)
+       xorl    %ecx, %ecx
        xgetbv
        ret
 END(x86_xgetbv)
diff -r 14fc697f9236 -r 28e77707742a usr.sbin/cpuctl/arch/x86_64-asm.S
--- a/usr.sbin/cpuctl/arch/x86_64-asm.S Sun Mar 01 15:37:26 2015 +0000
+++ b/usr.sbin/cpuctl/arch/x86_64-asm.S Sun Mar 01 18:02:42 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: x86_64-asm.S,v 1.4 2013/01/07 23:20:42 dsl Exp $       */
+/*     $NetBSD: x86_64-asm.S,v 1.5 2015/03/01 18:02:42 tnn Exp $       */
 
 /*-
  * Copyright (c) 2007 The NetBSD Foundation, Inc.
@@ -44,6 +44,7 @@
        ret
 
 ENTRY(x86_xgetbv)
+       xorl    %ecx, %ecx
        xgetbv
        ret
 



Home | Main Index | Thread Index | Old Index