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

[Commits] r17154 - in /fsf/trunk/ports: ./ sysdeps/alpha/ sysdeps/mips/ sysdeps/mips/sys/ sysdeps/unix/alpha/ sysdeps/unix/mips/ sysde...



Author: eglibc
Date: Thu Feb 16 00:05:41 2012
New Revision: 17154

Log:
Import glibc-ports-mainline for 2012-02-16

Added:
    fsf/trunk/ports/sysdeps/mips/dl-procinfo.c
    fsf/trunk/ports/sysdeps/mips/dl-procinfo.h
    fsf/trunk/ports/sysdeps/mips/sys/tas.h
    fsf/trunk/ports/sysdeps/unix/mips/entry.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/bits/signalfd.h
Removed:
    fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/entry.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/tas.h
Modified:
    fsf/trunk/ports/ChangeLog.alpha
    fsf/trunk/ports/ChangeLog.arm
    fsf/trunk/ports/ChangeLog.mips
    fsf/trunk/ports/sysdeps/alpha/preconfigure
    fsf/trunk/ports/sysdeps/mips/dl-machine.h
    fsf/trunk/ports/sysdeps/mips/dl-trampoline.c
    fsf/trunk/ports/sysdeps/unix/alpha/sysdep.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in
    fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h

Modified: fsf/trunk/ports/ChangeLog.alpha
==============================================================================
--- fsf/trunk/ports/ChangeLog.alpha (original)
+++ fsf/trunk/ports/ChangeLog.alpha Thu Feb 16 00:05:41 2012
@@ -1,3 +1,22 @@
+2012-02-15  Richard Henderson  <rth@xxxxxxxxxxx>
+
+	* sysdeps/unix/alpha/sysdeps.S: Don't check __ELF__, USE___THREAD,
+	or _LIBC_REENTRANT.
+
+2012-02-15  Richard Henderson  <rth@xxxxxxxxxxx>
+
+	[BZ #13361]
+	* sysdeps/unix/sysv/linux/alpha/bits/fcntl.h (struct file_handle): New.
+	(fallocate, name_to_handle_at, open_by_handle_at): Declare.
+
+2012-02-14  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+	    Tom de Vries  <tom@xxxxxxxxxxxxxxxx>
+
+	* sysdeps/alpha/preconfigure: Make setting of libc_commonpagesize and
+	libc_relro_required conditional on alpha machine.  Move setting of
+	libc_cv_gcc_unwind_find_fde ...
+	* sysdeps/unix/sysv/linux/alpha/configure.in: ... here.
+
 2012-02-13  Richard Henderson  <rth@xxxxxxxxxxx>
 
         * sysdeps/unix/sysv/linux/alpha/bits/eventfd.h: New file.

Modified: fsf/trunk/ports/ChangeLog.arm
==============================================================================
--- fsf/trunk/ports/ChangeLog.arm (original)
+++ fsf/trunk/ports/ChangeLog.arm Thu Feb 16 00:05:41 2012
@@ -1,3 +1,9 @@
+2012-02-15  Khem Raj  <raj.khem@xxxxxxxxx>
+
+	[BZ #12097]
+	* sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S: Disable
+	contents unless __thumb__.
+
 2012-02-08  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/arm/crti.S, sysdeps/arm/crtn.S: New files, based on

Modified: fsf/trunk/ports/ChangeLog.mips
==============================================================================
--- fsf/trunk/ports/ChangeLog.mips (original)
+++ fsf/trunk/ports/ChangeLog.mips Thu Feb 16 00:05:41 2012
@@ -1,3 +1,40 @@
+2012-02-15  Robert Millan  <rmh@xxxxxxx>
+
+	[BZ #12301]
+	* sysdeps/unix/sysv/linux/mips/mips32/sysdep.h [__ASSEMBLER__]
+	[__PIC__] (SYSCALL_ERROR_LABEL): New macro.
+
+2012-02-15  Robert Millan  <rmh@xxxxxxx>
+
+	[BZ #12298]
+	* sysdeps/unix/sysv/linux/mips/sys/tas.h: Moved to ...
+	* sysdeps/mips/sys/tas.h: ... here.
+
+2012-02-15  Robert Millan  <rmh@xxxxxxx>
+
+	[BZ #12297]
+	* sysdeps/mips/dl-machine.h: Fix a comment regarding __start.
+	* sysdeps/unix/sysv/linux/mips/entry.h: Moved to ...
+	* sysdeps/unix/mips/entry.h: ... here.
+
+2012-02-15  Robert Millan  <rmh@xxxxxxx>
+
+	[BZ #12193]
+	* sysdeps/mips/dl-machine.h (DL_PLATFORM_INIT, dl_platform_init):
+	Define.
+	* sysdeps/mips/dl-procinfo.c: New file.
+	* sysdeps/mips/dl-procinfo.h: Likewise.
+
+2012-02-15  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/mips/bits/signalfd.h: New file.
+	* sysdeps/unix/sysv/linux/mips/sys/signalfd.h: Remove.
+
+2012-02-15  Viju Vincent  <vijuvince@xxxxxxxxx>
+
+	* sysdeps/mips/dl-trampoline.c (__dl_runtime_resolve): Use locking
+	around calls to _dl_lookup_symbol_x.
+
 2012-02-13  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/unix/sysv/linux/mips/bits/inotify.h: New file.

Modified: fsf/trunk/ports/sysdeps/alpha/preconfigure
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/preconfigure (original)
+++ fsf/trunk/ports/sysdeps/alpha/preconfigure Thu Feb 16 00:05:41 2012
@@ -1,10 +1,7 @@
 case "$machine" in
-alpha*)		base_machine=alpha machine=alpha/$machine ;;
+alpha*)		base_machine=alpha machine=alpha/$machine
+		# Parameters to allow auto-detection of -z relro.
+		libc_commonpagesize=0x2000
+		libc_relro_required=yes ;;
 esac
 
-# We did historically export the unwinder from glibc.
-libc_cv_gcc_unwind_find_fde=yes
-
-# Parameters to allow auto-detection of -z relro.
-libc_commonpagesize=0x2000
-libc_relro_required=yes

Modified: fsf/trunk/ports/sysdeps/mips/dl-machine.h
==============================================================================
--- fsf/trunk/ports/sysdeps/mips/dl-machine.h (original)
+++ fsf/trunk/ports/sysdeps/mips/dl-machine.h Thu Feb 16 00:05:41 2012
@@ -1,6 +1,5 @@
 /* Machine-dependent ELF dynamic relocation inline functions.  MIPS version.
-   Copyright (C) 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2011
-   Free Software Foundation, Inc.
+   Copyright (C) 1996-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Kazumoto Kojima <kkojima@xxxxxxxxxxxxxxxxxxxxx>.
 
@@ -209,7 +208,7 @@
       when it is called to store away the arguments passed
       to it.
 
-   2) That under Linux the entry is named __start
+   2) That under Unix the entry is named __start
       and not just plain _start.  */
 
 #define RTLD_START asm (\
@@ -296,6 +295,18 @@
 #  define ARCH_LA_PLTEXIT mips_n64_gnu_pltexit
 # endif
 
+/* We define an initialization function.  This is called very early in
+   _dl_sysdep_start.  */
+#define DL_PLATFORM_INIT dl_platform_init ()
+
+static inline void __attribute__ ((unused))
+dl_platform_init (void)
+{
+  if (GLRO(dl_platform) != NULL && *GLRO(dl_platform) == '\0')
+    /* Avoid an empty string which would disturb us.  */
+    GLRO(dl_platform) = NULL;
+}
+
 /* For a non-writable PLT, rewrite the .got.plt entry at RELOC_ADDR to
    point at the symbol with address VALUE.  For a writable PLT, rewrite
    the corresponding PLT entry instead.  */

Added: fsf/trunk/ports/sysdeps/mips/dl-procinfo.c
==============================================================================
--- fsf/trunk/ports/sysdeps/mips/dl-procinfo.c (added)
+++ fsf/trunk/ports/sysdeps/mips/dl-procinfo.c Thu Feb 16 00:05:41 2012
@@ -1,0 +1,64 @@
+/* Data for Mips version of processor capability information.
+   Copyright (C) 2007-2012 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Robert Millan <rmh@xxxxxxx>.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+/* This information must be kept in sync with the _DL_PLATFORM_COUNT
+   definitions in procinfo.h.
+
+   If anything should be added here check whether the size of each string
+   is still ok with the given array size.
+
+   All the #ifdefs in the definitions are quite irritating but
+   necessary if we want to avoid duplicating the information.  There
+   are three different modes:
+
+   - PROCINFO_DECL is defined.  This means we are only interested in
+     declarations.
+
+   - PROCINFO_DECL is not defined:
+
+     + if SHARED is defined the file is included in an array
+       initializer.  The .element = { ... } syntax is needed.
+
+     + if SHARED is not defined a normal array initialization is
+       needed.
+  */
+
+#ifndef PROCINFO_CLASS
+#define PROCINFO_CLASS
+#endif
+
+#if !defined PROCINFO_DECL && defined SHARED
+  ._dl_mips_platforms
+#else
+PROCINFO_CLASS const char _dl_mips_platforms[4][11]
+#endif
+#ifndef PROCINFO_DECL
+= {
+    "loongson2e", "loongson2f", "octeon", "octeon2"
+  }
+#endif
+#if !defined SHARED || defined PROCINFO_DECL
+;
+#else
+,
+#endif
+
+#undef PROCINFO_DECL
+#undef PROCINFO_CLASS

Added: fsf/trunk/ports/sysdeps/mips/dl-procinfo.h
==============================================================================
--- fsf/trunk/ports/sysdeps/mips/dl-procinfo.h (added)
+++ fsf/trunk/ports/sysdeps/mips/dl-procinfo.h Thu Feb 16 00:05:41 2012
@@ -1,0 +1,68 @@
+/* Mips version of processor capability information handling macros.
+   Copyright (C) 2007-2012 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Robert Millan <rmh@xxxxxxx>.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#ifndef _DL_PROCINFO_H
+#define _DL_PROCINFO_H	1
+
+#include <ldsodefs.h>
+
+
+/* Mask to filter out platforms.  */
+#define _DL_HWCAP_PLATFORM    (-1ULL)
+
+#define _DL_PLATFORMS_COUNT   1
+
+static inline const char *
+__attribute__ ((unused))
+_dl_platform_string (int idx)
+{
+  return GLRO(dl_mips_platforms)[idx];
+};
+
+static inline int
+__attribute__ ((unused, always_inline))
+_dl_string_platform (const char *str)
+{
+  int i;
+
+  if (str != NULL)
+    for (i = 0; i < _DL_PLATFORMS_COUNT; ++i)
+      {
+        if (strcmp (str, _dl_platform_string (i)) == 0)
+          return i;
+      }
+  return -1;
+};
+
+/* We cannot provide a general printing function.  */
+#define _dl_procinfo(word) -1
+
+/* There are no hardware capabilities defined.  */
+#define _dl_hwcap_string(idx) ""
+
+/* By default there is no important hardware capability.  */
+#define HWCAP_IMPORTANT (0)
+
+/* We don't have any hardware capabilities.  */
+#define _DL_HWCAP_COUNT	0
+
+#define _dl_string_hwcap(str) (-1)
+
+#endif /* dl-procinfo.h */

Modified: fsf/trunk/ports/sysdeps/mips/dl-trampoline.c
==============================================================================
--- fsf/trunk/ports/sysdeps/mips/dl-trampoline.c (original)
+++ fsf/trunk/ports/sysdeps/mips/dl-trampoline.c Thu Feb 16 00:05:41 2012
@@ -26,6 +26,7 @@
 #include <elf.h>
 #include <ldsodefs.h>
 #include <dl-machine.h>
+#include <sysdep-cancel.h>
 
 /* Get link map for callers object containing STUB_PC.  */
 static inline struct link_map *
@@ -153,17 +154,44 @@
 
 	    if (version->hash != 0)
 	      {
+                /* We need to keep the scope around so do some locking.  This is
+		   not necessary for objects which cannot be unloaded or when
+		   we are not using any threads (yet).  */
+		if (!RTLD_SINGLE_THREAD_P)
+		  THREAD_GSCOPE_SET_FLAG ();
+
 		sym_map = _dl_lookup_symbol_x (strtab + sym->st_name, l,
 					       &sym, l->l_scope, version,
 					       ELF_RTYPE_CLASS_PLT, 0, 0);
+
+                /* We are done with the global scope.  */
+		if (!RTLD_SINGLE_THREAD_P)
+		  THREAD_GSCOPE_RESET_FLAG ();
+
 		break;
 	      }
 	    /* Fall through.  */
 	  }
 	case 0:
+	  {
+          /* We need to keep the scope around so do some locking.  This is
+	     not necessary for objects which cannot be unloaded or when
+	     we are not using any threads (yet).  */
+	  int flags = DL_LOOKUP_ADD_DEPENDENCY;
+	  if (!RTLD_SINGLE_THREAD_P)
+	    {
+	      THREAD_GSCOPE_SET_FLAG ();
+	      flags |= DL_LOOKUP_GSCOPE_LOCK;
+	    }
+
 	  sym_map = _dl_lookup_symbol_x (strtab + sym->st_name, l, &sym,
 					 l->l_scope, 0, ELF_RTYPE_CLASS_PLT,
-					 DL_LOOKUP_ADD_DEPENDENCY, 0);
+					 flags, 0);
+
+          /* We are done with the global scope.  */
+	  if (!RTLD_SINGLE_THREAD_P)
+	    THREAD_GSCOPE_RESET_FLAG ();
+	  }
 	}
 
       /* Currently value contains the base load address of the object

Added: fsf/trunk/ports/sysdeps/mips/sys/tas.h
==============================================================================
--- fsf/trunk/ports/sysdeps/mips/sys/tas.h (added)
+++ fsf/trunk/ports/sysdeps/mips/sys/tas.h Thu Feb 16 00:05:41 2012
@@ -1,0 +1,70 @@
+/* Copyright (C) 2000, 2002, 2003, 2004, 2007, 2009
+   Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Maciej W. Rozycki <macro@xxxxxxxxxxxxx>, 2000.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#ifndef _SYS_TAS_H
+#define _SYS_TAS_H 1
+
+#include <features.h>
+#include <sgidefs.h>
+
+__BEGIN_DECLS
+
+extern int _test_and_set (int *__p, int __v) __THROW;
+
+#ifdef __USE_EXTERN_INLINES
+
+# ifndef _EXTERN_INLINE
+#  define _EXTERN_INLINE __extern_inline
+# endif
+
+_EXTERN_INLINE int
+__NTH (_test_and_set (int *__p, int __v))
+{
+  int __r, __t;
+
+  __asm__ __volatile__
+    ("/* Inline test and set */\n"
+     ".set	push\n\t"
+#if _MIPS_SIM == _ABIO32
+     ".set	mips2\n\t"
+#endif
+     "sync\n\t"
+     "1:\n\t"
+     "ll	%0,%3\n\t"
+     "move	%1,%4\n\t"
+     "beq	%0,%4,2f\n\t"
+     "sc	%1,%2\n\t"
+     "beqz	%1,1b\n"
+     "sync\n\t"
+     ".set	pop\n\t"
+     "2:\n\t"
+     "/* End test and set */"
+     : "=&r" (__r), "=&r" (__t), "=m" (*__p)
+     : "m" (*__p), "r" (__v)
+     : "memory");
+
+  return __r;
+}
+
+#endif /* __USE_EXTERN_INLINES */
+
+__END_DECLS
+
+#endif /* sys/tas.h */

