diff options
Diffstat (limited to 'include/sys')
-rw-r--r-- | include/sys/auxv.h | 8 | ||||
-rw-r--r-- | include/sys/epoll.h | 3 | ||||
-rw-r--r-- | include/sys/file.h | 4 | ||||
-rw-r--r-- | include/sys/gmon.h | 8 | ||||
-rw-r--r-- | include/sys/ioctl.h | 5 | ||||
-rw-r--r-- | include/sys/mman.h | 5 | ||||
-rw-r--r-- | include/sys/prctl.h | 3 | ||||
-rw-r--r-- | include/sys/profil.h | 3 | ||||
-rw-r--r-- | include/sys/resource.h | 1 | ||||
-rw-r--r-- | include/sys/sendfile.h | 6 | ||||
-rw-r--r-- | include/sys/socket.h | 4 | ||||
-rw-r--r-- | include/sys/stat.h | 6 | ||||
-rw-r--r-- | include/sys/statfs.h | 13 | ||||
-rw-r--r-- | include/sys/statvfs.h | 6 | ||||
-rw-r--r-- | include/sys/sysctl.h | 3 | ||||
-rw-r--r-- | include/sys/sysinfo.h | 9 | ||||
-rw-r--r-- | include/sys/sysmacros.h | 52 | ||||
-rw-r--r-- | include/sys/time.h | 2 | ||||
-rw-r--r-- | include/sys/uio.h | 8 | ||||
-rw-r--r-- | include/sys/utsname.h | 2 | ||||
-rw-r--r-- | include/sys/wait.h | 6 |
21 files changed, 139 insertions, 18 deletions
diff --git a/include/sys/auxv.h b/include/sys/auxv.h new file mode 100644 index 0000000000..3bab6d05d4 --- /dev/null +++ b/include/sys/auxv.h @@ -0,0 +1,8 @@ +#include <misc/sys/auxv.h> + +#ifndef _ISOMAC + +extern __typeof (getauxval) __getauxval; +libc_hidden_proto (__getauxval) + +#endif /* !_ISOMAC */ diff --git a/include/sys/epoll.h b/include/sys/epoll.h index ce1c2e26d5..86e0a54e62 100644 --- a/include/sys/epoll.h +++ b/include/sys/epoll.h @@ -1,6 +1,9 @@ #ifndef _SYS_EPOLL_H #include_next <sys/epoll.h> +# ifndef _ISOMAC + libc_hidden_proto (epoll_pwait) +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/file.h b/include/sys/file.h index e73a4d1c94..d0cd1f9e15 100644 --- a/include/sys/file.h +++ b/include/sys/file.h @@ -1,6 +1,10 @@ #ifndef _SYS_FILE_H #include <misc/sys/file.h> +# ifndef _ISOMAC + /* Now define the internal interfaces. */ extern int __flock (int __fd, int __operation); + +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/gmon.h b/include/sys/gmon.h index 55739cf00c..06b07fb2a5 100644 --- a/include/sys/gmon.h +++ b/include/sys/gmon.h @@ -1,15 +1,15 @@ #ifndef _SYS_GMON_H #include <gmon/sys/gmon.h> +# ifndef _ISOMAC + /* Now define the internal interfaces. */ /* Write current profiling data to file. */ extern void __write_profiling (void); extern void write_profiling (void); -struct __bb; -extern void __bb_init_func (struct __bb *bb); -extern void __bb_exit_func (void); - extern struct gmonparam _gmonparam attribute_hidden; + +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/ioctl.h b/include/sys/ioctl.h index ebadd526b9..dd7c3c7c9c 100644 --- a/include/sys/ioctl.h +++ b/include/sys/ioctl.h @@ -1,6 +1,11 @@ #ifndef _SYS_IOCTL_H #include <misc/sys/ioctl.h> +# ifndef _ISOMAC + /* Now define the internal interfaces. */ extern int __ioctl (int __fd, unsigned long int __request, ...); +libc_hidden_proto (__ioctl) + +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/mman.h b/include/sys/mman.h index 7026f69f42..503edaae88 100644 --- a/include/sys/mman.h +++ b/include/sys/mman.h @@ -5,10 +5,14 @@ /* Now define the internal interfaces. */ extern void *__mmap (void *__addr, size_t __len, int __prot, int __flags, int __fd, __off_t __offset); +libc_hidden_proto (__mmap) extern void *__mmap64 (void *__addr, size_t __len, int __prot, int __flags, int __fd, __off64_t __offset); +libc_hidden_proto (__mmap64) extern int __munmap (void *__addr, size_t __len); +libc_hidden_proto (__munmap) extern int __mprotect (void *__addr, size_t __len, int __prot); +libc_hidden_proto (__mprotect) extern int __madvise (void *__addr, size_t __len, int __advice); libc_hidden_proto (__madvise) @@ -16,6 +20,7 @@ libc_hidden_proto (__madvise) /* This one is Linux specific. */ extern void *__mremap (void *__addr, size_t __old_len, size_t __new_len, int __flags, ...); +libc_hidden_proto (__mremap) # if IS_IN (rtld) # include <dl-mman.h> diff --git a/include/sys/prctl.h b/include/sys/prctl.h index 316f454c1c..0920ed642b 100644 --- a/include/sys/prctl.h +++ b/include/sys/prctl.h @@ -1,6 +1,9 @@ #ifndef _SYS_PRCTL_H #include_next <sys/prctl.h> +# ifndef _ISOMAC + extern int __prctl (int __option, ...); +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/profil.h b/include/sys/profil.h index 7bf17003ad..2b1133073e 100644 --- a/include/sys/profil.h +++ b/include/sys/profil.h @@ -1,9 +1,12 @@ #ifndef _PROFIL_H #include <gmon/sys/profil.h> +# ifndef _ISOMAC + /* Now define the internal interfaces. */ extern int __sprofil (struct prof *__profp, int __profcnt, struct timeval *__tvp, unsigned int __flags); +# endif /* !_ISOMAC */ #endif /* _PROFIL_H */ diff --git a/include/sys/resource.h b/include/sys/resource.h index 688c46c4ae..c55d4e63bd 100644 --- a/include/sys/resource.h +++ b/include/sys/resource.h @@ -23,5 +23,6 @@ extern int __getrusage (enum __rusage_who __who, struct rusage *__usage) extern int __setrlimit (enum __rlimit_resource __resource, const struct rlimit *__rlimits); +libc_hidden_proto (__setrlimit); #endif #endif diff --git a/include/sys/sendfile.h b/include/sys/sendfile.h index abe09769cc..b88cca27b8 100644 --- a/include/sys/sendfile.h +++ b/include/sys/sendfile.h @@ -1 +1,7 @@ #include <io/sys/sendfile.h> + +#ifndef _ISOMAC + +extern __typeof (sendfile64) __sendfile64 attribute_hidden; + +#endif diff --git a/include/sys/socket.h b/include/sys/socket.h index a00ab3cf93..26db0e0d77 100644 --- a/include/sys/socket.h +++ b/include/sys/socket.h @@ -20,7 +20,7 @@ extern int __socketpair (int __domain, int __type, int __protocol, /* Return a socket of any type. The socket can be used in subsequent ioctl calls to talk to the kernel. */ -extern int __opensock (void) internal_function attribute_hidden; +extern int __opensock (void) attribute_hidden; /* Put the address of the peer connected to socket FD into *ADDR (which is *LEN bytes long), and its actual length into *LEN. */ @@ -154,5 +154,7 @@ libc_hidden_proto (__libc_sa_len) # define SA_LEN(_x) __libc_sa_len((_x)->sa_family) #endif +libc_hidden_proto (__cmsg_nxthdr) + #endif #endif diff --git a/include/sys/stat.h b/include/sys/stat.h index 4f31c00eca..b82d452780 100644 --- a/include/sys/stat.h +++ b/include/sys/stat.h @@ -7,12 +7,14 @@ extern int __stat (const char *__file, struct stat *__buf); extern int __fstat (int __fd, struct stat *__buf); extern int __lstat (const char *__file, struct stat *__buf); extern int __chmod (const char *__file, __mode_t __mode); +libc_hidden_proto (__chmod) extern int __fchmod (int __fd, __mode_t __mode); extern __mode_t __umask (__mode_t __mask); extern int __mkdir (const char *__path, __mode_t __mode); +libc_hidden_proto (__mkdir) extern int __mknod (const char *__path, __mode_t __mode, __dev_t __dev); -#if IS_IN (libc) || IS_IN (rtld) +#if IS_IN (libc) || (IS_IN (rtld) && !defined NO_RTLD_HIDDEN) hidden_proto (__fxstat) hidden_proto (__fxstat64) hidden_proto (__lxstat) @@ -35,7 +37,7 @@ libc_hidden_proto (__xmknodat) libc_hidden_proto (__fxstatat) libc_hidden_proto (__fxstatat64) -# if IS_IN (rtld) +# if IS_IN (rtld) && !defined NO_RTLD_HIDDEN extern __typeof (__fxstatat64) __fxstatat64 attribute_hidden; # endif diff --git a/include/sys/statfs.h b/include/sys/statfs.h index e34ad02965..8a9f5a7b3b 100644 --- a/include/sys/statfs.h +++ b/include/sys/statfs.h @@ -1,10 +1,17 @@ #ifndef _SYS_STATFS_H #include <io/sys/statfs.h> +# ifndef _ISOMAC + /* Now define the internal interfaces. */ extern int __statfs (const char *__file, struct statfs *__buf); libc_hidden_proto (__statfs) -extern int __fstatfs (int __fildes, struct statfs *__buf); -extern int __statfs64 (const char *__file, struct statfs64 *__buf); -extern int __fstatfs64 (int __fildes, struct statfs64 *__buf); +extern int __fstatfs (int __fildes, struct statfs *__buf) + attribute_hidden; +extern int __statfs64 (const char *__file, struct statfs64 *__buf) + attribute_hidden; +extern int __fstatfs64 (int __fildes, struct statfs64 *__buf) + attribute_hidden; + +# endif /* !_ISOMAC */ #endif diff --git a/include/sys/statvfs.h b/include/sys/statvfs.h index fa3045386d..4cd1977c35 100644 --- a/include/sys/statvfs.h +++ b/include/sys/statvfs.h @@ -3,8 +3,10 @@ #ifndef _ISOMAC /* Now define the internal interfaces. */ -extern int __statvfs64 (const char *__file, struct statvfs64 *__buf); -extern int __fstatvfs64 (int __fildes, struct statvfs64 *__buf); +extern int __statvfs64 (const char *__file, struct statvfs64 *__buf) + attribute_hidden; +extern int __fstatvfs64 (int __fildes, struct statvfs64 *__buf) + attribute_hidden; libc_hidden_proto (statvfs) libc_hidden_proto (fstatvfs) diff --git a/include/sys/sysctl.h b/include/sys/sysctl.h index 4fffb4ff49..2a15e91354 100644 --- a/include/sys/sysctl.h +++ b/include/sys/sysctl.h @@ -1,10 +1,13 @@ #ifndef _SYS_SYSCTL_H #include_next <sys/sysctl.h> +# ifndef _ISOMAC + /* Read or write system parameters (Linux, FreeBSD specific). */ extern int __sysctl (int *__name, int __nlen, void *__oldval, size_t *__oldlenp, void *__newval, size_t __newlen); libc_hidden_proto (__sysctl) +# endif /* !_ISOMAC */ #endif /* _SYS_SYSCTL_H */ diff --git a/include/sys/sysinfo.h b/include/sys/sysinfo.h index d33055a2b3..7388356a19 100644 --- a/include/sys/sysinfo.h +++ b/include/sys/sysinfo.h @@ -1,21 +1,28 @@ #ifndef _SYS_SYSINFO_H #include_next <sys/sysinfo.h> +# ifndef _ISOMAC + /* Now we define the internal interface. */ /* Return number of configured processors. */ extern int __get_nprocs_conf (void); +libc_hidden_proto (__get_nprocs_conf) /* Return number of available processors. */ extern int __get_nprocs (void); +libc_hidden_proto (__get_nprocs) /* Return number of physical pages of memory in the system. */ extern long int __get_phys_pages (void); +libc_hidden_proto (__get_phys_pages) /* Return number of available physical pages of memory in the system. */ extern long int __get_avphys_pages (void); +libc_hidden_proto (__get_avphys_pages) /* Return maximum number of processes this real user ID can have. */ -extern long int __get_child_max (void); +extern long int __get_child_max (void) attribute_hidden; +# endif /* !_ISOMAC */ #endif /* sys/sysinfo.h */ diff --git a/include/sys/sysmacros.h b/include/sys/sysmacros.h new file mode 100644 index 0000000000..3c2b9c2689 --- /dev/null +++ b/include/sys/sysmacros.h @@ -0,0 +1,52 @@ +/* Definitions of macros to access 'dev_t' values. Internal header. + Copyright (C) 2018 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ + +#ifndef _ISOMAC +# define __SYSMACROS_NEED_IMPLEMENTATION +#endif + +#include <misc/sys/sysmacros.h> + +#if !defined _SYS_SYSMACROS_H_WRAPPER && !defined _ISOMAC +# define _SYS_SYSMACROS_H_WRAPPER 1 + +libc_hidden_proto (gnu_dev_major) +libc_hidden_proto (gnu_dev_minor) +libc_hidden_proto (gnu_dev_makedev) + +# undef __SYSMACROS_DECL_TEMPL +# define __SYSMACROS_DECL_TEMPL(rtype, name, proto) \ + extern rtype __gnu_dev_##name proto \ + __THROW __attribute_const__ attribute_hidden; + +# undef __SYSMACROS_IMPL_TEMPL +# define __SYSMACROS_IMPL_TEMPL(rtype, name, proto) \ + __extension__ __extern_inline __attribute_const__ rtype \ + __NTH (__gnu_dev_##name proto) + +__SYSMACROS_DECLARE_MAJOR (__SYSMACROS_DECL_TEMPL) +__SYSMACROS_DECLARE_MINOR (__SYSMACROS_DECL_TEMPL) +__SYSMACROS_DECLARE_MAKEDEV (__SYSMACROS_DECL_TEMPL) + +# ifdef __USE_EXTERN_INLINES +__SYSMACROS_DEFINE_MAJOR (__SYSMACROS_IMPL_TEMPL) +__SYSMACROS_DEFINE_MINOR (__SYSMACROS_IMPL_TEMPL) +__SYSMACROS_DEFINE_MAKEDEV (__SYSMACROS_IMPL_TEMPL) +# endif + +#endif diff --git a/include/sys/time.h b/include/sys/time.h index 41bf458141..98f6b6b2cc 100644 --- a/include/sys/time.h +++ b/include/sys/time.h @@ -1,5 +1,5 @@ /* Time function internal interfaces. - Copyright (C) 1997-2016 Free Software Foundation, Inc. + Copyright (C) 1997-2018 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 diff --git a/include/sys/uio.h b/include/sys/uio.h index f44ce182ba..204c4b906d 100644 --- a/include/sys/uio.h +++ b/include/sys/uio.h @@ -5,7 +5,15 @@ /* Now define the internal interfaces. */ extern ssize_t __readv (int __fd, const struct iovec *__iovec, int __count); +libc_hidden_proto (__readv) extern ssize_t __writev (int __fd, const struct iovec *__iovec, int __count); +libc_hidden_proto (__writev) + +/* Used for p{read,write}{v64}v2 implementation. */ +libc_hidden_proto (preadv) +libc_hidden_proto (preadv64) +libc_hidden_proto (pwritev) +libc_hidden_proto (pwritev64) #endif #endif diff --git a/include/sys/utsname.h b/include/sys/utsname.h index 14f4247dd4..9ed5fa2565 100644 --- a/include/sys/utsname.h +++ b/include/sys/utsname.h @@ -7,7 +7,7 @@ extern int __uname (struct utsname *__name); libc_hidden_proto (uname) libc_hidden_proto (__uname) -# if IS_IN (rtld) +# if IS_IN (rtld) && !defined NO_RTLD_HIDDEN extern __typeof (__uname) __uname attribute_hidden; # endif #endif diff --git a/include/sys/wait.h b/include/sys/wait.h index 9a38e61be7..5ac9cd6ca6 100644 --- a/include/sys/wait.h +++ b/include/sys/wait.h @@ -9,10 +9,10 @@ libc_hidden_proto (__waitpid) extern int __waitid (idtype_t idtype, id_t id, siginfo_t *infop, int options); extern __pid_t __libc_wait (int *__stat_loc); -extern __pid_t __wait (__WAIT_STATUS __stat_loc); -extern __pid_t __wait3 (__WAIT_STATUS __stat_loc, +extern __pid_t __wait (int *__stat_loc); +extern __pid_t __wait3 (int *__stat_loc, int __options, struct rusage * __usage); -extern __pid_t __wait4 (__pid_t __pid, __WAIT_STATUS __stat_loc, +extern __pid_t __wait4 (__pid_t __pid, int *__stat_loc, int __options, struct rusage *__usage) attribute_hidden; #endif |