summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Ludd <solar@gentoo.org>2008-06-07 23:28:06 +0000
committerNed Ludd <solar@gentoo.org>2008-06-07 23:28:06 +0000
commit44d1f70ed6e4cad82d038a4010e5181f58b8a7f3 (patch)
tree73d25b94de41f0036bb37787036834d8d756c098 /src/patchsets/uclibc
parentadding agaffney and wol31o2 as nominees (diff)
downloadgentoo-44d1f70ed6e4cad82d038a4010e5181f58b8a7f3.tar.gz
gentoo-44d1f70ed6e4cad82d038a4010e5181f58b8a7f3.tar.bz2
gentoo-44d1f70ed6e4cad82d038a4010e5181f58b8a7f3.zip
- update splice jazz from psm. Add a few ioperm fixes so arm-softfloat-linux-uclibc works again as a cross target when using gcc-3.x
Diffstat (limited to 'src/patchsets/uclibc')
-rw-r--r--src/patchsets/uclibc/0.9.28.3/60_all_uClibc-splice-tee.patch1548
-rw-r--r--src/patchsets/uclibc/0.9.28.3/62_all_uClibc-arm-ioperm.patch44
-rw-r--r--src/patchsets/uclibc/0.9.28.3/63_all_uClibc-arm-ioperm-outl.patch11
3 files changed, 1555 insertions, 48 deletions
diff --git a/src/patchsets/uclibc/0.9.28.3/60_all_uClibc-splice-tee.patch b/src/patchsets/uclibc/0.9.28.3/60_all_uClibc-splice-tee.patch
index 3b08a5f513..a16d14e21f 100644
--- a/src/patchsets/uclibc/0.9.28.3/60_all_uClibc-splice-tee.patch
+++ b/src/patchsets/uclibc/0.9.28.3/60_all_uClibc-splice-tee.patch
@@ -1,35 +1,474 @@
-diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/splice.c uClibc-0.9.28.3/libc/sysdeps/linux/common/splice.c
---- uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/splice.c 1970-01-01 00:00:00 +0000
-+++ uClibc-0.9.28.3/libc/sysdeps/linux/common/splice.c 2008-04-28 14:27:39 +0000
-@@ -0,0 +1,24 @@
+--- uClibc-0.9.28.3/libc/sysdeps/linux/sh/bits/fcntl.h.mps 2008-05-24 23:28:37.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/sh/bits/fcntl.h 2008-05-24 23:33:32.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007
++ 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
+@@ -21,8 +22,11 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -42,18 +46,18 @@
+ #define O_ASYNC 020000
+
+ #ifdef __USE_GNU
+-# define O_DIRECT 040000 /* Direct disk access. */
+-# define O_DIRECTORY 0200000 /* Must be a directory. */
+-# define O_NOFOLLOW 0400000 /* Do not follow links. */
+-# define O_STREAMING 04000000/* streaming access */
++# define O_DIRECT 040000 /* Direct disk access. */
++# define O_DIRECTORY 0200000 /* Must be a directory. */
++# define O_NOFOLLOW 0400000 /* Do not follow links. */
++# define O_NOATIME 01000000 /* Do not set atime. */
+ #endif
+
+ /* For now Linux has synchronisity options for data and read operations.
+ We define the symbols here but let them do the same as O_SYNC since
+- this is a superset. */
++ this is a superset. */
+ #if defined __USE_POSIX199309 || defined __USE_UNIX98
+ # define O_DSYNC O_SYNC /* Synchronize data. */
+-# define O_RSYNC O_SYNC /* Synchronize read operations. */
++# define O_RSYNC O_SYNC /* Synchronize read operations. */
+ #endif
+
+ #ifdef __USE_LARGEFILE64
+@@ -69,17 +73,17 @@
+ #ifndef __USE_FILE_OFFSET64
+ # define F_GETLK 5 /* Get record locking info. */
+ # define F_SETLK 6 /* Set record locking info (non-blocking). */
+-# define F_SETLKW 7 /* Set record locking info (blocking). */
++# define F_SETLKW 7 /* Set record locking info (blocking). */
+ #else
+-# define F_GETLK F_GETLK64 /* Get record locking info. */
++# define F_GETLK F_GETLK64 /* Get record locking info. */
+ # define F_SETLK F_SETLK64 /* Set record locking info (non-blocking).*/
+ # define F_SETLKW F_SETLKW64 /* Set record locking info (blocking). */
+ #endif
+ #define F_GETLK64 12 /* Get record locking info. */
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+-#define F_SETLKW64 14 /* Set record locking info (blocking). */
++#define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -89,20 +93,26 @@
+ # define F_GETSIG 11 /* Get number of signal to be sent. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++#ifdef __USE_GNU
++# define F_SETLEASE 1024 /* Set a lease. */
++# define F_GETLEASE 1025 /* Enquire what lease is active. */
++# define F_NOTIFY 1026 /* Request notfications on a directory. */
++#endif
++
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+ #define F_RDLCK 0 /* Read lock. */
+-#define F_WRLCK 1 /* Write lock. */
+-#define F_UNLCK 2 /* Remove lock. */
++#define F_WRLCK 1 /* Write lock. */
++#define F_UNLCK 2 /* Remove lock. */
+
+ /* For old implementation of bsd flock(). */
+ #define F_EXLCK 4 /* or 3 */
+ #define F_SHLCK 8 /* or 4 */
+
+ #ifdef __USE_BSD
+-/* Operations for bsd flock(), also used by the kernel implementation. */
++/* Operations for bsd flock(), also used by the kernel implementation. */
+ # define LOCK_SH 1 /* shared lock */
+ # define LOCK_EX 2 /* exclusive lock */
+ # define LOCK_NB 4 /* or'd with one of the above to prevent
+@@ -110,9 +120,27 @@
+ # define LOCK_UN 8 /* remove lock */
+ #endif
+
++#ifdef __USE_GNU
++# define LOCK_MAND 32 /* This is a mandatory flock: */
++# define LOCK_READ 64 /* ... which allows concurrent read operations. */
++# define LOCK_WRITE 128 /* ... which allows concurrent write operations. */
++# define LOCK_RW 192 /* ... Which allows concurrent read & write operations. */
++#endif
++
++#ifdef __USE_GNU
++/* Types of directory notifications that may be requested with F_NOTIFY. */
++# define DN_ACCESS 0x00000001 /* File accessed. */
++# define DN_MODIFY 0x00000002 /* File modified. */
++# define DN_CREATE 0x00000004 /* File created. */
++# define DN_DELETE 0x00000008 /* File removed. */
++# define DN_RENAME 0x00000010 /* File renamed. */
++# define DN_ATTRIB 0x00000020 /* File changed attibutes. */
++# define DN_MULTISHOT 0x80000000 /* Don't remove notifier. */
++#endif
++
+ struct flock
+ {
+- short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
++ short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
+ short int l_whence; /* Where `l_start' is relative to (like `lseek'). */
+ #ifndef __USE_FILE_OFFSET64
+ __off_t l_start; /* Offset where the lock begins. */
+@@ -127,7 +155,7 @@ struct flock
+ #ifdef __USE_LARGEFILE64
+ struct flock64
+ {
+- short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
++ short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
+ short int l_whence; /* Where `l_start' is relative to (like `lseek'). */
+ __off64_t l_start; /* Offset where the lock begins. */
+ __off64_t l_len; /* Size of the locked area; zero means until EOF. */
+@@ -149,8 +177,62 @@ struct flock64
+ #ifdef __USE_XOPEN2K
+ # define POSIX_FADV_NORMAL 0 /* No further special treatment. */
+ # define POSIX_FADV_RANDOM 1 /* Expect random page references. */
+-# define POSIX_FADV_SEQUENTIAL 2 /* Expect sequential page references. */
++# define POSIX_FADV_SEQUENTIAL 2 /* Expect sequential page references. */
+ # define POSIX_FADV_WILLNEED 3 /* Will need these pages. */
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/cris/bits/fcntl.h.mps 2008-05-24 23:27:34.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/cris/bits/fcntl.h 2008-05-24 23:31:05.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007
++ 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
+@@ -21,8 +22,11 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -45,7 +49,7 @@
+ # define O_DIRECT 040000 /* Direct disk access. */
+ # define O_DIRECTORY 0200000 /* Must be a directory. */
+ # define O_NOFOLLOW 0400000 /* Do not follow links. */
+-# define O_STREAMING 04000000/* streaming access */
++# define O_NOATIME 01000000 /* Do not set atime. */
+ #endif
+
+ /* For now Linux has synchronisity options for data and read operations.
+@@ -79,7 +83,7 @@
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -95,7 +99,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -178,3 +182,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/frv/bits/fcntl.h.mps 2008-05-24 23:27:51.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/frv/bits/fcntl.h 2008-05-24 23:27:57.000000000 +0200
+@@ -89,7 +89,7 @@
+ # define F_GETSIG 11 /* Get number of signal to be sent. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+--- uClibc-0.9.28.3/libc/sysdeps/linux/bfin/bits/fcntl.h.mps 2008-05-24 23:27:15.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/bfin/bits/fcntl.h 2008-05-24 23:30:52.000000000 +0200
+@@ -23,6 +23,9 @@
+
+
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -95,7 +98,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -178,3 +181,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/common/vmsplice.c.mps 2008-05-24 23:20:38.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/common/vmsplice.c 2008-05-24 23:21:17.000000000 +0200
+@@ -0,0 +1,25 @@
+/* vi: set sw=4 ts=4: */
+/*
-+ * splice() for uClibc
++ * vmsplice() for uClibc
+ *
+ * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
++#include <errno.h>
+#include <sys/syscall.h>
+#include <fcntl.h>
+
-+#ifdef __NR_splice
-+_syscall6(ssize_t, splice, int, __fdin, __off64_t *, __offin, int, __fdout,
-+ __off64_t *, __offout, size_t, __len, unsigned int, __flags);
++#ifdef __NR_vmsplice
++_syscall4(ssize_t, vmsplice, int, __fdout, const struct iovec *, __iov,
++ size_t, __count, unsigned int, __flags);
+#else
-+ssize_t splice(int __fdin, __off64_t *__offin, int __fdout,
-+ __off64_t *__offout, size_t __len, unsigned int __flags)
++ssize_t vmsplice(int __fdout, const struct iovec *__iov, size_t __count,
++ unsigned int __flags)
+{
+ __set_errno(ENOSYS);
+ return -1;
+}
+#endif
+
-diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/tee.c uClibc-0.9.28.3/libc/sysdeps/linux/common/tee.c
---- uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/tee.c 1970-01-01 00:00:00 +0000
-+++ uClibc-0.9.28.3/libc/sysdeps/linux/common/tee.c 2008-04-28 14:27:39 +0000
-@@ -0,0 +1,23 @@
+--- uClibc-0.9.28.3/libc/sysdeps/linux/common/bits/uio.h.mps 2008-05-24 23:49:36.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/common/bits/uio.h 2008-05-24 23:49:39.000000000 +0200
+@@ -1,4 +1,4 @@
+-/* Copyright (C) 1996, 1997 Free Software Foundation, Inc.
++/* Copyright (C) 1996, 1997, 2006 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
+@@ -16,10 +16,12 @@
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+-#ifndef _SYS_UIO_H
++#if !defined _SYS_UIO_H && !defined _FCNTL_H
+ # error "Never include <bits/uio.h> directly; use <sys/uio.h> instead."
+ #endif
+
++#ifndef _BITS_UIO_H
++#define _BITS_UIO_H 1
+
+ #include <sys/types.h>
+
+@@ -31,7 +33,7 @@
+ /* Size of object which can be written atomically.
+
+ This macro has different values in different kernel versions. The
+- latest versions of ther kernel use 1024 and this is good choice. Since
++ latest versions of the kernel use 1024 and this is good choice. Since
+ the C library implementation of readv/writev is able to emulate the
+ functionality even if the currently running kernel does not support
+ this large value the readv/writev call will not fail because of this. */
+@@ -44,3 +46,5 @@ struct iovec
+ void *iov_base; /* Pointer to data. */
+ size_t iov_len; /* Length of data. */
+ };
++
++#endif
+--- uClibc-0.9.28.3/libc/sysdeps/linux/common/tee.c.mps 2008-05-24 23:20:38.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/common/tee.c 2008-05-24 23:21:08.000000000 +0200
+@@ -0,0 +1,24 @@
+/* vi: set sw=4 ts=4: */
+/*
+ * tee() for uClibc
@@ -39,6 +478,7 @@ diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/tee.c uClibc-0.9.28.3/l
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
++#include <errno.h>
+#include <sys/syscall.h>
+#include <fcntl.h>
+
@@ -53,57 +493,252 @@ diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/tee.c uClibc-0.9.28.3/l
+}
+#endif
+
-diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/vmsplice.c uClibc-0.9.28.3/libc/sysdeps/linux/common/vmsplice.c
---- uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/vmsplice.c 1970-01-01 00:00:00 +0000
-+++ uClibc-0.9.28.3/libc/sysdeps/linux/common/vmsplice.c 2008-04-28 14:27:39 +0000
-@@ -0,0 +1,24 @@
+--- uClibc-0.9.28.3/libc/sysdeps/linux/common/splice.c.mps 2008-05-24 23:20:38.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/common/splice.c 2008-05-24 23:20:57.000000000 +0200
+@@ -0,0 +1,25 @@
+/* vi: set sw=4 ts=4: */
+/*
-+ * vmsplice() for uClibc
++ * splice() for uClibc
+ *
+ * Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
+ *
+ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
+ */
+
++#include <errno.h>
+#include <sys/syscall.h>
+#include <fcntl.h>
+
-+#ifdef __NR_vmsplice
-+_syscall4(ssize_t, vmsplice, int, __fdout, const struct iovec *, __iov,
-+ size_t, __count, unsigned int, __flags);
++#ifdef __NR_splice
++_syscall6(ssize_t, splice, int, __fdin, __off64_t *, __offin, int, __fdout,
++ __off64_t *, __offout, size_t, __len, unsigned int, __flags);
+#else
-+ssize_t vmsplice(int __fdout, const struct iovec *__iov, size_t __count,
-+ unsigned int __flags)
++ssize_t splice(int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len, unsigned int __flags)
+{
+ __set_errno(ENOSYS);
+ return -1;
+}
+#endif
+
---- uClibc-0.9.28.3.orig/libc/sysdeps/linux/i386/bits/fcntl.h 2008-04-28 14:27:25 +0000
-+++ uClibc-0.9.28.3/libc/sysdeps/linux/i386/bits/fcntl.h 2008-04-28 14:35:36 +0000
-@@ -1,5 +1,5 @@
+--- uClibc-0.9.28.3/libc/sysdeps/linux/arm/bits/fcntl.h.mps 2008-05-24 23:26:55.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/arm/bits/fcntl.h 2008-05-24 23:30:35.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 1995-1998, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995-1998, 2000, 2004, 2006, 2007
++ 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
+@@ -21,35 +22,34 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+-#define O_ACCMODE 0003
+-#define O_RDONLY 00
+-#define O_WRONLY 01
+-#define O_RDWR 02
+-#define O_CREAT 0100 /* not fcntl */
+-#define O_EXCL 0200 /* not fcntl */
+-#define O_NOCTTY 0400 /* not fcntl */
+-#define O_TRUNC 01000 /* not fcntl */
+-#define O_APPEND 02000
+-#define O_NONBLOCK 04000
++#define O_ACCMODE 0003
++#define O_RDONLY 00
++#define O_WRONLY 01
++#define O_RDWR 02
++#define O_CREAT 0100 /* not fcntl */
++#define O_EXCL 0200 /* not fcntl */
++#define O_NOCTTY 0400 /* not fcntl */
++#define O_TRUNC 01000 /* not fcntl */
++#define O_APPEND 02000
++#define O_NONBLOCK 04000
+ #define O_NDELAY O_NONBLOCK
+-#define O_SYNC 010000
+-#define O_FSYNC O_SYNC
+-#define O_ASYNC 020000
++#define O_SYNC 010000
++#define O_FSYNC O_SYNC
++#define O_ASYNC 020000
+
+ #ifdef __USE_GNU
+-# define O_DIRECTORY 040000 /* Must be a directory. */
++# define O_DIRECTORY 040000 /* Must be a directory. */
+ # define O_NOFOLLOW 0100000 /* Do not follow links. */
+ # define O_DIRECT 0200000 /* Direct disk access. */
+-# define O_STREAMING 04000000/* streaming access */
+-#endif
+-
+-#ifdef __USE_LARGEFILE64
+-# define O_LARGEFILE 0400000
++# define O_NOATIME 01000000 /* Do not set atime. */
+ #endif
+
+ /* For now Linux has synchronisity options for data and read operations.
+@@ -60,13 +60,16 @@
+ # define O_RSYNC O_SYNC /* Synchronize read operations. */
+ #endif
+
++#ifdef __USE_LARGEFILE64
++# define O_LARGEFILE 0400000
++#endif
++
+ /* Values for the second argument to `fcntl'. */
+ #define F_DUPFD 0 /* Duplicate file descriptor. */
+ #define F_GETFD 1 /* Get file descriptor flags. */
+ #define F_SETFD 2 /* Set file descriptor flags. */
+ #define F_GETFL 3 /* Get file status flags. */
+ #define F_SETFL 4 /* Set file status flags. */
+-
+ #ifndef __USE_FILE_OFFSET64
+ # define F_GETLK 5 /* Get record locking info. */
+ # define F_SETLK 6 /* Set record locking info (non-blocking). */
+@@ -80,7 +83,7 @@
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -96,7 +99,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -104,12 +107,12 @@
+ #define F_WRLCK 1 /* Write lock. */
+ #define F_UNLCK 2 /* Remove lock. */
+
+-/* for old implementation of bsd flock () */
++/* For old implementation of bsd flock(). */
+ #define F_EXLCK 4 /* or 3 */
+ #define F_SHLCK 8 /* or 4 */
+
+ #ifdef __USE_BSD
+-/* Operations for bsd flock(), also used by the kernel implementation */
++/* Operations for bsd flock(), also used by the kernel implementation. */
+ # define LOCK_SH 1 /* shared lock */
+ # define LOCK_EX 2 /* exclusive lock */
+ # define LOCK_NB 4 /* or'd with one of the above to prevent
+@@ -179,3 +182,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/i386/bits/fcntl.h.mps 2008-05-24 23:20:33.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/i386/bits/fcntl.h 2008-05-24 23:25:42.000000000 +0200
+@@ -1,5 +1,6 @@
/* O_*, F_*, FD_* bit values for Linux.
- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
-+ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2008 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007
++ 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
-@@ -46,6 +46,7 @@
+@@ -21,8 +22,11 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -45,7 +49,7 @@
+ # define O_DIRECT 040000 /* Direct disk access. */
# define O_DIRECTORY 0200000 /* Must be a directory. */
# define O_NOFOLLOW 0400000 /* Do not follow links. */
- # define O_STREAMING 04000000/* streaming access */
-+# define O_CLOEXEC 02000000 /* Set close_on_exec. */
+-# define O_STREAMING 04000000/* streaming access */
++# define O_NOATIME 01000000 /* Do not set atime. */
#endif
/* For now Linux has synchronisity options for data and read operations.
-@@ -93,9 +94,11 @@
- # define F_SETLEASE 1024 /* Set a lease. */
- # define F_GETLEASE 1025 /* Enquire what lease is active. */
+@@ -79,7 +83,7 @@
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -95,7 +99,7 @@
# define F_NOTIFY 1026 /* Request notfications on a directory. */
-+# define F_DUPFD_CLOEXEC 1030 /* Duplicate file descriptor with
-+ close-on-exit set. */
#endif
-/* For F_[GET|SET]FL. */
@@ -111,29 +746,846 @@ diff -ruN uClibc-0.9.28.3.orig/libc/sysdeps/linux/common/vmsplice.c uClibc-0.9.2
#define FD_CLOEXEC 1 /* actually anything with low bit set goes */
/* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
-@@ -178,3 +181,25 @@
+@@ -178,3 +182,58 @@ struct flock64
# define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
# define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
#endif
+
++
+#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
+
+/* Flags for SPLICE and VMSPLICE. */
-+# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
-+# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
-+ (but we may still block on the fd
-+ we splice from/to). */
-+# define SPLICE_F_MORE 4 /* Expect more data. */
-+# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
+
-+extern size_t vmsplice (int __fdout, const struct iovec *__iov,
-+ size_t __count, unsigned int __flags);
+
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
+extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
-+ __off64_t *__offout, size_t __len,
-+ unsigned int __flags);
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
+
++/* In-kernel implementation of tee for pipe buffers. */
+extern ssize_t tee (int __fdin, int __fdout, size_t __len,
-+ unsigned int __flags);
++ unsigned int __flags);
+
+#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/x86_64/bits/fcntl.h.mps 2008-05-24 23:29:18.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/x86_64/bits/fcntl.h 2008-05-24 23:29:52.000000000 +0200
+@@ -1,5 +1,5 @@
+ /* O_*, F_*, FD_* bit values for Linux/x86-64.
+- Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc.
++ Copyright (C) 2001, 2002, 2004, 2006, 2007 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
+@@ -21,9 +21,12 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
+ #include <bits/wordsize.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -110,7 +113,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -193,3 +196,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/m68k/bits/fcntl.h.mps 2008-05-24 23:28:07.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/m68k/bits/fcntl.h 2008-05-24 23:31:45.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2004, 2006, 2007
++ 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
+@@ -21,8 +22,11 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -45,7 +49,7 @@
+ # define O_DIRECTORY 040000 /* Must be a directory. */
+ # define O_NOFOLLOW 0100000 /* Do not follow links. */
+ # define O_DIRECT 0200000 /* Direct disk access. */
+-# define O_STREAMING 04000000/* streaming access */
++# define O_NOATIME 01000000 /* Do not set atime. */
+ #endif
+
+ /* For now Linux has synchronisity options for data and read operations.
+@@ -79,7 +83,7 @@
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -95,7 +99,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -178,3 +182,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/powerpc/bits/fcntl.h.mps 2008-05-24 23:32:54.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/powerpc/bits/fcntl.h 2008-05-24 23:33:16.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux/PowerPC.
+- Copyright (C) 1995,1996,1997,1998,2000,2003 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2003, 2004, 2006, 2007
++ 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
+@@ -21,8 +22,11 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
++
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -45,7 +49,7 @@
+ # define O_DIRECT 0400000 /* Direct disk access. */
+ # define O_DIRECTORY 040000 /* Must be a directory. */
+ # define O_NOFOLLOW 0100000 /* Do not follow links. */
+-# define O_STREAMING 04000000 /* streaming access */
++# define O_NOATIME 01000000 /* Do not set atime. */
+ #endif
+
+ #ifdef __USE_LARGEFILE64
+@@ -79,7 +83,7 @@
+ #define F_SETLK64 13 /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 14 /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 8 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 9 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -95,7 +99,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -178,3 +182,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/sh64/bits/fcntl.h.mps 2008-05-24 23:28:48.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/sh64/bits/fcntl.h 2008-05-24 23:28:52.000000000 +0200
+@@ -89,7 +89,7 @@
+ # define F_GETSIG 11 /* Get number of signal to be sent. */
+ #endif
+
+-/* For F_[GET|SET]FL. */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+--- uClibc-0.9.28.3/libc/sysdeps/linux/alpha/bits/fcntl.h.mps 2008-05-24 23:26:36.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/alpha/bits/fcntl.h 2008-05-24 23:30:17.000000000 +0200
+@@ -1,5 +1,5 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 1995-1999, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995-2000,2004,2005,2006,2007 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
+@@ -21,8 +21,10 @@
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
+-
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
+
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+@@ -44,10 +46,10 @@
+ #define O_ASYNC 020000 /* fcntl, for BSD compatibility */
+
+ #ifdef __USE_GNU
+-# define O_DIRECT 040000 /* Direct disk access. */
+ # define O_DIRECTORY 0100000 /* Must be a directory. */
+ # define O_NOFOLLOW 0200000 /* Do not follow links. */
+-# define O_STREAMING 04000000/* streaming access */
++# define O_DIRECT 02000000 /* Direct disk access. */
++# define O_NOATIME 04000000 /* Do not set atime. */
+ #endif
+
+ #ifdef __USE_LARGEFILE64
+@@ -76,7 +78,7 @@
+ #define F_SETLK64 F_SETLK /* Set record locking info (non-blocking). */
+ #define F_SETLKW64 F_SETLKW /* Set record locking info (blocking). */
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 5 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 6 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -92,7 +94,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* for F_[GET|SET]FL */
++/* for F_[GET|SET]FD */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf() */
+@@ -169,6 +171,61 @@ struct flock64
+ # define POSIX_FADV_RANDOM 1 /* Expect random page references. */
+ # define POSIX_FADV_SEQUENTIAL 2 /* Expect sequential page references. */
+ # define POSIX_FADV_WILLNEED 3 /* Will need these pages. */
+-# define POSIX_FADV_DONTNEED 6 /* Don't need these pages. */
+-# define POSIX_FADV_NOREUSE 7 /* Data will be accessed once. */
++# define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
++# define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/mips/bits/fcntl.h.mps 2008-05-24 23:28:26.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/mips/bits/fcntl.h 2008-05-24 23:32:33.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux.
+- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2002, 2003, 2004, 2006, 2007
++ 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
+@@ -17,50 +18,57 @@
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+-#ifndef _FCNTL_H
++#ifndef _FCNTL_H
+ # error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
+ #endif
+
++#include <sgidefs.h>
+ #include <sys/types.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
+
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+-#define O_ACCMODE 0x0003
+-#define O_RDONLY 0x0000
+-#define O_WRONLY 0x0001
+-#define O_RDWR 0x0002
+-#define O_APPEND 0x0008
+-#define O_SYNC 0x0010
+-#define O_NONBLOCK 0x0080
+-#define O_CREAT 0x0100 /* not fcntl */
+-#define O_TRUNC 0x0200 /* not fcntl */
+-#define O_EXCL 0x0400 /* not fcntl */
+-#define O_NOCTTY 0x0800 /* not fcntl */
+-#define O_FSYNC O_SYNC
+-#define O_ASYNC 0x1000
+-
+-#ifdef __USE_LARGEFILE64
+-# define O_LARGEFILE 0x2000 /* Allow large file opens. */
+-#endif
++#define O_ACCMODE 0003
++#define O_RDONLY 00
++#define O_WRONLY 01
++#define O_RDWR 02
++#define O_APPEND 0x0008
++#define O_SYNC 0x0010
++#define O_NONBLOCK 0x0080
++#define O_NDELAY O_NONBLOCK
++#define O_CREAT 0x0100 /* not fcntl */
++#define O_TRUNC 0x0200 /* not fcntl */
++#define O_EXCL 0x0400 /* not fcntl */
++#define O_NOCTTY 0x0800 /* not fcntl */
++#define O_FSYNC O_SYNC
++#define O_ASYNC 0x1000
+
+ #ifdef __USE_GNU
+ # define O_NOFOLLOW 0x20000 /* Do not follow links. */
+ # define O_DIRECT 0x8000 /* Direct disk access hint. */
+ # define O_DIRECTORY 0x10000 /* Must be a directory. */
+-# define O_STREAMING 0x4000000/* streaming access */
++# define O_NOATIME 0x40000 /* Do not set atime. */
+ #endif
+
+-#define O_NDELAY O_NONBLOCK
+-
+-/* For now Linux has no synchronisity options for data and read
+- operations. We define the symbols here but let them do the same as
+- O_SYNC since this is a superset. */
++/* For now Linux has no synchronisity options for data and read operations.
++ We define the symbols here but let them do the same as O_SYNC since
++ this is a superset. */
+ #if defined __USE_POSIX199309 || defined __USE_UNIX98
+ # define O_DSYNC O_SYNC /* Synchronize data. */
+ # define O_RSYNC O_SYNC /* Synchronize read operations. */
+ #endif
+
++#ifdef __USE_LARGEFILE64
++# if __WORDSIZE == 64
++# define O_LARGEFILE 0
++# else
++# define O_LARGEFILE 0x2000 /* Allow large file opens. */
++# endif
++#endif
++
+ /* Values for the second argument to `fcntl'. */
+ #define F_DUPFD 0 /* Duplicate file descriptor. */
+ #define F_GETFD 1 /* Get file descriptor flags. */
+@@ -77,11 +85,17 @@
+ # define F_SETLKW F_SETLKW64 /* Set record locking info (blocking). */
+ #endif
+
+-#define F_GETLK64 33 /* Get record locking info. */
+-#define F_SETLK64 34 /* Set record locking info (non-blocking). */
+-#define F_SETLKW64 35 /* Set record locking info (blocking). */
++#if __WORDSIZE == 64
++# define F_GETLK64 14 /* Get record locking info. */
++# define F_SETLK64 6 /* Set record locking info (non-blocking). */
++# define F_SETLKW64 7 /* Set record locking info (blocking). */
++#else
++# define F_GETLK64 33 /* Get record locking info. */
++# define F_SETLK64 34 /* Set record locking info (non-blocking). */
++# define F_SETLKW64 35 /* Set record locking info (blocking). */
++#endif
+
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_SETOWN 24 /* Get owner of socket (receiver of SIGIO). */
+ # define F_GETOWN 23 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -97,7 +111,7 @@
+ # define F_NOTIFY 1026 /* Request notfications on a directory. */
+ #endif
+
+-/* for F_[GET|SET]FL */
++/* For F_[GET|SET]FD. */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -105,12 +119,12 @@
+ #define F_WRLCK 1 /* Write lock. */
+ #define F_UNLCK 2 /* Remove lock. */
+
+-/* for old implementation of bsd flock () */
++/* For old implementation of bsd flock(). */
+ #define F_EXLCK 4 /* or 3 */
+ #define F_SHLCK 8 /* or 4 */
+
+ #ifdef __USE_BSD
+-/* Operations for bsd flock(), also used by the kernel implementation */
++/* Operations for bsd flock(), also used by the kernel implementation. */
+ # define LOCK_SH 1 /* shared lock */
+ # define LOCK_EX 2 /* exclusive lock */
+ # define LOCK_NB 4 /* or'd with one of the above to prevent
+@@ -136,23 +150,30 @@
+ # define DN_MULTISHOT 0x80000000 /* Don't remove notifier. */
+ #endif
+
+-typedef struct flock
++struct flock
+ {
+ short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
+ short int l_whence; /* Where `l_start' is relative to (like `lseek'). */
+ #ifndef __USE_FILE_OFFSET64
+ __off_t l_start; /* Offset where the lock begins. */
+ __off_t l_len; /* Size of the locked area; zero means until EOF. */
+- long int l_sysid; /* XXX */
++#if _MIPS_SIM != _ABI64
++ /* The 64-bit flock structure, used by the n64 ABI, and for 64-bit
++ fcntls in o32 and n32, never has this field. */
++ long int l_sysid;
++#endif
+ #else
+ __off64_t l_start; /* Offset where the lock begins. */
+ __off64_t l_len; /* Size of the locked area; zero means until EOF. */
+ #endif
+ __pid_t l_pid; /* Process holding the lock. */
+-#ifndef __USE_FILE_OFFSET64
+- long int pad[4]; /* XXX */
++#if ! defined __USE_FILE_OFFSET64 && _MIPS_SIM != _ABI64
++ /* The 64-bit flock structure, used by the n64 ABI, and for 64-bit
++ flock in o32 and n32, never has this field. */
++ long int pad[4];
+ #endif
+-} flock_t;
++ };
++typedef struct flock flock_t;
+
+ #ifdef __USE_LARGEFILE64
+ struct flock64
+@@ -165,7 +186,6 @@ struct flock64
+ };
+ #endif
+
+-
+ /* Define some more compatibility macros to be backward compatible with
+ BSD systems which did not managed to hide these kernel macros. */
+ #ifdef __USE_BSD
+@@ -185,3 +205,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
+--- uClibc-0.9.28.3/libc/sysdeps/linux/sparc/bits/fcntl.h.mps 2008-05-24 23:29:00.000000000 +0200
++++ uClibc-0.9.28.3/libc/sysdeps/linux/sparc/bits/fcntl.h 2008-05-24 23:33:53.000000000 +0200
+@@ -1,5 +1,6 @@
+ /* O_*, F_*, FD_* bit values for Linux/SPARC.
+- Copyright (C) 1995, 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
++ Copyright (C) 1995, 1996, 1997, 1998, 2000, 2003, 2004, 2006, 2007
++ 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
+@@ -23,6 +24,9 @@
+
+ #include <sys/types.h>
+ #include <bits/wordsize.h>
++#ifdef __USE_GNU
++# include <bits/uio.h>
++#endif
+
+ /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
+ located on an ext2 file system */
+@@ -43,7 +47,8 @@
+ #ifdef __USE_GNU
+ # define O_DIRECTORY 0x10000 /* must be a directory */
+ # define O_NOFOLLOW 0x20000 /* don't follow links */
+-# define O_STREAMING 0x4000000/* streaming access */
++# define O_DIRECT 0x100000 /* direct disk access hint */
++# define O_NOATIME 0x200000 /* Do not set atime. */
+ #endif
+
+ #ifdef __USE_LARGEFILE64
+@@ -76,7 +81,7 @@
+ #define F_SETFD 2 /* Set file descriptor flags. */
+ #define F_GETFL 3 /* Get file status flags. */
+ #define F_SETFL 4 /* Set file status flags. */
+-#if defined __USE_BSD || defined __USE_XOPEN2K
++#if defined __USE_BSD || defined __USE_UNIX98
+ # define F_GETOWN 5 /* Get owner of socket (receiver of SIGIO). */
+ # define F_SETOWN 6 /* Set owner of socket (receiver of SIGIO). */
+ #endif
+@@ -111,7 +116,7 @@
+ # define F_SETLKW64 14 /* Set record locking info (blocking). */
+ #endif
+
+-/* for F_[GET|SET]FL */
++/* for F_[GET|SET]FD */
+ #define FD_CLOEXEC 1 /* actually anything with low bit set goes */
+
+ /* For posix fcntl() and `l_type' field of a `struct flock' for lockf(). */
+@@ -196,3 +201,58 @@ struct flock64
+ # define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */
+ # define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */
+ #endif
++
++
++#ifdef __USE_GNU
++/* Flags for SYNC_FILE_RANGE. */
++# define SYNC_FILE_RANGE_WAIT_BEFORE 1 /* Wait upon writeout of all pages
++ in the range before performing the
++ write. */
++# define SYNC_FILE_RANGE_WRITE 2 /* Initiate writeout of all those
++ dirty pages in the range which are
++ not presently under writeback. */
++# define SYNC_FILE_RANGE_WAIT_AFTER 4 /* Wait upon writeout of all pages in
++ the range after performing the
++ write. */
++
++/* Flags for SPLICE and VMSPLICE. */
++# define SPLICE_F_MOVE 1 /* Move pages instead of copying. */
++# define SPLICE_F_NONBLOCK 2 /* Don't block on the pipe splicing
++ (but we may still block on the fd
++ we splice from/to). */
++# define SPLICE_F_MORE 4 /* Expect more data. */
++# define SPLICE_F_GIFT 8 /* Pages passed in are a gift. */
++#endif
++
++__BEGIN_DECLS
++
++#ifdef __USE_GNU
++
++/* Provide kernel hint to read ahead. */
++extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count)
++ __THROW;
++
++
++#if 0
++/* Selective file content synch'ing. */
++extern int sync_file_range (int __fd, __off64_t __from, __off64_t __to,
++ unsigned int __flags);
++#endif
++
++
++/* Splice address range into a pipe. */
++extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
++ size_t __count, unsigned int __flags);
++
++/* Splice two files together. */
++extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
++ __off64_t *__offout, size_t __len,
++ unsigned int __flags);
++
++/* In-kernel implementation of tee for pipe buffers. */
++extern ssize_t tee (int __fdin, int __fdout, size_t __len,
++ unsigned int __flags);
++
++#endif
++
++__END_DECLS
diff --git a/src/patchsets/uclibc/0.9.28.3/62_all_uClibc-arm-ioperm.patch b/src/patchsets/uclibc/0.9.28.3/62_all_uClibc-arm-ioperm.patch
new file mode 100644
index 0000000000..5ac1355d70
--- /dev/null
+++ b/src/patchsets/uclibc/0.9.28.3/62_all_uClibc-arm-ioperm.patch
@@ -0,0 +1,44 @@
+--- libc/sysdeps/linux/arm/ioperm.c.orig 2008-06-07 14:57:05.000000000 -0700
++++ libc/sysdeps/linux/arm/ioperm.c 2008-06-07 14:57:31.000000000 -0700
+@@ -44,7 +44,7 @@
+ #include <sys/types.h>
+ #include <sys/mman.h>
+
+-#include <asm/page.h>
++#include <sys/io.h>
+ #include <sys/sysctl.h>
+
+ #include <linux/version.h>
+@@ -216,28 +216,27 @@
+ }
+
+
+-void
+-outl(unsigned int b, unsigned long int port)
++int outl(unsigned long b, unsigned long int port)
+ {
+ *((volatile unsigned long *)(IO_ADDR (port))) = b;
+ }
+
+
+-unsigned int
++unsigned char
+ inb (unsigned long int port)
+ {
+ return *((volatile unsigned char *)(IO_ADDR (port)));
+ }
+
+
+-unsigned int
++unsigned short int
+ inw(unsigned long int port)
+ {
+ return *((volatile unsigned short *)(IO_ADDR (port)));
+ }
+
+
+-unsigned int
++unsigned long int
+ inl(unsigned long int port)
+ {
+ return *((volatile unsigned long *)(IO_ADDR (port)));
diff --git a/src/patchsets/uclibc/0.9.28.3/63_all_uClibc-arm-ioperm-outl.patch b/src/patchsets/uclibc/0.9.28.3/63_all_uClibc-arm-ioperm-outl.patch
new file mode 100644
index 0000000000..3dce7aa615
--- /dev/null
+++ b/src/patchsets/uclibc/0.9.28.3/63_all_uClibc-arm-ioperm-outl.patch
@@ -0,0 +1,11 @@
+--- libc/sysdeps/linux/arm/sys/io.h 2008-06-07 14:51:05.000000000 -0700
++++ libc/sysdeps/linux/arm/sys/io.h 2008-06-07 14:52:23.000000000 -0700
+@@ -41,7 +41,7 @@
+
+ extern void outb (unsigned char value, unsigned long int port) __THROW;
+ extern void outw (unsigned short value, unsigned long int port) __THROW;
+-extern void outl (unsigned long value, unsigned long int port) __THROW;
++extern int outl (unsigned long value, unsigned long int port) __THROW;
+
+ __END_DECLS
+