Modified: fsf/trunk/ports/sysdeps/unix/alpha/sysdep.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/alpha/sysdep.S (original)
+++ fsf/trunk/ports/sysdeps/unix/alpha/sysdep.S Thu Feb 16 00:05:41 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1996, 1998, 2002, 2003, 2004
+/* Copyright (C) 1993, 1996, 1998, 2002, 2003, 2004, 2012
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Brendan Kehoe (brendan@xxxxxxx).
@@ -21,7 +21,7 @@
 #include <sysdep.h>
 #include <features.h>
 
-#if defined(__ELF__) && defined(PIC)
+#if defined(PIC)
 	/* Put this at the end of libc's text segment so that all of
 	   the direct branches from the syscalls are forward, and 
 	   thus predicted not taken.  */
@@ -30,106 +30,38 @@
 	.text
 #endif
 
-#ifdef PIC
-	/* When building a shared library, we branch here without
-	   having loaded the GP.  Nor, since it was a direct branch,
-	   have we loaded PV with our address.  Do both.  */
-# define LOADGP		br pv, 1f; 1: ldgp gp, 0(pv)
-# define PROLOGUE	.prologue 0
-# define EPILOGUE
-#else
-	/* When building the static library, we tail call here from
-	   elsewhere, which might use a different GP.  The entertaining
-	   part is that we have to return with the GP of our caller
-	   in place, so that linker relaxation works properly.  */
-	/* ??? This is so ugly.  Consider always putting the errno
-	   setting code with the syscall in the static case.  */
-# define GPSAVEREG	t10
-# define LOADGP		ldah	t11, 0(pv) !gpdisp!1;		\
-			br	1f;				\
-			.subsection 2;				\
-			1: mov	gp, GPSAVEREG;			\
-			lda	gp, 0(t11) !gpdisp!1;		\
-			br	2f;				\
-			.previous;				\
-			mov	gp, GPSAVEREG;			\
-			2:
-# define PROLOGUE	.prologue 1
-# define EPILOGUE	mov	GPSAVEREG, gp
-#endif
-
-	.align 4
-	.globl __syscall_error
-	.ent __syscall_error
-__syscall_error:
-
-#if defined(_LIBC_REENTRANT) && USE___THREAD
-
 #ifndef NOT_IN_libc
 # define SYSCALL_ERROR_ERRNO __libc_errno
 #else
 # define SYSCALL_ERROR_ERRNO errno
 #endif
 
