This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.26.9000-697-g87bbc4c


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  87bbc4cf1e95400e17670a38684c041319c3187b (commit)
       via  e8681faa01e782800aa44acd0f13b191aca13c81 (commit)
      from  43e662837ca64a5141a5ebbb2d6f9d15513524d7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=87bbc4cf1e95400e17670a38684c041319c3187b

commit 87bbc4cf1e95400e17670a38684c041319c3187b
Author: Yury Norov <ynorov@caviumnetworks.com>
Date:   Tue Oct 31 15:31:40 2017 -0200

    Remove useless #ifdefs from Linux sig*.c  syscalls
    
    sigprocmask.c, sigtimedwait.c, sigwait.c and sigwaitinfo.c files from
    sysdeps/unix/sysv/linux include nptl-signals.h via nptl/pthreadP.h,
    and so SIGCANCEL and SIGSETXID become defined unconditionally. But
    later in the code, there are some checks weither symbols defined,
    which is useless. This patch removes useless checks.
    
    Checked on x86_64-linux-gnu.
    
    	* sysdeps/unix/sysv/linux/sigprocmask.c: Remove useless #ifdefs.
    	* sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise.
    	* sysdeps/unix/sysv/linux/sigwait.c: Likewise.
    	* sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise.
    
    Signed-off-by: Yury Norov <ynorov@caviumnetworks.com>
    Reviewed-by: Andreas Schwab <schwab@suse.de>
    Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>

diff --git a/ChangeLog b/ChangeLog
index 296ec24..77fe57c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2017-01-31  Yury Norov  <ynorov@caviumnetworks.com>
 
+	* sysdeps/unix/sysv/linux/sigprocmask.c: Remove useless #ifdefs.
+	* sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise.
+	* sysdeps/unix/sysv/linux/sigwait.c: Likewise.
+	* sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise.
+
 	* sysdeps/unix/sysv/linux/ia64/sigpending.c: Remove file.
 	* sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c: Likewise.
 	* sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c: Likewise.
diff --git a/sysdeps/unix/sysv/linux/sigprocmask.c b/sysdeps/unix/sysv/linux/sigprocmask.c
index d0b8e04..e776563 100644
--- a/sysdeps/unix/sysv/linux/sigprocmask.c
+++ b/sysdeps/unix/sysv/linux/sigprocmask.c
@@ -30,26 +30,19 @@
 int
 __sigprocmask (int how, const sigset_t *set, sigset_t *oset)
 {
-#ifdef SIGCANCEL
   sigset_t local_newmask;
 
   /* The only thing we have to make sure here is that SIGCANCEL and
      SIGSETXID are not blocked.  */
   if (set != NULL
       && (__builtin_expect (__sigismember (set, SIGCANCEL), 0)
-# ifdef SIGSETXID
-	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)
-# endif
-	  ))
+	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)))
     {
       local_newmask = *set;
       __sigdelset (&local_newmask, SIGCANCEL);
-# ifdef SIGSETXID
       __sigdelset (&local_newmask, SIGSETXID);
-# endif
       set = &local_newmask;
     }
-#endif
 
   return INLINE_SYSCALL (rt_sigprocmask, 4, how, set, oset, _NSIG / 8);
 }
diff --git a/sysdeps/unix/sysv/linux/sigtimedwait.c b/sysdeps/unix/sysv/linux/sigtimedwait.c
index ab1a84e..42afbce 100644
--- a/sysdeps/unix/sysv/linux/sigtimedwait.c
+++ b/sysdeps/unix/sysv/linux/sigtimedwait.c
@@ -29,25 +29,18 @@ int
 __sigtimedwait (const sigset_t *set, siginfo_t *info,
 		const struct timespec *timeout)
 {
-#ifdef SIGCANCEL
   sigset_t tmpset;
   if (set != NULL
       && (__builtin_expect (__sigismember (set, SIGCANCEL), 0)
-# ifdef SIGSETXID
-	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)
-# endif
-	  ))
+	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)))
     {
       /* Create a temporary mask without the bit for SIGCANCEL set.  */
       // We are not copying more than we have to.
       memcpy (&tmpset, set, _NSIG / 8);
       __sigdelset (&tmpset, SIGCANCEL);
-# ifdef SIGSETXID
       __sigdelset (&tmpset, SIGSETXID);
-# endif
       set = &tmpset;
     }
