summary refs log tree commit diff
path: root/sysdeps/unix
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2003-02-17 19:15:42 +0000
committerUlrich Drepper <drepper@redhat.com>2003-02-17 19:15:42 +0000
commit81b5057288217437017b42780d7814eb7b0744d5 (patch)
tree5cc9c5a605362821c9032dbe622114c314b890b4 /sysdeps/unix
parent371a2972795a2eec8bd09fb8173b1ed800d68896 (diff)
downloadglibc-81b5057288217437017b42780d7814eb7b0744d5.tar.gz
glibc-81b5057288217437017b42780d7814eb7b0744d5.tar.xz
glibc-81b5057288217437017b42780d7814eb7b0744d5.zip
Update.
2003-02-17  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

	* sysdeps/unix/sysv/linux/powerpc/ftruncate64.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/truncate64.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/pread64.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/pread.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/pwrite64.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/pwrite.c: Delete.

	* sysdeps/unix/sysv/linux/powerpc/fe_nomask.c: Move file...
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c: ...here.
	* sysdeps/unix/sysv/linux/powerpc/glob64.c: Move file...
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/glob64.c: ...here.

	* sysdeps/unix/sysv/linux/tcgetattr.c: Use INLINE_SYSCALL.
	* sysdeps/unix/sysv/linux/tcsetattr.c: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/tcgetattr.c: Delete.
	* sysdeps/unix/sysv/linux/powerpc/tcsetattr.c: Delete.
Diffstat (limited to 'sysdeps/unix')
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/ftruncate64.c77
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c (renamed from sysdeps/unix/sysv/linux/powerpc/fe_nomask.c)2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/glob64.c (renamed from sysdeps/unix/sysv/linux/powerpc/glob64.c)0
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/pread.c60
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/pread64.c60
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/pwrite.c60
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/pwrite64.c61
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/tcgetattr.c19
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/tcsetattr.c19
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/truncate64.c77
-rw-r--r--sysdeps/unix/sysv/linux/tcgetattr.c2
-rw-r--r--sysdeps/unix/sysv/linux/tcsetattr.c4
12 files changed, 4 insertions, 437 deletions
diff --git a/sysdeps/unix/sysv/linux/powerpc/ftruncate64.c b/sysdeps/unix/sysv/linux/powerpc/ftruncate64.c
deleted file mode 100644
index 39f7d1fb59..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/ftruncate64.c
+++ /dev/null
@@ -1,77 +0,0 @@
-/* Copyright (C) 1997,1998,1999,2000,2001,2002 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, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#include <sys/types.h>
-#include <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-#include "kernel-features.h"
-
-#ifdef __NR_ftruncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls.  */
-extern int have_no_truncate64;
-#endif
-
-extern int __syscall_ftruncate64 (int fd, off64_t length);
-
-
-/* Truncate the file FD refers to to LENGTH bytes.  */
-int
-__ftruncate64 (fd, length)
-     int fd;
-     off64_t length;
-{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-  if (! have_no_truncate64)
-#endif
-    {
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      int saved_errno = errno;
-#endif
-      int result = __syscall_ftruncate64 (fd, length);
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      if (result != -1 || errno != ENOSYS)
-#endif
-	return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      __set_errno (saved_errno);
-      have_no_truncate64 = 1;
-#endif
-    }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-  if ((off_t) length != length)
-    {
-      __set_errno (EINVAL);
-      return -1;
-    }
-  return __ftruncate (fd, (off_t) length);
-#endif
-}
-weak_alias (__ftruncate64, ftruncate64)
-
-#else
-/* Use the generic implementation.  */
-# include <sysdeps/generic/ftruncate64.c>
-#endif
diff --git a/sysdeps/unix/sysv/linux/powerpc/fe_nomask.c b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c
index 27e6572d4d..e51714d312 100644
--- a/sysdeps/unix/sysv/linux/powerpc/fe_nomask.c
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fe_nomask.c
@@ -36,7 +36,7 @@ fe_nomask_handler (int signum, struct sigcontext *sc)
 }
 
 const fenv_t *
