]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Thu, 20 Feb 2003 22:23:34 +0000 (22:23 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 20 Feb 2003 22:23:34 +0000 (22:23 +0000)
2002-07-24  Philip Blundell  <philb@gnu.org>

* sysdeps/unix/sysv/linux/arm/ioperm.c (init_iosys): Yield ENODEV
on unknown systems.

2003-02-20  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

* sysdeps/powerpc/powerpc32/atomicity.h: Remove compiler workaround.
* sysdeps/unix/sysv/linux/kernel-features.h
(__ASSUME_NEW_PRCTL_SYSCALL): Defined for ppc32 too.
* sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c: Use prctl
if possible.
* sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: Avoid short
interprocedure branches.
* sysdeps/powerpc/soft-fp/Dist (sim-full.c, fenv_const.c): Move to...
* sysdeps/powerpc/nofpu/Dist: ...here.
* sysdeps/unix/sysv/linux/powerpc/Dist (fe_nomask.c): Move to...
* sysdeps/unix/sysv/linux/powerpc/powerpc32/Dist: ...here.
* sysdeps/unix/sysv/linux/s390/s390-64/Dist (kernel_stat.h): Delete.
* sysdeps/unix/sysv/linux/sparc/Dist (bits/utmpx.h): Delete.
* sysdeps/unix/sysv/linux/x86_64/Dist (bits/utmpx.h): Delete.

15 files changed:
ChangeLog
linuxthreads/ChangeLog
linuxthreads/sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S
sysdeps/powerpc/nofpu/Dist [new file with mode: 0644]
sysdeps/powerpc/powerpc32/atomicity.h
sysdeps/powerpc/soft-fp/Dist
sysdeps/unix/sysv/linux/arm/ioperm.c
sysdeps/unix/sysv/linux/kernel-features.h
sysdeps/unix/sysv/linux/powerpc/Dist
sysdeps/unix/sysv/linux/powerpc/powerpc32/Dist
sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c
sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S
sysdeps/unix/sysv/linux/s390/s390-64/Dist
sysdeps/unix/sysv/linux/sparc/Dist
sysdeps/unix/sysv/linux/x86_64/Dist

index eb9116f56469405bd34cefc435a40b53e1348d46..835570821ab7e17fafb8417c6c9cfda269053dde 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,25 @@
+2002-07-24  Philip Blundell  <philb@gnu.org>
+
+       * sysdeps/unix/sysv/linux/arm/ioperm.c (init_iosys): Yield ENODEV
+       on unknown systems.
+
+2003-02-20  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
+
+       * sysdeps/powerpc/powerpc32/atomicity.h: Remove compiler workaround.
+       * sysdeps/unix/sysv/linux/kernel-features.h
+       (__ASSUME_NEW_PRCTL_SYSCALL): Defined for ppc32 too.
+       * sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c: Use prctl
+       if possible.
+       * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: Avoid short
+       interprocedure branches.
+       * sysdeps/powerpc/soft-fp/Dist (sim-full.c, fenv_const.c): Move to...
+       * sysdeps/powerpc/nofpu/Dist: ...here.
+       * sysdeps/unix/sysv/linux/powerpc/Dist (fe_nomask.c): Move to...
+       * sysdeps/unix/sysv/linux/powerpc/powerpc32/Dist: ...here.
+       * sysdeps/unix/sysv/linux/s390/s390-64/Dist (kernel_stat.h): Delete.
+       * sysdeps/unix/sysv/linux/sparc/Dist (bits/utmpx.h): Delete.
+       * sysdeps/unix/sysv/linux/x86_64/Dist (bits/utmpx.h): Delete.
+
 2003-02-18  Alan Modra  <amodra@bigpond.net.au>
 
        * sysdeps/powerpc/powerpc32/sysdep.h (HIDDEN_JUMPTARGET): Redefine.
index f05881dd82c5dab7d3020cd8cb457720fb478cfa..8a7ba0eaa35aa59a7896b38156c62eef3ca3d502 100644 (file)
@@ -1,3 +1,8 @@
+2003-02-20  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
+
+       * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: Avoid short
+       interprocedure branches.
+
 2003-02-19  Ulrich Drepper  <drepper@redhat.com>
 
        * specific.c (pthread_key_delete_helper): Don't use GETMEM, we
index 5054d5f98458d4f83d8d07425c0dde07a7457c71..ee6254a950600b431a2aa21a4ea7ad0ff4ff7584 100644 (file)
@@ -36,16 +36,15 @@ ENTRY (__vfork)
        mtlr    9
        lwz     10,__libc_pthread_functions@got(10)
        lwz     10,0(10)
-       cmpwi   10,0
-       bne-    HIDDEN_JUMPTARGET(__fork)
 # else
        .weak   pthread_create
-       lis     9,pthread_create@ha
-       la      9,pthread_create@l(9)
-       cmpwi   9,0
-       bne-    .Lhidden_fork
+       lis     10,pthread_create@ha
+       la      10,pthread_create@l(10)
 # endif
 
+       cmpwi   10,0
+       bne-    .Lhidden_fork
+
        DO_CALL (SYS_ify (vfork));
 
 # ifdef __ASSUME_VFORK_SYSCALL
@@ -54,28 +53,24 @@ ENTRY (__vfork)
        bnslr+
        /* Check if vfork syscall is known at all.  */
        cmpwi   r3,ENOSYS
-#  ifdef SHARED
-       bne     JUMPTARGET(__syscall_error)
-#  else
-       bne     .Lsyscall_error
-#  endif
+       bne-    .Lsyscall_error
 
 # endif
+
+.Lhidden_fork:
+       b       HIDDEN_JUMPTARGET(__fork)
+
 #endif
 
 #ifndef __ASSUME_VFORK_SYSCALL
        /* If we don't have vfork, fork is close enough.  */
 
        DO_CALL (SYS_ify (fork));
-       PSEUDO_RET
-#endif
+       bnslr+
 
-# ifndef SHARED
-.Lhidden_fork:
-       b       HIDDEN_JUMPTARGET(__fork)
 .Lsyscall_error:
        b       JUMPTARGET(__syscall_error)
-# endif
+#endif
 
 PSEUDO_END (__vfork)
 libc_hidden_def (__vfork)
diff --git a/sysdeps/powerpc/nofpu/Dist b/sysdeps/powerpc/nofpu/Dist
new file mode 100644 (file)
index 0000000..cd155fd
--- /dev/null
@@ -0,0 +1,2 @@
+sim-full.c
+fenv_const.c
index a3f672e5ecde69a3ef259a3d48ccc009a2544537..253bd32673064ce966d9651bc6043897cf48ec1e 100644 (file)
 
 #include <inttypes.h>
 
-#if BROKEN_PPC_ASM_CR0
-# define __ATOMICITY_INLINE /* nothing */
-#else
-# define __ATOMICITY_INLINE inline
-#endif
-
-static __ATOMICITY_INLINE int
+static inline int
 __attribute__ ((unused))
 exchange_and_add (volatile uint32_t *mem, int val)
 {
@@ -42,7 +36,7 @@ exchange_and_add (volatile uint32_t *mem, int val)
   return result;
 }
 
-static __ATOMICITY_INLINE void
+static inline void
 __attribute__ ((unused))
 atomic_add (volatile uint32_t *mem, int val)
 {
@@ -55,7 +49,7 @@ atomic_add (volatile uint32_t *mem, int val)
 " : "=&b"(tmp) : "r" (mem), "Ir"(val) : "cr0", "memory");
 }
 
-static __ATOMICITY_INLINE int
+static inline int
 __attribute__ ((unused))
 compare_and_swap (volatile long int *p, long int oldval, long int newval)
 {
@@ -72,7 +66,7 @@ compare_and_swap (volatile long int *p, long int oldval, long int newval)
   return result >> 5;
 }
 
-static __ATOMICITY_INLINE long int
+static inline long int
 __attribute__ ((unused))
 always_swap (volatile long int *p, long int newval)
 {
@@ -85,7 +79,7 @@ always_swap (volatile long int *p, long int newval)
   return result;
 }
 
-static __ATOMICITY_INLINE int
+static inline int
 __attribute__ ((unused))
 test_and_set (volatile long int *p, long int newval)
 {
index 9e4152a77ff4d9cd1d882cdc5bf9eaee09e873da..a91752412975645df457c7dc2b3f93e8181cfabf 100644 (file)
@@ -25,6 +25,4 @@ q_sub.c
 q_ulltoq.c
 q_util.c
 q_utoq.c
-sim-full.c
-fenv_const.c
 sfp-machine.h
index 40ac8e603823d9a8a8aff8077f48f92a04d35899..558b485b6158ece03a4afe680dd4e36b1e1a651e 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2003 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Phil Blundell, based on the Alpha version by
    David Mosberger.
@@ -166,7 +166,7 @@ init_iosys (void)
     }
 
   /* systype is not a known platform name... */
-  __set_errno (EINVAL);
+  __set_errno (ENODEV);
   return -1;
 }
 
