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

[Commits] r24854 - in /fsf/trunk/libc/ports: ./ sysdeps/ia64/ sysdeps/ia64/bits/ sysdeps/unix/sysv/linux/ia64/



Author: eglibc
Date: Wed Dec 25 00:01:55 2013
New Revision: 24854

Log:
Import glibc-mainline for 2013-12-25

Added:
    fsf/trunk/libc/ports/sysdeps/ia64/sotruss-lib.c
Modified:
    fsf/trunk/libc/ports/ChangeLog.ia64
    fsf/trunk/libc/ports/sysdeps/ia64/bits/link.h
    fsf/trunk/libc/ports/sysdeps/unix/sysv/linux/ia64/ioperm.c

Modified: fsf/trunk/libc/ports/ChangeLog.ia64
==============================================================================
--- fsf/trunk/libc/ports/ChangeLog.ia64 (original)
+++ fsf/trunk/libc/ports/ChangeLog.ia64 Wed Dec 25 00:01:55 2013
@@ -1,3 +1,15 @@
+2013-12-24  Mike Frysinger  <vapier@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/ia64/ioperm.c: Delete code behind #if 0.
+
+2013-12-24  Mike Frysinger  <vapier@xxxxxxxxxx>
+
+	* sysdeps/ia64/sotruss-lib.c: New file.
+
+2013-12-24  Mike Frysinger  <vapier@xxxxxxxxxx>
+
+	* sysdeps/ia64/bits/link.h: Fix whitespace.
+
 2013-11-28  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/ia64/fpu/fegetround.c (fegetround): Use libm_hidden_def.

Modified: fsf/trunk/libc/ports/sysdeps/ia64/bits/link.h
==============================================================================
--- fsf/trunk/libc/ports/sysdeps/ia64/bits/link.h (original)
+++ fsf/trunk/libc/ports/sysdeps/ia64/bits/link.h Wed Dec 25 00:01:55 2013
@@ -46,17 +46,17 @@
 __BEGIN_DECLS
 
 extern Elf64_Addr la_ia64_gnu_pltenter (Elf64_Sym *__sym, unsigned int __ndx,
-				       uintptr_t *__refcook,
-				       uintptr_t *__defcook,
-				       La_ia64_regs *__regs,
-				       unsigned int *__flags,
-				       const char *__symname,
-				       long int *__framesizep);
-extern unsigned int la_ia64_gnu_pltexit (Elf64_Sym *__sym, unsigned int __ndx,
 					uintptr_t *__refcook,
 					uintptr_t *__defcook,
-					const La_ia64_regs *__inregs,
-					La_ia64_retval *__outregs,
-					const char *__symname);
+					La_ia64_regs *__regs,
+					unsigned int *__flags,
+					const char *__symname,
+					long int *__framesizep);
+extern unsigned int la_ia64_gnu_pltexit (Elf64_Sym *__sym, unsigned int __ndx,
+					 uintptr_t *__refcook,
+					 uintptr_t *__defcook,
+					 const La_ia64_regs *__inregs,
+					 La_ia64_retval *__outregs,
+					 const char *__symname);
 
 __END_DECLS

Added: fsf/trunk/libc/ports/sysdeps/ia64/sotruss-lib.c
==============================================================================
--- fsf/trunk/libc/ports/sysdeps/ia64/sotruss-lib.c (added)
+++ fsf/trunk/libc/ports/sysdeps/ia64/sotruss-lib.c Wed Dec 25 00:01:55 2013
@@ -1,0 +1,50 @@
+/* Override generic sotruss-lib.c to define actual functions for ia64.
+   Copyright (C) 2012-2013 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/>.  */
+
+#define HAVE_ARCH_PLTENTER
+#define HAVE_ARCH_PLTEXIT
+
+#include <elf/sotruss-lib.c>
+
+ElfW(Addr)
+la_ia64_gnu_pltenter (ElfW(Sym) *sym __attribute__ ((unused)),
+		      unsigned int ndx __attribute__ ((unused)),
+		      uintptr_t *refcook, uintptr_t *defcook,
+		      La_ia64_regs *regs, unsigned int *flags,
+		      const char *symname, long int *framesizep)
+{
+  print_enter (refcook, defcook, symname,
+	       regs->lr_gr[0], regs->lr_gr[1], regs->lr_gr[2], *flags);
+
+  /* No need to copy anything, we will not need the parameters in any case.  */
+  *framesizep = 0;
+
+  return sym->st_value;
+}
+
+unsigned int
+la_ia64_gnu_pltexit (ElfW(Sym) *sym, unsigned int ndx, uintptr_t *refcook,
+		     uintptr_t *defcook,
+		     const struct La_ia64_regs *inregs,
+		     struct La_ia64_retval *outregs, const char *symname)
+{
+  print_exit (refcook, defcook, symname, outregs->lrv_r8);
+
+  return 0;
+}

Modified: fsf/trunk/libc/ports/sysdeps/unix/sysv/linux/ia64/ioperm.c
==============================================================================
--- fsf/trunk/libc/ports/sysdeps/unix/sysv/linux/ia64/ioperm.c (original)
+++ fsf/trunk/libc/ports/sysdeps/unix/sysv/linux/ia64/ioperm.c Wed Dec 25 00:01:55 2013
@@ -59,11 +59,7 @@
 int
 _ioperm (unsigned long int from, unsigned long int num, int turn_on)
 {
-#if 0
-  unsigned long int addr, len, base;
-#endif
   unsigned long int base;
-  int prot;
 
   /* this test isn't as silly as it may look like; consider overflows! */
   if (from >= MAX_PORT || from + num > MAX_PORT)
@@ -91,14 +87,9 @@
 	    return -1;
 
 	  len = io_offset (MAX_PORT);
-#if 1
 	  /* see comment below */
 	  base = (unsigned long int) __mmap (0, len, PROT_READ | PROT_WRITE, MAP_SHARED,
 						fd, phys_io_base);
-#else
-	  base = (unsigned long int) __mmap (0, len, PROT_NONE, MAP_SHARED,
-						fd, phys_io_base);
-#endif
 	  __close (fd);
 
 	  if ((long) base == -1)
@@ -106,25 +97,19 @@
 
 	  io.base = base;
 	}
-      prot = PROT_READ | PROT_WRITE;
     }
   else
     {
       if (!io.base)
 	return 0;	/* never was turned on... */
-
-      prot = PROT_NONE;
-    }
-#if 0
+    }
+
   /* We can't do mprotect because that would cause us to lose the
      uncached flag that the /dev/mem driver turned on.  A MAP_UNCACHED
-     flag seems so much cleaner...  */
-  addr = (io.base + io_offset (from)) & io.page_mask;
-  len  = io.base + io_offset (from + num) - addr;
-  return mprotect ((void *) addr, len, prot);
-#else
+     flag seems so much cleaner...
+
+     See the history of this file for a version that tried mprotect.  */
   return 0;
-#endif
 }
 
 int

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