-__fe_nomask_env(void)
+__fe_nomask_env (void)
 {
   struct sigaction act;
 
diff --git a/sysdeps/unix/sysv/linux/powerpc/glob64.c b/sysdeps/unix/sysv/linux/powerpc/powerpc32/glob64.c
index 82a9a296a7..82a9a296a7 100644
--- a/sysdeps/unix/sysv/linux/powerpc/glob64.c
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/glob64.c
diff --git a/sysdeps/unix/sysv/linux/powerpc/pread.c b/sysdeps/unix/sysv/linux/powerpc/pread.c
deleted file mode 100644
index e5e3ed8bfe..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/pread.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/* Copyright (C) 1997, 1998, 1999, 2002 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   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 <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#ifdef __NR_pread
-
-extern ssize_t __syscall_pread (int fd, void *buf, size_t count,
-				off64_t offset);
-
-static ssize_t __emulate_pread (int fd, void *buf, size_t count,
-				off_t offset) internal_function;
-
-
-ssize_t
-__libc_pread (fd, buf, count, offset)
-     int fd;
-     void *buf;
-     size_t count;
-     off_t offset;
-{
-  ssize_t result;
-
-  /* First try the syscall.  */
-  result = __syscall_pread (fd, CHECK_N (buf, count), count, (off64_t) offset);
-  if (result == -1 && errno == ENOSYS)
-    /* No system call available.  Use the emulation.  */
-    result = __emulate_pread (fd, buf, count, offset);
-
-  return result;
-}
-
-strong_alias (__libc_pread, __pread)
-weak_alias (__libc_pread, pread)
-
-#define __libc_pread(fd, buf, count, offset) \
-     static internal_function __emulate_pread (fd, buf, count, offset)
-#endif
-#include <sysdeps/posix/pread.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/pread64.c b/sysdeps/unix/sysv/linux/powerpc/pread64.c
deleted file mode 100644
index d6acb72b9d..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/pread64.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/* Copyright (C) 1997,1998,1999,2000,2002 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   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 <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#ifdef __NR_pread
-
-extern ssize_t __syscall_pread (int fd, void *buf, size_t count,
-				off64_t offset);
-
-static ssize_t __emulate_pread64 (int fd, void *buf, size_t count,
-				  off64_t offset) internal_function;
-
-
-ssize_t
-__libc_pread64 (fd, buf, count, offset)
-     int fd;
-     void *buf;
-     size_t count;
-     off64_t offset;
-{
-  ssize_t result;
-
-  /* First try the syscall.  */
-  result = __syscall_pread (fd, CHECK_N (buf, count), count, offset);
-  if (result == -1 && errno == ENOSYS)
-    /* No system call available.  Use the emulation.  */
-    result = __emulate_pread64 (fd, buf, count, offset);
-
-  return result;
-}
-
-weak_alias (__libc_pread64, __pread64)
-weak_alias (__libc_pread64, pread64)
-
-#define __libc_pread64(fd, buf, count, offset) \
-     static internal_function __emulate_pread64 (fd, buf, count, offset)
-#endif
-#include <sysdeps/posix/pread64.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/pwrite.c b/sysdeps/unix/sysv/linux/powerpc/pwrite.c
deleted file mode 100644
index 7be7b44fef..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/pwrite.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/* Copyright (C) 1997, 1998, 1999, 2002 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   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 <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#ifdef __NR_pwrite
-
-extern ssize_t __syscall_pwrite (int fd, const void *buf, size_t count,
-				   off64_t offset);
-
-static ssize_t __emulate_pwrite (int fd, const void *buf, size_t count,
-				 off_t offset) internal_function;
-
-
-ssize_t
-__libc_pwrite (fd, buf, count, offset)
-     int fd;
-     const void *buf;
-     size_t count;
-     off_t offset;
-{
-  ssize_t result;
-
-  /* First try the syscall.  */
-  result = __syscall_pwrite (fd, CHECK_N (buf, count), count, (off64_t) offset);
-  if (result == -1 && errno == ENOSYS)
-    /* No system call available.  Use the emulation.  */
-    result = __emulate_pwrite (fd, buf, count, offset);
-
-  return result;
-}
-
-strong_alias (__libc_pwrite, __pwrite)
-weak_alias (__libc_pwrite, pwrite)
-
-#define __libc_pwrite(fd, buf, count, offset) \
-     static internal_function __emulate_pwrite (fd, buf, count, offset)
-#endif
-#include <sysdeps/posix/pwrite.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/pwrite64.c b/sysdeps/unix/sysv/linux/powerpc/pwrite64.c
deleted file mode 100644
index 24ad56d1c0..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/pwrite64.c
+++ /dev/null
@@ -1,61 +0,0 @@
-/* Copyright (C) 1997, 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
-
-   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 <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#ifdef __NR_pwrite
-
-extern ssize_t __syscall_pwrite (int fd, const void *buf, size_t count,
-				   off64_t offset);
-
-static ssize_t __emulate_pwrite64 (int fd, const void *buf, size_t count,
-				   off64_t offset) internal_function;
-
-
-ssize_t
-__libc_pwrite64 (fd, buf, count, offset)
-     int fd;
-     const void *buf;
-     size_t count;
-     off64_t offset;
-{
-  ssize_t result;
-
-  /* First try the syscall.  */
-  result = __syscall_pwrite (fd, CHECK_N (buf, count), count, offset);
-  if (result == -1 && errno == ENOSYS)
-    /* No system call available.  Use the emulation.  */
-    result = __emulate_pwrite64 (fd, buf, count, offset);
-
-  return result;
-}
-
-weak_alias (__libc_pwrite64, __pwrite64)
-libc_hidden_def (__pwrite64)
-weak_alias (__libc_pwrite64, pwrite64)
-
-#define __libc_pwrite64(fd, buf, count, offset) \
-     static internal_function __emulate_pwrite64 (fd, buf, count, offset)
-#endif
-#include <sysdeps/posix/pwrite64.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/tcgetattr.c b/sysdeps/unix/sysv/linux/powerpc/tcgetattr.c
deleted file mode 100644
index d9b0efe59d..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/tcgetattr.c
+++ /dev/null
@@ -1,19 +0,0 @@
-/* We must use the syscall directly since __ioctl does some extra work.  */
-
-#include <sys/ioctl.h>
-
-#include <sysdep.h>
-#include <bp-checks.h>
-
-struct __kernel_termios;
-
-static inline int
-tcgetattr_ioctl (int fd, unsigned long int request,
-		 struct __kernel_termios *termios_p)
-{
-  return INLINE_SYSCALL (ioctl, 3, fd, request, CHECK_1 (termios_p));
-}
-
-#define __ioctl tcgetattr_ioctl
-
-#include <sysdeps/unix/sysv/linux/tcgetattr.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/tcsetattr.c b/sysdeps/unix/sysv/linux/powerpc/tcsetattr.c
deleted file mode 100644
index c3d5b93334..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/tcsetattr.c
+++ /dev/null
@@ -1,19 +0,0 @@
-/* We must use the syscall directly since __ioctl does some extra work.  */
-
-#include <sys/ioctl.h>
-
-#include <sysdep.h>
-#include <bp-checks.h>
-
-struct __kernel_termios;
-
-static inline int
-tcsetattr_ioctl (int fd, unsigned long int request,
-		 const struct __kernel_termios *termios_p)
-{
-  return INLINE_SYSCALL (ioctl, 3, fd, request, CHECK_1 (termios_p));
-}
-
-#define __ioctl tcsetattr_ioctl
-
-#include <sysdeps/unix/sysv/linux/tcsetattr.c>
diff --git a/sysdeps/unix/sysv/linux/powerpc/truncate64.c b/sysdeps/unix/sysv/linux/powerpc/truncate64.c
deleted file mode 100644
index 3f5c581444..0000000000
--- a/sysdeps/unix/sysv/linux/powerpc/truncate64.c
+++ /dev/null
@@ -1,77 +0,0 @@
-/* Copyright (C) 1997, 1998, 1999, 2000, 2002 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, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#include <sys/types.h>
-#include <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#include "kernel-features.h"
-
-#ifdef __NR_truncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls.  */
-int have_no_truncate64;
-#endif
-
-extern int __syscall_truncate64 (const char *path, off64_t length);
-
-
-/* Truncate the file FD refers to to LENGTH bytes.  */
-int
-truncate64 (path, length)
-     const char *path;
-     off64_t length;
-{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-  if (! have_no_truncate64)
-#endif
-    {
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      int saved_errno = errno;
-#endif
-      int result = __syscall_truncate64 (CHECK_STRING (path), length);
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      if (result != -1 || errno != ENOSYS)
-#endif
-	return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-      __set_errno (saved_errno);
-      have_no_truncate64 = 1;
-#endif
-    }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-  if ((off_t) length != length)
-    {
-      __set_errno (EINVAL);
-      return -1;
-    }
-  return truncate (path, (off_t) length);
-#endif
-}
-
-#else
-/* Use the generic implementation.  */
-# include <sysdeps/generic/truncate64.c>
-#endif
diff --git a/sysdeps/unix/sysv/linux/tcgetattr.c b/sysdeps/unix/sysv/linux/tcgetattr.c
index 4761573cb6..dbbd4bb277 100644
--- a/sysdeps/unix/sysv/linux/tcgetattr.c
+++ b/sysdeps/unix/sysv/linux/tcgetattr.c
@@ -36,7 +36,7 @@ __tcgetattr (fd, termios_p)
   struct __kernel_termios k_termios;
   int retval;
 