-#endif
 
     /* XXX The size argument hopefully will have to be changed to the
        real size of the user-level sigset_t.  */
diff --git a/sysdeps/unix/sysv/linux/sigwait.c b/sysdeps/unix/sysv/linux/sigwait.c
index 48bcd2f..395bd9f 100644
--- a/sysdeps/unix/sysv/linux/sigwait.c
+++ b/sysdeps/unix/sysv/linux/sigwait.c
@@ -33,25 +33,18 @@ do_sigwait (const sigset_t *set, int *sig)
 {
   int ret;
 
-#ifdef SIGCANCEL
   sigset_t tmpset;
   if (set != NULL
       && (__builtin_expect (__sigismember (set, SIGCANCEL), 0)
-# ifdef SIGSETXID
-	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)
-# endif
-	  ))
+	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)))
     {
       /* Create a temporary mask without the bit for SIGCANCEL set.  */
       // We are not copying more than we have to.
       memcpy (&tmpset, set, _NSIG / 8);
       __sigdelset (&tmpset, SIGCANCEL);
-# ifdef SIGSETXID
       __sigdelset (&tmpset, SIGSETXID);
-# endif
       set = &tmpset;
     }
-#endif
 
   /* XXX The size argument hopefully will have to be changed to the
      real size of the user-level sigset_t.  */
diff --git a/sysdeps/unix/sysv/linux/sigwaitinfo.c b/sysdeps/unix/sysv/linux/sigwaitinfo.c
index 5a044f0..0062d3e 100644
--- a/sysdeps/unix/sysv/linux/sigwaitinfo.c
+++ b/sysdeps/unix/sysv/linux/sigwaitinfo.c
@@ -31,25 +31,18 @@
 int
 __sigwaitinfo (const sigset_t *set, siginfo_t *info)
 {
-#ifdef SIGCANCEL
   sigset_t tmpset;
   if (set != NULL
       && (__builtin_expect (__sigismember (set, SIGCANCEL), 0)
-# ifdef SIGSETXID
-	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)
-# endif
-	  ))
+	  || __builtin_expect (__sigismember (set, SIGSETXID), 0)))
     {
       /* Create a temporary mask without the bit for SIGCANCEL set.  */
       // We are not copying more than we have to.
       memcpy (&tmpset, set, _NSIG / 8);
       __sigdelset (&tmpset, SIGCANCEL);
-# ifdef SIGSETXID
       __sigdelset (&tmpset, SIGSETXID);
-# endif
       set = &tmpset;
     }
-#endif
 
   /* XXX The size argument hopefully will have to be changed to the
      real size of the user-level sigset_t.  */

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=e8681faa01e782800aa44acd0f13b191aca13c81

commit e8681faa01e782800aa44acd0f13b191aca13c81
Author: Yury Norov <ynorov@caviumnetworks.com>
Date:   Tue Oct 31 15:28:42 2017 -0200

    Consolidate Linux sigpending() implementation
    
    ia64, s390-64, sparc64 and x86_64 host their own implementation of
    sigpending() in corresponding files, but they are identical to generic
    linux file despite few comments. This patch removes that files, so the
    implementation of sigpending() is taken from sysdeps/unix/sysv/linux
    for all ports.
    
    Build-tested on x86_64.
    
    	* sysdeps/unix/sysv/linux/ia64/sigpending.c: Remove file.
    	* sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c: Likewise.
    	* sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c: Likewise.
    	* sysdeps/unix/sysv/linux/x86_64/sigpending.c: Likewise.
    
    Signed-off-by: Yury Norov <ynorov@caviumnetworks.com>
    Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>

diff --git a/ChangeLog b/ChangeLog
index 9c03aba..296ec24 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2017-01-31  Yury Norov  <ynorov@caviumnetworks.com>
+
+	* sysdeps/unix/sysv/linux/ia64/sigpending.c: Remove file.
+	* sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c: Likewise.
+	* sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c: Likewise.
+	* sysdeps/unix/sysv/linux/x86_64/sigpending.c: Likewise.
+
 2017-10-31  Joseph Myers  <joseph@codesourcery.com>
 
 	* math/complex.h
