svn commit: trunk/uClibc/libpthread/linuxthreads/sysdeps/i386
vapier at uclibc.org
vapier at uclibc.org
Thu Sep 8 04:24:27 UTC 2005
Author: vapier
Date: 2005-09-07 21:24:25 -0700 (Wed, 07 Sep 2005)
New Revision: 11397
Log:
import some fixes from glibc
Modified:
trunk/uClibc/libpthread/linuxthreads/sysdeps/i386/useldt.h
Changeset:
Modified: trunk/uClibc/libpthread/linuxthreads/sysdeps/i386/useldt.h
===================================================================
--- trunk/uClibc/libpthread/linuxthreads/sysdeps/i386/useldt.h 2005-09-08 04:07:49 UTC (rev 11396)
+++ trunk/uClibc/libpthread/linuxthreads/sysdeps/i386/useldt.h 2005-09-08 04:24:25 UTC (rev 11397)
@@ -24,6 +24,7 @@
#include <stdlib.h> /* For abort(). */
+
/* We don't want to include the kernel header. So duplicate the
information. */
@@ -76,7 +77,7 @@
#ifdef __PIC__
# define USETLS_EBX_ARG "r"
-# define USETLS_LOAD_EBX "xchgl %3, %%ebx\n\t"
+# define USETLS_LOAD_EBX "xchgl %1, %%ebx\n\t"
#else
# define USETLS_EBX_ARG "b"
# define USETLS_LOAD_EBX
@@ -108,8 +109,10 @@
"movl %2, %%eax\n\t" \
"int $0x80\n\t" \
USETLS_LOAD_EBX \
- : "&a" (__result) \
- : USETLS_EBX_ARG (&ldt_entry), "i" (__NR_set_thread_area)); \
+ : "=&a" (__result) \
+ : USETLS_EBX_ARG (&ldt_entry), "i" (__NR_set_thread_area), \
+ "m" (ldt_entry) \
+ : "memory"); \
if (__result == 0) \
asm ("movw %w0, %%gs" :: "q" (__gs)); \
else \
@@ -126,8 +129,10 @@
"movl %2, %%eax\n\t" \
"int $0x80\n\t" \
USETLS_LOAD_EBX \
- : "&a" (__result) \
- : USETLS_EBX_ARG (&ldt_entry), "i" (__NR_set_thread_area)); \
+ : "=&a" (__result) \
+ : USETLS_EBX_ARG (&ldt_entry), "i" (__NR_set_thread_area), \
+ "m" (ldt_entry) \
+ : "memory"); \
if (__result == 0) \
{ \
__gs = (ldt_entry.entry_number << 3) + 3; \
More information about the uClibc-cvs
mailing list