]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
PowerPC: Fix __fe_mask_env export
authorAdhemerval Zanella <azanella@linux.vnet.ibm.com>
Thu, 23 Jan 2014 17:04:51 +0000 (11:04 -0600)
committerAdhemerval Zanella <azanella@linux.vnet.ibm.com>
Thu, 23 Jan 2014 17:05:51 +0000 (11:05 -0600)
This patch does not export __fe_mask_env anymore, only providing a
compatibility symbol. It fixes BZ#14143.

ChangeLog
NEWS
sysdeps/powerpc/bits/fenv.h
sysdeps/powerpc/fpu/fenv_libc.h
sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c
sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_mask.c
sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c

index 0992488a6a9ce5f7ba599f59af73162eadb9f213..d8393677a54055b48441e2cb8a5952ee27c42e60 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2014-01-23  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
+
+       [BZ #14143]
+       * sysdeps/powerpc/bits/fenv.h (__fe_nomask_env): Remove declaration.
+       (__fe_mask_env): Likewise.
+       * sysdeps/powerpc/fpu/fenv_libc.h (__fe_nomask_env): Remove
+       libm_hidden_proto and add function prototype.
+       (__fe_mask_env): Add function prototype.
+       * sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/fe_nomask.c
+       (__fe_nomask_env): Add compat symbol for GLIBC_2.1.
+       * sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_mask.c
+       (__fe_mask_env): Remove compiler warnings regarding ununsed variables.
+       * sysdeps/unix/sysv/linux/powerpc/powerpc64/fpu/fe_nomask.c
+       (__fe_nomask_env): Add compat symbol for GLIBC_2.3.
+
 2014-01-16  Adhemerval Zanella  <azanella@linux.vnet.ibm.com>
 
        [BZ#16430]
diff --git a/NEWS b/NEWS
index db471a4ee8152ff5c713605bb48ed64bb3bdb092..28b77555b28c7ba7d828bae56407994971fe3496 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -9,8 +9,8 @@ Version 2.18.1
 
 * The following bugs are resolved with this release:
 
-  14155, 14547, 14699, 15532, 15427, 15522, 15680, 15723, 15734, 15735,
-  15797, 15892, 15895, 15909, 15917, 15996, 16072, 16150, 16430.
+  14143, 14155, 14547, 14699, 15532, 15427, 15522, 15680, 15723, 15734,
+  15735, 15797, 15892, 15895, 15909, 15917, 15996, 16072, 16150, 16430.
 
 * Support for powerpc64le has been added.
 
index 122edd3dc3d3839f30b5bf676cf3ec434840a91e..86bf94e8fd400d967074830e589bf879c643f612 100644 (file)
@@ -153,15 +153,12 @@ extern const fenv_t __fe_enabled_env;
 extern const fenv_t __fe_nonieee_env;
 # define FE_NONIEEE_ENV        (&__fe_nonieee_env)
 
-__BEGIN_DECLS
-
 /* Floating-point environment with all exceptions enabled.  Note that
    just evaluating this value does not change the processor exception mode.
    Passing this mask to fesetenv will result in a prctl syscall to change
    the MSR FE0/FE1 bits to "Precise Mode".  On some processors this will
    result in slower floating point execution.  This will last until an
    fenv or exception mask is installed that disables all FP exceptions.  */
-extern const fenv_t *__fe_nomask_env (void);
 # define FE_NOMASK_ENV FE_ENABLED_ENV
 
 /* Floating-point environment with all exceptions disabled.  Note that
@@ -169,9 +166,6 @@ extern const fenv_t *__fe_nomask_env (void);
    Passing this mask to fesetenv will result in a prctl syscall to change
    the MSR FE0/FE1 bits to "Ignore Exceptions Mode".  On most processors
    this allows the fastest possible floating point execution.*/
-extern const fenv_t *__fe_mask_env (void);
 # define FE_MASK_ENV   FE_DFL_ENV
 
-__END_DECLS
-
 #endif
index baa2a7d39a458e8f1da6c007057588d1bbb052f3..cb15c1cecbd9ef82149e2d30a9563dfabd2d77b2 100644 (file)
@@ -23,7 +23,9 @@
 #include <ldsodefs.h>
 #include <sysdep.h>
 
-libm_hidden_proto (__fe_nomask_env)
+extern const fenv_t *__fe_nomask_env (void);
+
+extern const fenv_t *__fe_mask_env (void);
 
 /* The sticky bits in the FPSCR indicating exceptions have occurred.  */
 #define FPSCR_STICKY_BITS ((FE_ALL_EXCEPT | FE_ALL_INVALID) & ~FE_INVALID)
index 94db79f8e7e49e3f5efa1274ad95d869e04c32d7..dd3ec46b5614c55c9c734df8d75b0c25bad68d77 100644 (file)
@@ -23,6 +23,7 @@
 #include <sysdep.h>
 #include <sys/prctl.h>
 #include <kernel-features.h>
+#include <shlib-compat.h>
 
 const fenv_t *
 __fe_nomask_env (void)
@@ -32,4 +33,6 @@ __fe_nomask_env (void)
 
   return FE_ENABLED_ENV;
 }
-libm_hidden_def (__fe_nomask_env)
+#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_18)
+compat_symbol (libm, __fe_nomask_env, __fe_nomask_env, GLIBC_2_1);
+#endif
index 2ab585500510632673c84b88cc52ef4969a2bf0e..1d579bfccae6968b5adbfe05966ebb24ae48825f 100644 (file)
@@ -27,9 +27,8 @@ const fenv_t *
 __fe_mask_env (void)
 {
 #if defined PR_SET_FPEXC && defined PR_FP_EXC_DISABLED
-  int result;
   INTERNAL_SYSCALL_DECL (err);
-  result = INTERNAL_SYSCALL (prctl, err, 2, PR_SET_FPEXC, PR_FP_EXC_DISABLED);
+  INTERNAL_SYSCALL (prctl, err, 2, PR_SET_FPEXC, PR_FP_EXC_DISABLED);
 #else
   __set_errno (ENOSYS);
 #endif
index fd2ffb14f057e3b71d08b6a39c9cb38325c53869..5172f6587e3b7da9f8c472d09800261c762c5603 100644 (file)
 #include <sys/syscall.h>
 #include <sys/prctl.h>
 #include <kernel-features.h>
+#include <shlib-compat.h>
 
 const fenv_t *
 __fe_nomask_env (void)
 {
 #if defined PR_SET_FPEXC && defined PR_FP_EXC_PRECISE
-  int result;
   INTERNAL_SYSCALL_DECL (err);
-  result = INTERNAL_SYSCALL (prctl, err, 2, PR_SET_FPEXC, PR_FP_EXC_PRECISE);
+  INTERNAL_SYSCALL (prctl, err, 2, PR_SET_FPEXC, PR_FP_EXC_PRECISE);
 #else
   __set_errno (ENOSYS);
 #endif
   return FE_ENABLED_ENV;
 }
-libm_hidden_def (__fe_nomask_env)
+#if SHLIB_COMPAT (libm, GLIBC_2_3, GLIBC_2_18)
+compat_symbol (libm, __fe_nomask_env, __fe_nomask_env, GLIBC_2_3);
+#endif