diff --git a/sysdeps/unix/sysv/linux/ia64/sigpending.c b/sysdeps/unix/sysv/linux/ia64/sigpending.c
deleted file mode 100644
index b165323..0000000
--- a/sysdeps/unix/sysv/linux/ia64/sigpending.c
+++ /dev/null
@@ -1,36 +0,0 @@
-/* Copyright (C) 1997-2017 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/>.  */
-
-/* Linux/ia64 only has rt signals, thus we do not even want to try falling
-   back to the old style signals as the default Linux handler does. */
-
-#include <errno.h>
-#include <signal.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-/* Change the set of blocked signals to SET,
-   wait until a signal arrives, and restore the set of blocked signals.  */
-int
-sigpending (sigset_t *set)
-{
-  /* XXX The size argument hopefully will have to be changed to the
-     real size of the user-level sigset_t.  */
-  return INLINE_SYSCALL (rt_sigpending, 2, set, _NSIG / 8);
-}
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c b/sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c
deleted file mode 100644
index daf8cfd..0000000
--- a/sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c
+++ /dev/null
@@ -1,36 +0,0 @@
-/* Copyright (C) 2001-2017 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/>.  */
-
-/* 64 bit Linux for S/390 only has rt signals, thus we do not even want to try
-   falling back to the old style signals as the default Linux handler does. */
-
-#include <errno.h>
-#include <signal.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-/* Change the set of blocked signals to SET,
-   wait until a signal arrives, and restore the set of blocked signals.  */
-int
-sigpending (sigset_t *set)
-{
-  /* XXX The size argument hopefully will have to be changed to the
-     real size of the user-level sigset_t.  */
-  return INLINE_SYSCALL (rt_sigpending, 2, set, _NSIG / 8);
-}
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c b/sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c
deleted file mode 100644
index 7e82927..0000000
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c
+++ /dev/null
@@ -1,33 +0,0 @@
-/* Copyright (C) 1997-2017 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/>.  */
-
-#include <errno.h>
-#include <signal.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-/* Change the set of blocked signals to SET,
-   wait until a signal arrives, and restore the set of blocked signals.  */
-int
-sigpending (sigset_t *set)
-{
-  /* XXX The size argument hopefully will have to be changed to the
-     real size of the user-level sigset_t.  */
-  return INLINE_SYSCALL (rt_sigpending, 2, set, _NSIG / 8);
-}
diff --git a/sysdeps/unix/sysv/linux/x86_64/sigpending.c b/sysdeps/unix/sysv/linux/x86_64/sigpending.c
deleted file mode 100644
index 410217e..0000000
--- a/sysdeps/unix/sysv/linux/x86_64/sigpending.c
+++ /dev/null
@@ -1,36 +0,0 @@
-/* Copyright (C) 1997-2017 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/>.  */
-
-/* Linux/x86_64 only has rt signals, thus we do not even want to try falling
-   back to the old style signals as the default Linux handler does. */
-
-#include <errno.h>
-#include <signal.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-/* Change the set of blocked signals to SET,
-   wait until a signal arrives, and restore the set of blocked signals.  */
-int
-sigpending (sigset_t *set)
-{
-  /* XXX The size argument hopefully will have to be changed to the
-     real size of the user-level sigset_t.  */
-  return INLINE_SYSCALL (rt_sigpending, 2, set, _NSIG / 8);
-}

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                          |   12 ++++++
 sysdeps/unix/sysv/linux/ia64/sigpending.c          |   36 --------------------
 sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c  |   36 --------------------
 sysdeps/unix/sysv/linux/sigprocmask.c              |    9 +----
 sysdeps/unix/sysv/linux/sigtimedwait.c             |    9 +----
 sysdeps/unix/sysv/linux/sigwait.c                  |    9 +----
 sysdeps/unix/sysv/linux/sigwaitinfo.c              |    9 +----
 sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c |   33 ------------------
 sysdeps/unix/sysv/linux/x86_64/sigpending.c        |   36 --------------------
 9 files changed, 16 insertions(+), 173 deletions(-)
 delete mode 100644 sysdeps/unix/sysv/linux/ia64/sigpending.c
 delete mode 100644 sysdeps/unix/sysv/linux/s390/s390-64/sigpending.c
 delete mode 100644 sysdeps/unix/sysv/linux/sparc/sparc64/sigpending.c
 delete mode 100644 sysdeps/unix/sysv/linux/x86_64/sigpending.c


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]