@@ -194,8 +194,8 @@ _ioperm (unsigned long int from, unsigned long int num, int turn_on)
            return -1;
 
          io.base =
-           (unsigned long int) __mmap (0, MAX_PORT << io.shift, 
-                                       PROT_READ | PROT_WRITE, 
+           (unsigned long int) __mmap (0, MAX_PORT << io.shift,
+                                       PROT_READ | PROT_WRITE,
                                        MAP_SHARED, fd, io.io_base);
          close (fd);
          if ((long) io.base == -1)
index 45cd3e59c87560fbe05a2f340d26e51172bcad37..239d6379b4889c2c5ac3e216cbbe03d1db317aa8 100644 (file)
 # define __ASSUME_MMAP2_SYSCALL                1
 #endif
 
-/* Starting with 2.4.21 PowerPC64 implements the new prctl syscall.
+/* Starting with 2.4.21 PowerPC implements the new prctl syscall.
    This allows applications to get/set the Floating Point Exception Mode.  */
-#if __LINUX_KERNEL_VERSION >= (132096+21) && defined __powerpc64__
+#if __LINUX_KERNEL_VERSION >= (132096+21) && defined __powerpc__
 # define __ASSUME_NEW_PRCTL_SYSCALL            1
 #endif
 
index 507728abb1d726fea3abcb0c74be7916d4d751d0..f36d3685f6517e4db77d5cc875bf723e9240fec7 100644 (file)
@@ -1,6 +1,4 @@
-bits/utmpx.h
 dl-brk.S
-fe_nomask.c
 ipc_priv.h
 kernel_termios.h
 ldd-rewrite.sed
index 381f8780800cea1256faf0a4318c893305deaac9..297e031620ab76adfee012732dd2260200583908 100644 (file)
@@ -1,2 +1,3 @@
 clone.S
 kernel_stat.h
+fe_nomask.c
index e51714d312b96d2029865055681d2a6010233629..2c85a3a9e99a31806aa23a0ac263469dc406195e 100644 (file)
 #include <errno.h>
 #include <signal.h>
 #include <unistd.h>
+#include <sysdep.h>
+#include <sys/prctl.h>
+#include "kernel-features.h"
 
+#if __ASSUME_NEW_PRCTL_SYSCALL == 0
 /* This is rather fiddly under Linux.  We don't have direct access,
    and there is no system call, but we can change the bits 
    in a signal handler's context...  */
@@ -34,18 +38,31 @@ fe_nomask_handler (int signum, struct sigcontext *sc)
   sc->regs->msr |= 0x900ul;  /* FE0 | FE1 */
   sigaction (SIGUSR1, &oact, NULL);
 }