-	LOADGP
-	PROLOGUE
+	.align 4
+	.globl	__syscall_error
+	.ent	__syscall_error
+__syscall_error:
+	/* When building a shared library, we branch here without having
+	   loaded the GP.  Nor, since it was a direct branch, have we
+	   loaded PV with our address.
+
+	   When building a static library, we tail call here from another
+	   object file, possibly with a different GP, and must return with
+	   the GP of our caller in place so that linker relaxation works.
+
+	   Both issues are solved by computing the GP into T1 instead of
+	   clobbering the traditional GP register.  */
+	.prologue 0
 	mov	v0, t0
+	br	t1, 1f
+1:	ldah	t1, 0(t1) !gpdisp!1
 	call_pal PAL_rduniq
-	ldq	t1, SYSCALL_ERROR_ERRNO(gp) !gottprel
-	addq	v0, t1, v0
-	stl	t0, 0(v0)
+
+	lda	t1, 0(t1) !gpdisp!1
+	ldq	t1, SYSCALL_ERROR_ERRNO(t1) !gottprel
+	addq	v0, t1, t1
 	lda	v0, -1
-	EPILOGUE
+
+	stl	t0, 0(t1)
 	ret
 
-#elif defined(_LIBC_REENTRANT)
-
-	LOADGP
-	lda	sp, -32(sp)
-	.frame	sp, 32, ra, 0
-	stq	ra, 0(sp)
-	stq	v0, 8(sp)
-#ifdef GPSAVEREG
-	stq	GPSAVEREG, 16(sp)
-#endif
-	.mask	0x4000001, -32
-	PROLOGUE
-
-	/* Find our per-thread errno address  */
-#if defined PIC && !defined IS_IN_librt
-	bsr	ra, __errno_location	!samegp
-#else
-	jsr	ra, __errno_location
-#ifndef GPSAVEREG
-	ldgp	gp, 0(ra)
-#endif
-#endif
-
-	/* Store the error value.  */
-	ldq	t0, 8(sp)
-	stl	t0, 0(v0)
-
-	/* And kick back a -1.  */
-	ldi	v0, -1
-
-#ifdef GPSAVEREG
-	ldq	GPSAVEREG, 16(sp)
-#endif
-	ldq	ra, 0(sp)
-	lda	sp, 32(sp)
-	EPILOGUE
-	ret
-
-#else
-
-	LOADGP
-	PROLOGUE
-	stl	v0, errno
-	lda	v0, -1
-	EPILOGUE
-	ret
-
-#endif
-
-	.subsection 3
 	.end __syscall_error

