summaryrefslogtreecommitdiffstats
path: root/sys/i386
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1999-01-09 13:07:18 +0000
committerbde <bde@FreeBSD.org>1999-01-09 13:07:18 +0000
commit97a75ce74241ef194ab458a10d1e24e1de0e27cf (patch)
tree5cc0596dda2196114b55358ed694ac2b3b61d7ae /sys/i386
parentcea612c7820bfb144a3e6e478758d7163d4a293b (diff)
downloadFreeBSD-src-97a75ce74241ef194ab458a10d1e24e1de0e27cf.zip
FreeBSD-src-97a75ce74241ef194ab458a10d1e24e1de0e27cf.tar.gz
Don't put operands in clobber lists, since this is dubious for old
versions of gcc and broken for current versions of egcs. Cleaned up the asm statement for do_cpuid() a little. Submitted by: "John S. Dyson" <dyson@iquest.net> but rewritten by me
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/i386/identcpu.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sys/i386/i386/identcpu.c b/sys/i386/i386/identcpu.c
index f5a1ead..f962882 100644
--- a/sys/i386/i386/identcpu.c
+++ b/sys/i386/i386/identcpu.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* from: Id: machdep.c,v 1.193 1996/06/18 01:22:04 bde Exp
- * $Id: identcpu.c,v 1.54 1998/12/27 23:23:26 msmith Exp $
+ * $Id: identcpu.c,v 1.55 1999/01/08 16:29:56 bde Exp $
*/
#include "opt_cpu.h"
@@ -106,13 +106,13 @@ do_cpuid(u_int ax, u_int *p)
{
__asm __volatile(
".byte 0x0f, 0xa2;"
- "movl %%eax, (%%esi);"
- "movl %%ebx, (4)(%%esi);"
- "movl %%ecx, (8)(%%esi);"
- "movl %%edx, (12)(%%esi);"
- :
- : "a" (ax), "S" (p)
- : "ax", "bx", "cx", "dx"
+ "movl %%eax, (%2);"
+ "movl %%ebx, 4(%2);"
+ "movl %%ecx, 8(%2);"
+ "movl %%edx, 12(%2);"
+ : "=a" (ax)
+ : "0" (ax), "S" (p)
+ : "bx", "cx", "dx"
);
}
OpenPOWER on IntegriCloud