From: Ulrich Drepper Date: Sun, 15 Dec 2002 21:23:04 +0000 (+0000) Subject: Update. X-Git-Tag: upstream/2.30~20487 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4cbc19503345d159ade2da6a3c31c202aababa5c;p=external%2Fglibc.git Update. * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect, readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev. * Makefile (libpthread-routines): Remove pt-creat, pt-poll, pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend, pt-sigwaitinfo, pt-waitid, and pt-writev. * pt-creat.c: Removed. * pt-poll.c: Removed. * pt-pselect.c: Removed. * pt-readv.c: Removed. * pt-select.c: Removed. * pt-sigpause.c: Removed. * pt-sigsuspend.c: Removed. * pt-sigwaitinfo.c: Removed. * pt-waitid.c: Removed. * pt-writev.c: Removed. --- diff --git a/nptl/ChangeLog b/nptl/ChangeLog index 1ed889e..8529a26 100644 --- a/nptl/ChangeLog +++ b/nptl/ChangeLog @@ -1,5 +1,21 @@ 2002-12-15 Ulrich Drepper + * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect, + readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev. + * Makefile (libpthread-routines): Remove pt-creat, pt-poll, + pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend, + pt-sigwaitinfo, pt-waitid, and pt-writev. + * pt-creat.c: Removed. + * pt-poll.c: Removed. + * pt-pselect.c: Removed. + * pt-readv.c: Removed. + * pt-select.c: Removed. + * pt-sigpause.c: Removed. + * pt-sigsuspend.c: Removed. + * pt-sigwaitinfo.c: Removed. + * pt-waitid.c: Removed. + * pt-writev.c: Removed. + * init.c (pthread_functions): New variable. (__pthread_initialize_minimal): Pass pointer to pthread_functions (or NULL) to __libc_pthread_init. diff --git a/nptl/Makefile b/nptl/Makefile index 71680d8..409b9de 100644 --- a/nptl/Makefile +++ b/nptl/Makefile @@ -99,10 +99,8 @@ libpthread-routines = init events \ pt-sendto pt-fsync pt-lseek pt-lseek64 pt-msync \ pt-nanosleep pt-open pt-open64 pt-pause pt-pread \ pt-pread64 pt-pwrite pt-pwrite64 pt-tcdrain pt-system \ - pt-wait pt-waitpid pt-readv pt-writev pt-creat \ - pt-msgrcv pt-msgsnd pt-poll pt-select pt-sigpause \ - pt-sigsuspend pt-sigwait pt-sigwaitinfo pt-waitid \ - pt-pselect pt-raise \ + pt-wait pt-waitpid pt-msgrcv pt-msgsnd pt-sigwait \ + pt-raise \ flockfile ftrylockfile funlockfile \ sigaction \ herrno res pt-allocrtsig \ diff --git a/nptl/pt-creat.c b/nptl/pt-creat.c deleted file mode 100644 index f1783f1..0000000 --- a/nptl/pt-creat.c +++ /dev/null @@ -1,42 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include -#include "pthreadP.h" - - -int -creat (const char *pathname, mode_t mode) -{ - int oldtype = CANCEL_ASYNC (); - -#if defined INLINE_SYSCALL && defined __NR_creat - int result = INLINE_SYSCALL (creat, 2, pathname, mode); -#else - int result = __libc_open (pathname, O_WRONLY|O_CREAT|O_TRUNC, mode); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-poll.c b/nptl/pt-poll.c deleted file mode 100644 index 53b432b..0000000 --- a/nptl/pt-poll.c +++ /dev/null @@ -1,41 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -poll (struct pollfd *fds, nfds_t nfds, int timeout) -{ - int oldtype =CANCEL_ASYNC (); - -#ifdef INLINE_SYSCALL - int result = INLINE_SYSCALL (poll, 3, fds, nfds, timeout); -#else - int result = __poll (fds, nfds, timeout); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-pselect.c b/nptl/pt-pselect.c deleted file mode 100644 index 542a103..0000000 --- a/nptl/pt-pselect.c +++ /dev/null @@ -1,39 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -pselect (int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, - const struct timespec *timeout, const sigset_t *sigmask) -{ - int oldtype = CANCEL_ASYNC (); - - int result = __pselect (nfds, readfds, writefds, exceptfds, timeout, - sigmask); - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-readv.c b/nptl/pt-readv.c deleted file mode 100644 index dc22df8..0000000 --- a/nptl/pt-readv.c +++ /dev/null @@ -1,68 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -/* Not all versions of the kernel support extremely large numbers - of records. */ -#ifndef UIO_FASTIOV -/* 1024 is what the kernels with NPTL support use. */ -# define UIO_FASTIOV 1024 -#endif - - -ssize_t -readv (fd, vector, count) - int fd; - const struct iovec *vector; - int count; -{ - int oldtype = CANCEL_ASYNC (); - - ssize_t result; -#ifdef INTERNAL_SYSCALL - result = INTERNAL_SYSCALL (readv, 3, fd, vector, count); - if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (result), 0)) - { - if (count <= UIO_FASTIOV) - { - __set_errno (INTERNAL_SYSCALL_ERRNO (result)); - result = -1; - } - else - result = __libc_readv (fd, vector, count); - } -#else -# if defined INLINE_SYSCALL - result = INLINE_SYSCALL (readv, 3, fd, vector, count); - if (result < 0 && errno == EINVAL - && __builtin_expect (count > UIO_FASTIOV, 0)) -# endif - result = __libc_readv (fd, vector, count); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-select.c b/nptl/pt-select.c deleted file mode 100644 index cb795c5..0000000 --- a/nptl/pt-select.c +++ /dev/null @@ -1,43 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -select (int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, - struct timeval *timeout) -{ - int oldtype = CANCEL_ASYNC (); - -#if defined INLINE_SYSCALL && defined __NR__newselect - int result = INLINE_SYSCALL (_newselect, 5, nfds, readfds, writefds, - exceptfds, timeout); -#else - int result = __select (nfds, readfds, writefds, exceptfds, timeout); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-sigpause.c b/nptl/pt-sigpause.c deleted file mode 100644 index e35026b..0000000 --- a/nptl/pt-sigpause.c +++ /dev/null @@ -1,51 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -#undef sigpause -int -sigpause (int mask) -{ - int oldtype = CANCEL_ASYNC (); - - int result = __sigpause (mask, 0); - - CANCEL_RESET (oldtype); - - return result; -} - - -int -__xpg_sigpause (int sig) -{ - int oldtype = CANCEL_ASYNC (); - - int result = __sigpause (sig, 1); - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-sigsuspend.c b/nptl/pt-sigsuspend.c deleted file mode 100644 index e531a5b..0000000 --- a/nptl/pt-sigsuspend.c +++ /dev/null @@ -1,41 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -sigsuspend (const sigset_t *set) -{ - int oldtype = CANCEL_ASYNC (); - -#ifdef INLINE_SYSCALL - int result = INLINE_SYSCALL (rt_sigsuspend, 2, set, _NSIG / 8); -#else - int result = __sigsuspend (set); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-sigwaitinfo.c b/nptl/pt-sigwaitinfo.c deleted file mode 100644 index 49f402d..0000000 --- a/nptl/pt-sigwaitinfo.c +++ /dev/null @@ -1,41 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -sigwaitinfo (const sigset_t *set, siginfo_t *info) -{ - int oldtype = CANCEL_ASYNC (); - -#ifdef INLINE_SYSCALL - int result = INLINE_SYSCALL (rt_sigtimedwait, 4, set, info, NULL, _NSIG / 8); -#else - int result = __sigwaitinfo (set, info); -#endif - - CANCEL_RESET (oldtype); - - return result; -} diff --git a/nptl/pt-waitid.c b/nptl/pt-waitid.c deleted file mode 100644 index ee8633c..0000000 --- a/nptl/pt-waitid.c +++ /dev/null @@ -1,38 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -int -waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options) -{ - int oldtype = CANCEL_ASYNC (); - - int result = __waitid (idtype, id, infop, options); - - CANCEL_RESET (oldtype); - - return result; -} -strong_alias (__wait, wait) diff --git a/nptl/pt-writev.c b/nptl/pt-writev.c deleted file mode 100644 index 99e876c..0000000 --- a/nptl/pt-writev.c +++ /dev/null @@ -1,67 +0,0 @@ -/* Copyright (C) 2002 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper , 2002. - - 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. */ - -#include -#include -#include -#include -#include "pthreadP.h" - - -/* Not all versions of the kernel support the large number of records. */ -#ifndef UIO_FASTIOV -/* 1024 is what the kernels with NPTL support use. */ -# define UIO_FASTIOV 1024 -#endif - - -ssize_t -writev (fd, vector, count) - int fd; - const struct iovec *vector; - int count; -{ - int oldtype = CANCEL_ASYNC (); - - ssize_t result; -#ifdef INTERNAL_SYSCALL - result = INTERNAL_SYSCALL (writev, 3, fd, vector, count); - if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (result), 0)) - { - if (count <= UIO_FASTIOV) - { - __set_errno (INTERNAL_SYSCALL_ERRNO (result)); - result = -1; - } - else - result = __libc_writev (fd, vector, count); - } -#else -# if defined INLINE_SYSCALL - result = INLINE_SYSCALL (writev, 3, fd, vector, count); - if (result < 0 && errno == EINVAL - && __builtin_expect (count > UIO_FASTIOV, 0)) -# endif - result = __libc_writev (fd, vector, count); -#endif - - CANCEL_RESET (oldtype); - - return result; -}