Added: fsf/trunk/ports/sysdeps/unix/mips/entry.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/mips/entry.h (added)
+++ fsf/trunk/ports/sysdeps/unix/mips/entry.h Thu Feb 16 00:05:41 2012
@@ -1,0 +1,5 @@
+#ifndef __ASSEMBLY__
+extern void __start (void);
+#endif
+
+#define ENTRY_POINT __start

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/fcntl.h Thu Feb 16 00:05:41 2012
@@ -1,5 +1,5 @@
 /* O_*, F_*, FD_* bit values for Linux.
-   Copyright (C) 1995-2000,2004,2005,2006,2007,2010 Free Software Foundation, Inc.
+   Copyright (C) 1995-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -223,6 +223,18 @@
 					   we splice from/to).  */
 # define SPLICE_F_MORE		4	/* Expect more data.  */
 # define SPLICE_F_GIFT		8	/* Pages passed in are a gift.  */
+
+/* File handle structure.  */
+struct file_handle
+{
+  unsigned int handle_bytes;
+  int handle_type;
+  /* File identifier.  */
+  unsigned char f_handle[0];
+};
+
+/* Maximum handle size (for now).  */
+# define MAX_HANDLE_SZ	128
 #endif
 
 __BEGIN_DECLS
@@ -252,6 +264,38 @@
 extern ssize_t tee (int __fdin, int __fdout, size_t __len,
 		    unsigned int __flags);
 
