diff options
-rw-r--r-- | src/ChangeLog | 4 | ||||
-rw-r--r-- | src/hwfeatures.c | 9 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index c9d56fd0..c6e08de8 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-21 Marcus Brinkmann <marcus@g10code.de> + + * hwfeatures.c (detect_ia32_gnuc): Fix inline asm. + 2007-12-11 Werner Koch <wk@g10code.com> * visibility.c (gcry_md_hash_buffer): Don't use return vor a void diff --git a/src/hwfeatures.c b/src/hwfeatures.c index 200da2c2..4dd4e4f4 100644 --- a/src/hwfeatures.c +++ b/src/hwfeatures.c @@ -79,13 +79,12 @@ detect_ia32_gnuc (void) ("pushl %%ebx\n\t" /* Save GOT register. */ "xorl %%eax, %%eax\n\t" /* 0 -> EAX. */ "cpuid\n\t" /* Get vendor ID. */ - "leal %0, %%eax\n\t" /* EBX,EDX,ECX -> VENDOR_ID. */ - "movl %%ebx, (%%eax)\n\t" - "movl %%edx, 4(%%eax)\n\t" - "movl %%ecx, 8(%%eax)\n\t" + "movl %%ebx, (%0)\n\t" /* EBX,EDX,ECX -> VENDOR_ID. */ + "movl %%edx, 4(%0)\n\t" + "movl %%ecx, 8(%0)\n\t" "popl %%ebx\n" - : "=m" (vendor_id) : + : "S" (&vendor_id[0]) : "%eax", "%ecx", "%edx", "cc" ); vendor_id[12] = 0; |