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

[commits] r15313 - in /fsf/trunk/libc: ./ bits/ elf/ misc/bits/ misc/sys/ sysdeps/i386/bits/ sysdeps/powerpc/powerpc64/ sysdeps/x86_64...



Author: eglibc
Date: Wed Sep 14 00:02:36 2011
New Revision: 15313

Log:
Import glibc-mainline for 2011-09-14

Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/bits/select.h
    fsf/trunk/libc/elf/Makefile
    fsf/trunk/libc/elf/rtld.c
    fsf/trunk/libc/misc/bits/select2.h
    fsf/trunk/libc/misc/sys/select.h
    fsf/trunk/libc/sysdeps/i386/bits/select.h
    fsf/trunk/libc/sysdeps/powerpc/powerpc64/dl-machine.h
    fsf/trunk/libc/sysdeps/x86_64/bits/select.h

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Wed Sep 14 00:02:36 2011
@@ -1,3 +1,25 @@
+2011-09-13  Andreas Schwab  <schwab@xxxxxxxxxxxxxx>
+
+	* sysdeps/powerpc/powerpc64/dl-machine.h (elf_machine_rela):
+	Always define `refsym'.
+
+2011-09-13  Andreas Schwab  <schwab@xxxxxxxxxx>
+
+	* misc/sys/select.h (__FD_MASK): Renamed from __FDMASK.
+	(__FD_ELT): Renamed from __FDELT.
+	* misc/bits/select2.h (__FD_ELT): Likewise.
+	* bits/select.h (__FD_SET, __FD_CLR, __FD_ISSET): Use __FD_ELT,
+	__FD_MASK instead of __FDELT, __FDMASK.
+	* sysdeps/i386/bits/select.h (__FD_SET, __FD_CLR, __FD_ISSET):
+	Likewise.
+	* sysdeps/x86_64/bits/select.h (__FD_SET, __FD_CLR, __FD_ISSET):
+	Likewise.
+
+	* elf/Makefile (gen-ldd): Fix pattern.
+
+	* elf/rtld.c (dl_main): Only use USE___THREAD when defined.
+	(init_tls): Likewise.
+
 2011-09-12  Ulrich Drepper  <drepper@xxxxxxxxx>
 
 	* sysdeps/ieee754/dbl-64/wordsize-64/s_logb.c: New file.

Modified: fsf/trunk/libc/bits/select.h
==============================================================================
--- fsf/trunk/libc/bits/select.h (original)
+++ fsf/trunk/libc/bits/select.h Wed Sep 14 00:02:36 2011
@@ -31,7 +31,8 @@
       __FDS_BITS (__arr)[__i] = 0;					      \
   } while (0)
 #define __FD_SET(d, s) \
-  ((void) (__FDS_BITS (s)[__FDELT(d)] |= __FDMASK(d)))
+  ((void) (__FDS_BITS (s)[__FD_ELT(d)] |= __FD_MASK(d)))
 #define __FD_CLR(d, s) \
-  ((void) (__FDS_BITS (s)[__FDELT(d)] &= ~__FDMASK(d)))
-#define __FD_ISSET(d, s)   ((__FDS_BITS (s)[__FDELT (d)] & __FDMASK (d)) != 0)
+  ((void) (__FDS_BITS (s)[__FD_ELT(d)] &= ~__FD_MASK(d)))
+#define __FD_ISSET(d, s) \
+  ((__FDS_BITS (s)[__FD_ELT (d)] & __FD_MASK (d)) != 0)

Modified: fsf/trunk/libc/elf/Makefile
==============================================================================
--- fsf/trunk/libc/elf/Makefile (original)
+++ fsf/trunk/libc/elf/Makefile Wed Sep 14 00:02:36 2011
@@ -483,7 +483,7 @@
 else
 define gen-ldd
 LC_ALL=C sed $($(ldd-shell)-ldd-rewrite) < $< \
-| LC_ALL=C sed -f $(patsubst $(..)/,/,$(..)$(ldd-rewrite-script)) > $@.new
+| LC_ALL=C sed -f $(patsubst $(..)/%,/%,$(..)$(ldd-rewrite-script)) > $@.new
 endef
 endif
 

Modified: fsf/trunk/libc/elf/rtld.c
==============================================================================
--- fsf/trunk/libc/elf/rtld.c (original)
+++ fsf/trunk/libc/elf/rtld.c Wed Sep 14 00:02:36 2011
@@ -779,7 +779,12 @@
 
   /* And finally install it for the main thread.  If ld.so itself uses
      TLS we know the thread pointer was initialized earlier.  */
-  const char *lossage = TLS_INIT_TP (tcbp, USE___THREAD);
+  const char *lossage
+#ifdef USE___THREAD
+    = TLS_INIT_TP (tcbp, USE___THREAD);
+#else
+    = TLS_INIT_TP (tcbp, 0);
+#endif
   if (__builtin_expect (lossage != NULL, 0))
     _dl_fatal_printf ("cannot set up thread-local storage: %s\n", lossage);
   tls_init_tp_called = true;
@@ -2310,7 +2315,12 @@
      TLS we know the thread pointer was initialized earlier.  */
   if (! tls_init_tp_called)
     {
-      const char *lossage = TLS_INIT_TP (tcbp, USE___THREAD);
+      const char *lossage
+#ifdef USE___THREAD
+	= TLS_INIT_TP (tcbp, USE___THREAD);
+#else
+	= TLS_INIT_TP (tcbp, 0);
+#endif
       if (__builtin_expect (lossage != NULL, 0))
 	_dl_fatal_printf ("cannot set up thread-local storage: %s\n",
 			  lossage);

Modified: fsf/trunk/libc/misc/bits/select2.h
==============================================================================
--- fsf/trunk/libc/misc/bits/select2.h (original)
+++ fsf/trunk/libc/misc/bits/select2.h Wed Sep 14 00:02:36 2011
@@ -25,8 +25,8 @@
 extern unsigned long int __fdelt_chk (unsigned long int __d);
 extern unsigned long int __fdelt_warn (unsigned long int __d)
   __warnattr ("bit outside of fd_set selected");
-#undef __FDELT
-#define	__FDELT(d) \
+#undef __FD_ELT
+#define	__FD_ELT(d) \
   ({ unsigned long int __d = d;						    \
      (__builtin_constant_p (__d)					    \
       ? (__d >= __FD_SETSIZE						    \

Modified: fsf/trunk/libc/misc/sys/select.h
==============================================================================
--- fsf/trunk/libc/misc/sys/select.h (original)
+++ fsf/trunk/libc/misc/sys/select.h Wed Sep 14 00:02:36 2011
@@ -54,14 +54,12 @@
 /* The fd_set member is required to be an array of longs.  */
 typedef long int __fd_mask;
 
-/* Some versions of <linux/posix_types.h> define these macros.  */
+/* Some versions of <linux/posix_types.h> define this macros.  */
 #undef	__NFDBITS
-#undef	__FDELT
-#undef	__FDMASK
 /* It's easier to assume 8-bit bytes than to get CHAR_BIT.  */
 #define __NFDBITS	(8 * (int) sizeof (__fd_mask))
-#define	__FDELT(d)	((d) / __NFDBITS)
-#define	__FDMASK(d)	((__fd_mask) 1 << ((d) % __NFDBITS))
+#define	__FD_ELT(d)	((d) / __NFDBITS)
+#define	__FD_MASK(d)	((__fd_mask) 1 << ((d) % __NFDBITS))
 
 /* fd_set for select and pselect.  */
 typedef struct

Modified: fsf/trunk/libc/sysdeps/i386/bits/select.h
==============================================================================
--- fsf/trunk/libc/sysdeps/i386/bits/select.h (original)
+++ fsf/trunk/libc/sysdeps/i386/bits/select.h Wed Sep 14 00:02:36 2011
@@ -48,8 +48,8 @@
 #endif	/* GNU CC */
 
 #define __FD_SET(d, set) \
-  ((void) (__FDS_BITS (set)[__FDELT (d)] |= __FDMASK (d)))
+  ((void) (__FDS_BITS (set)[__FD_ELT (d)] |= __FD_MASK (d)))
 #define __FD_CLR(d, set) \
-  ((void) (__FDS_BITS (set)[__FDELT (d)] &= ~__FDMASK (d)))
+  ((void) (__FDS_BITS (set)[__FD_ELT (d)] &= ~__FD_MASK (d)))
 #define __FD_ISSET(d, set) \
-  ((__FDS_BITS (set)[__FDELT (d)] & __FDMASK (d)) != 0)
+  ((__FDS_BITS (set)[__FD_ELT (d)] & __FD_MASK (d)) != 0)

Modified: fsf/trunk/libc/sysdeps/powerpc/powerpc64/dl-machine.h
==============================================================================
--- fsf/trunk/libc/sysdeps/powerpc/powerpc64/dl-machine.h (original)
+++ fsf/trunk/libc/sysdeps/powerpc/powerpc64/dl-machine.h Wed Sep 14 00:02:36 2011
@@ -560,9 +560,7 @@
 {
   Elf64_Addr *const reloc_addr = reloc_addr_arg;
   const int r_type = ELF64_R_TYPE (reloc->r_info);
-#ifndef RTLD_BOOTSTRAP
   const Elf64_Sym *const refsym = sym;
-#endif
 
   if (r_type == R_PPC64_RELATIVE)
     {

Modified: fsf/trunk/libc/sysdeps/x86_64/bits/select.h
==============================================================================
--- fsf/trunk/libc/sysdeps/x86_64/bits/select.h (original)
+++ fsf/trunk/libc/sysdeps/x86_64/bits/select.h Wed Sep 14 00:02:36 2011
@@ -57,8 +57,8 @@
 #endif	/* GNU CC */
 
 #define __FD_SET(d, set) \
-  ((void) (__FDS_BITS (set)[__FDELT (d)] |= __FDMASK (d)))
+  ((void) (__FDS_BITS (set)[__FD_ELT (d)] |= __FD_MASK (d)))
 #define __FD_CLR(d, set) \
-  ((void) (__FDS_BITS (set)[__FDELT (d)] &= ~__FDMASK (d)))
+  ((void) (__FDS_BITS (set)[__FD_ELT (d)] &= ~__FD_MASK (d)))
 #define __FD_ISSET(d, set) \
-  ((__FDS_BITS (set)[__FDELT (d)] & __FDMASK (d)) != 0)
+  ((__FDS_BITS (set)[__FD_ELT (d)] & __FD_MASK (d)) != 0)