+/* Reserve storage for the data of the file associated with FD.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+# ifndef __USE_FILE_OFFSET64
+extern int fallocate (int __fd, int __mode, __off_t __offset, __off_t __len);
+# else
+#  ifdef __REDIRECT
+extern int __REDIRECT (fallocate, (int __fd, int __mode, __off64_t __offset,
+				   __off64_t __len),
+		       fallocate64);
+#  else
+#   define fallocate fallocate64
+#  endif
+# endif
+# ifdef __USE_LARGEFILE64
+extern int fallocate64 (int __fd, int __mode, __off64_t __offset,
+			__off64_t __len);
+# endif
+
+/* Map file name to file handle.  */
+extern int name_to_handle_at (int __dfd, const char *__name,
+			      struct file_handle *__handle, int *__mnt_id,
+			      int __flags) __THROW;
+
+/* Open file using the file handle.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern int open_by_handle_at (int __mountdirfd, struct file_handle *__handle,
+			      int __flags);
+
 #endif
 
 __END_DECLS

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure Thu Feb 16 00:05:41 2012
@@ -6,3 +6,6 @@
 # require TLS (ver 2.6.0), it seems pointless to fix them.
 # ??? Surely this should now be the generic default.
 arch_minimum_kernel=2.6.0
+
+# We did historically export the unwinder from glibc.
+libc_cv_gcc_unwind_find_fde=yes

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in Thu Feb 16 00:05:41 2012
@@ -6,3 +6,6 @@
 # require TLS (ver 2.6.0), it seems pointless to fix them.
 # ??? Surely this should now be the generic default.
 arch_minimum_kernel=2.6.0
+
+# We did historically export the unwinder from glibc.
+libc_cv_gcc_unwind_find_fde=yes

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S Thu Feb 16 00:05:41 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 2010 Free Software Foundation, Inc.
+/* Copyright (C) 2010-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -25,6 +25,7 @@
    ARM unwind tables for register to register moves, the actual opcodes
    are not defined.  */
 