-  retval = __ioctl (fd, TCGETS, &k_termios);
+  retval = INLINE_SYSCALL (ioctl, 3, fd, TCGETS, &k_termios);
 
   termios_p->c_iflag = k_termios.c_iflag;
   termios_p->c_oflag = k_termios.c_oflag;
diff --git a/sysdeps/unix/sysv/linux/tcsetattr.c b/sysdeps/unix/sysv/linux/tcsetattr.c
index 031cad7add..a961052202 100644
--- a/sysdeps/unix/sysv/linux/tcsetattr.c
+++ b/sysdeps/unix/sysv/linux/tcsetattr.c
@@ -87,14 +87,14 @@ tcsetattr (fd, optional_actions, termios_p)
   memcpy (&k_termios.c_cc[0], &termios_p->c_cc[0],
 	  __KERNEL_NCCS * sizeof (cc_t));
 
-  retval = __ioctl (fd, cmd, &k_termios);
+  retval = INLINE_SYSCALL (ioctl, 3, fd, cmd, &k_termios);
 
   if (retval == 0 && cmd == TCSETS)
     {
       /* The Linux kernel has a bug which silently ignore the invalid
 	 c_cflag on pty. We have to check it here. */
       int save = errno;
-      retval = __ioctl (fd, TCGETS, &k_termios);
+      retval = INLINE_SYSCALL (ioctl, 3, fd, TCGETS, &k_termios);
       if (retval)
 	{
 	  /* We cannot verify if the setting is ok. We don't return