+#endif
 
 const fenv_t *
 __fe_nomask_env (void)
 {
-  struct sigaction act;
+#if __ASSUME_NEW_PRCTL_SYSCALL == 0
+# if defined PR_SET_FPEXC && defined PR_FP_EXC_PRECISE
+  int result = INLINE_SYSCALL (prctl, 2, PR_SET_FPEXC, PR_FP_EXC_PRECISE);
 
-  act.sa_handler = (sighandler_t) fe_nomask_handler;
-  sigemptyset (&act.sa_mask);
-  act.sa_flags = 0;
+  if (result == -1 && errno == EINVAL)
+# endif
+    {
+      struct sigaction act;
 
-  sigaction (SIGUSR1, &act, &oact);
-  raise (SIGUSR1);
+      act.sa_handler = (sighandler_t) fe_nomask_handler;
+      sigemptyset (&act.sa_mask);
+      act.sa_flags = 0;
+
+      sigaction (SIGUSR1, &act, &oact);
+      raise (SIGUSR1);
+    }
+#else
+  INTERNAL_SYSCALL_DECL (err);
+  INTERNAL_SYSCALL (prctl, err, 2, PR_SET_FPEXC, PR_FP_EXC_PRECISE);
+#endif
 
   return FE_ENABLED_ENV;
 }
index 9a0f53e99ef4c48f73bc3e87513396c5d7e514e6..5fb7868c3170436175e3d419ba0367de316a0337 100644 (file)
@@ -38,7 +38,7 @@ ENTRY (__vfork)
        bnslr+
        /* Check if vfork syscall is known at all.  */
        cmpwi   r3,ENOSYS
-       bne     JUMPTARGET(__syscall_error)
+       bne-    .Lsyscall_error
 
 # endif
 #endif
@@ -47,7 +47,10 @@ ENTRY (__vfork)
        /* If we don't have vfork, fork is close enough.  */
 
        DO_CALL (SYS_ify (fork))
-       PSEUDO_RET
+       bnslr+
+
+.Lsyscall_error:
+       b       JUMPTARGET(__syscall_error)
 #endif
 
 PSEUDO_END (__vfork)
index bc32c766e1b640aace0049a611fd7c902e7a225a..bfd4edc37237de41bd4ea91356882b13a75ab489 100644 (file)
@@ -1,3 +1,2 @@
 clone.S
-kernel_stat.h
 ucontext_i.h
index 0fea868016bcdc30e8ea3c0dc83c24ddf86cd363..174d0539097d59c6253aeacb51da2819f04362aa 100644 (file)
@@ -1,4 +1,3 @@
-bits/utmpx.h
 kernel_termios.h
 sys/trap.h
 ldd-rewrite.sed
index 0bae1286ebe295135e3c335d8e712b94b578cffe..57dd1b2221eb4171e58d345ebc2becac28e77b11 100644 (file)
@@ -1,4 +1,3 @@
-bits/utmpx.h
 clone.S
 ldd-rewrite.sed
 __start_context.S