+#if defined(__thumb__)
 	.thumb
 	.syntax unified
 	.hidden __libc_do_syscall
@@ -44,3 +45,5 @@
 	pop	{r7, pc}
 	.fnend
 END (__libc_do_syscall)
+
+#endif /* __thumb__ */

Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/bits/signalfd.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/bits/signalfd.h (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/bits/signalfd.h Thu Feb 16 00:05:41 2012
@@ -1,0 +1,29 @@
+/* Copyright (C) 2007-2012 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, see
+   <http://www.gnu.org/licenses/>.  */
+
+#ifndef	_SYS_SIGNALFD_H
+# error "Never use <bits/signalfd.h> directly; include <sys/signalfd.h> instead."
+#endif
+
+/* Flags for signalfd.  */
+enum
+  {
+    SFD_CLOEXEC = 02000000,
+#define SFD_CLOEXEC SFD_CLOEXEC
+    SFD_NONBLOCK = 00000200
+#define SFD_NONBLOCK SFD_NONBLOCK
+  };

Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/entry.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/entry.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/entry.h (removed)
@@ -1,5 +1,0 @@
-#ifndef __ASSEMBLY__
-extern void __start (void);
-#endif
-
-#define ENTRY_POINT __start

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/sysdep.h Thu Feb 16 00:05:41 2012
@@ -37,7 +37,15 @@
 #undef SYS_ify
 #define SYS_ify(syscall_name)	__NR_##syscall_name
 
-#ifndef __ASSEMBLER__
+#ifdef __ASSEMBLER__
+
+/* We don't want the label for the error handler to be visible in the symbol
+   table when we define it here.  */
+#ifdef __PIC__
+# define SYSCALL_ERROR_LABEL 99b
+#endif
+
+#else   /* ! __ASSEMBLER__ */
 
 /* Define a macro which expands into the inline wrapper code for a system
    call.  */

Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/signalfd.h (removed)
@@ -1,66 +1,0 @@
-/* Copyright (C) 2007, 2008 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Lesser General Public
-   License as published by the Free Software Foundation; either
-   version 2.1 of the License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Lesser General Public License for more details.
-
-   You should have received a copy of the GNU Lesser General Public
-   License along with the GNU C Library; if not, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#ifndef	_SYS_SIGNALFD_H
-#define	_SYS_SIGNALFD_H	1
-
-#define __need_sigset_t
-#include <signal.h>
-#include <stdint.h>
-
-
-struct signalfd_siginfo
-{
-  uint32_t ssi_signo;
-  int32_t ssi_errno;
-  int32_t ssi_code;
-  uint32_t ssi_pid;
-  uint32_t ssi_uid;
-  int32_t ssi_fd;
-  uint32_t ssi_tid;
-  uint32_t ssi_band;
-  uint32_t ssi_overrun;
-  uint32_t ssi_trapno;
-  int32_t ssi_status;
-  int32_t ssi_int;
-  uint64_t ssi_ptr;
-  uint64_t ssi_utime;
-  uint64_t ssi_stime;
-  uint64_t ssi_addr;
-  uint8_t __pad[48];
-};
-
-/* Flags for signalfd.  */
-enum
-  {
-    SFD_CLOEXEC = 02000000,
-#define SFD_CLOEXEC SFD_CLOEXEC
-    SFD_NONBLOCK = 0200
-#define SFD_NONBLOCK SFD_NONBLOCK
-  };
-
-__BEGIN_DECLS
-
-/* Request notification for delivery of signals in MASK to be
-   performed using descriptor FD.*/
-extern int signalfd (int __fd, const sigset_t *__mask, int __flags)
-  __THROW __nonnull ((2));
-
-__END_DECLS
-
-#endif /* sys/signalfd.h */

Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/tas.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/tas.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/sys/tas.h (removed)
@@ -1,70 +1,0 @@
-/* Copyright (C) 2000, 2002, 2003, 2004, 2007, 2009
-   Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Maciej W. Rozycki <macro@xxxxxxxxxxxxx>, 2000.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Lesser General Public
-   License as published by the Free Software Foundation; either
-   version 2.1 of the License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Lesser General Public License for more details.
-
-   You should have received a copy of the GNU Lesser General Public
-   License along with the GNU C Library; if not, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#ifndef _SYS_TAS_H
-#define _SYS_TAS_H 1
-
-#include <features.h>
-#include <sgidefs.h>
-
-__BEGIN_DECLS
-
-extern int _test_and_set (int *__p, int __v) __THROW;
-
-#ifdef __USE_EXTERN_INLINES
-
-# ifndef _EXTERN_INLINE
-#  define _EXTERN_INLINE __extern_inline
-# endif
-
-_EXTERN_INLINE int
-__NTH (_test_and_set (int *__p, int __v))
-{
-  int __r, __t;
-
-  __asm__ __volatile__
-    ("/* Inline test and set */\n"
-     ".set	push\n\t"
-#if _MIPS_SIM == _ABIO32
-     ".set	mips2\n\t"
-#endif
-     "sync\n\t"
-     "1:\n\t"
-     "ll	%0,%3\n\t"
-     "move	%1,%4\n\t"
-     "beq	%0,%4,2f\n\t"
-     "sc	%1,%2\n\t"
-     "beqz	%1,1b\n"
-     "sync\n\t"
-     ".set	pop\n\t"
-     "2:\n\t"
-     "/* End test and set */"
-     : "=&r" (__r), "=&r" (__t), "=m" (*__p)
-     : "m" (*__p), "r" (__v)
-     : "memory");
-
-  return __r;
-}
-
-#endif /* __USE_EXTERN_INLINES */
-
-__END_DECLS
-
-#endif /* sys/tas.h */

_______________________________________________
Commits mailing list
Commits@xxxxxxxxxx
http://eglibc.org/cgi-bin/mailman/listinfo/commits