From 694525ec2e1ba8cd93affc352dfd149ace4fa016 Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Fri, 24 Oct 2008 08:34:31 +0000 Subject: - tidy up inline: ldso and syscalls are __always_inline (the latter would need more cleanup) --- libc/stdlib/stdlib.c | 2 +- libc/sysdeps/linux/bfin/bits/elf-fdpic.h | 2 +- libc/sysdeps/linux/bfin/crtreloc.c | 4 ++-- libc/sysdeps/linux/common/__syscall_fcntl.c | 2 +- libc/sysdeps/linux/common/getcwd.c | 4 ++-- libc/sysdeps/linux/common/getdents.c | 2 +- libc/sysdeps/linux/common/getrlimit.c | 4 ++-- libc/sysdeps/linux/common/ioctl.c | 2 +- libc/sysdeps/linux/common/ppoll.c | 2 +- libc/sysdeps/linux/common/setrlimit.c | 4 ++-- libc/sysdeps/linux/common/sigprocmask.c | 4 ++-- libc/sysdeps/linux/common/sysctl.c | 2 +- libc/sysdeps/linux/e1/bits/fenvinline.h | 2 +- libc/sysdeps/linux/frv/bits/elf-fdpic.h | 2 +- libc/sysdeps/linux/frv/crtreloc.c | 4 ++-- libc/sysdeps/linux/powerpc/ioctl.c | 2 +- 16 files changed, 22 insertions(+), 22 deletions(-) (limited to 'libc') diff --git a/libc/stdlib/stdlib.c b/libc/stdlib/stdlib.c index d72b80941..3c74be71a 100644 --- a/libc/stdlib/stdlib.c +++ b/libc/stdlib/stdlib.c @@ -936,7 +936,7 @@ libc_hidden_def(_stdlib_mb_cur_max) * To note, until now all the supported encoding are stateless. */ -static inline int is_stateful(unsigned char encoding) +static __always_inline int is_stateful(unsigned char encoding) { switch (encoding) { diff --git a/libc/sysdeps/linux/bfin/bits/elf-fdpic.h b/libc/sysdeps/linux/bfin/bits/elf-fdpic.h index 905648054..b7e87b8e9 100644 --- a/libc/sysdeps/linux/bfin/bits/elf-fdpic.h +++ b/libc/sysdeps/linux/bfin/bits/elf-fdpic.h @@ -64,7 +64,7 @@ struct elf32_fdpic_loadaddr { /* Map a pointer's VMA to its corresponding address according to the load map. */ -inline static void * +static __always_inline void * __reloc_pointer (void *p, const struct elf32_fdpic_loadmap *map) { diff --git a/libc/sysdeps/linux/bfin/crtreloc.c b/libc/sysdeps/linux/bfin/crtreloc.c index 5e038256a..408ded2f8 100644 --- a/libc/sysdeps/linux/bfin/crtreloc.c +++ b/libc/sysdeps/linux/bfin/crtreloc.c @@ -41,7 +41,7 @@ union word { /* Compute the runtime address of pointer in the range [p,e), and then map the pointer pointed by it. */ -inline static void *** +static __always_inline void *** reloc_range_indirect (void ***p, void ***e, const struct elf32_fdpic_loadmap *map) { @@ -102,7 +102,7 @@ __self_reloc (const struct elf32_fdpic_loadmap *map, need. */ /* Remap pointers in [p,e). */ -inline static void** +static __always_inline void** reloc_range (void **p, void **e, const struct elf32_fdpic_loadmap *map) { diff --git a/libc/sysdeps/linux/common/__syscall_fcntl.c b/libc/sysdeps/linux/common/__syscall_fcntl.c index 697abd0d4..a3fb74fa3 100644 --- a/libc/sysdeps/linux/common/__syscall_fcntl.c +++ b/libc/sysdeps/linux/common/__syscall_fcntl.c @@ -21,7 +21,7 @@ libc_hidden_proto(__libc_fcntl64) #endif #define __NR___syscall_fcntl __NR_fcntl -static inline +static __always_inline _syscall3(int, __syscall_fcntl, int, fd, int, cmd, long, arg) int __libc_fcntl(int fd, int cmd, ...) diff --git a/libc/sysdeps/linux/common/getcwd.c b/libc/sysdeps/linux/common/getcwd.c index f8fa3968b..ddeb483d6 100644 --- a/libc/sysdeps/linux/common/getcwd.c +++ b/libc/sysdeps/linux/common/getcwd.c @@ -30,7 +30,7 @@ libc_hidden_proto(stat) #ifdef __NR_getcwd # define __NR___syscall_getcwd __NR_getcwd -static inline +static __always_inline _syscall2(int, __syscall_getcwd, char *, buf, unsigned long, size) #else @@ -144,7 +144,7 @@ oops: return 0; } -static inline +static __always_inline int __syscall_getcwd(char * buf, unsigned long size) { int len; diff --git a/libc/sysdeps/linux/common/getdents.c b/libc/sysdeps/linux/common/getdents.c index 97c6d8b06..cff87e55c 100644 --- a/libc/sysdeps/linux/common/getdents.c +++ b/libc/sysdeps/linux/common/getdents.c @@ -39,7 +39,7 @@ struct kernel_dirent ssize_t __getdents (int fd, char *buf, size_t nbytes) attribute_hidden; #define __NR___syscall_getdents __NR_getdents -static inline _syscall3(int, __syscall_getdents, int, fd, unsigned char *, kdirp, size_t, count); +static __always_inline _syscall3(int, __syscall_getdents, int, fd, unsigned char *, kdirp, size_t, count); #ifdef __ASSUME_GETDENTS32_D_TYPE ssize_t __getdents (int fd, char *buf, size_t nbytes) diff --git a/libc/sysdeps/linux/common/getrlimit.c b/libc/sysdeps/linux/common/getrlimit.c index ec62b2e45..40b3c7368 100644 --- a/libc/sysdeps/linux/common/getrlimit.c +++ b/libc/sysdeps/linux/common/getrlimit.c @@ -21,7 +21,7 @@ libc_hidden_proto(getrlimit) /* just call ugetrlimit() */ # define __NR___syscall_ugetrlimit __NR_ugetrlimit -static inline +static __always_inline _syscall2(int, __syscall_ugetrlimit, enum __rlimit_resource, resource, struct rlimit *, rlim) int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits) @@ -39,7 +39,7 @@ _syscall2(int, getrlimit, __rlimit_resource_t, resource, /* we have to handle old style getrlimit() */ # define __NR___syscall_getrlimit __NR_getrlimit -static inline +static __always_inline _syscall2(int, __syscall_getrlimit, int, resource, struct rlimit *, rlim) int getrlimit(__rlimit_resource_t resource, struct rlimit *rlimits) diff --git a/libc/sysdeps/linux/common/ioctl.c b/libc/sysdeps/linux/common/ioctl.c index 4792409d4..51f83a372 100644 --- a/libc/sysdeps/linux/common/ioctl.c +++ b/libc/sysdeps/linux/common/ioctl.c @@ -14,7 +14,7 @@ libc_hidden_proto(ioctl) #define __NR___syscall_ioctl __NR_ioctl -static inline +static __always_inline _syscall3(int, __syscall_ioctl, int, fd, int, request, void *, arg) int ioctl(int fd, unsigned long int request, ...) diff --git a/libc/sysdeps/linux/common/ppoll.c b/libc/sysdeps/linux/common/ppoll.c index 8b12e612f..a203c0c55 100644 --- a/libc/sysdeps/linux/common/ppoll.c +++ b/libc/sysdeps/linux/common/ppoll.c @@ -25,7 +25,7 @@ libc_hidden_proto(ppoll) # define __NR___libc_ppoll __NR_ppoll -static inline +static __always_inline _syscall4(int, __libc_ppoll, struct pollfd *, fds, nfds_t, nfds, const struct timespec *, timeout, const __sigset_t *, sigmask) diff --git a/libc/sysdeps/linux/common/setrlimit.c b/libc/sysdeps/linux/common/setrlimit.c index 9a344a121..3811cd7d4 100644 --- a/libc/sysdeps/linux/common/setrlimit.c +++ b/libc/sysdeps/linux/common/setrlimit.c @@ -21,7 +21,7 @@ libc_hidden_proto(setrlimit) /* just call usetrlimit() */ # define __NR___syscall_usetrlimit __NR_usetrlimit -static inline +static __always_inline _syscall2(int, __syscall_usetrlimit, enum __rlimit_resource, resource, const struct rlimit *, rlim) int setrlimit(__rlimit_resource_t resource, struct rlimit *rlimits) @@ -39,7 +39,7 @@ _syscall2(int, setrlimit, __rlimit_resource_t, resource, /* we have to handle old style setrlimit() */ # define __NR___syscall_setrlimit __NR_setrlimit -static inline +static __always_inline _syscall2(int, __syscall_setrlimit, int, resource, const struct rlimit *, rlim) int setrlimit(__rlimit_resource_t resource, const struct rlimit *rlimits) diff --git a/libc/sysdeps/linux/common/sigprocmask.c b/libc/sysdeps/linux/common/sigprocmask.c index a9d59e602..7da17bc77 100644 --- a/libc/sysdeps/linux/common/sigprocmask.c +++ b/libc/sysdeps/linux/common/sigprocmask.c @@ -19,7 +19,7 @@ libc_hidden_proto(sigprocmask) #ifdef __NR_rt_sigprocmask # define __NR___rt_sigprocmask __NR_rt_sigprocmask -static inline +static __always_inline _syscall4(int, __rt_sigprocmask, int, how, const sigset_t *, set, sigset_t *, oldset, size_t, size) @@ -46,7 +46,7 @@ int sigprocmask(int how, const sigset_t * set, sigset_t * oldset) #else # define __NR___syscall_sigprocmask __NR_sigprocmask -static inline +static __always_inline _syscall3(int, __syscall_sigprocmask, int, how, const sigset_t *, set, sigset_t *, oldset) diff --git a/libc/sysdeps/linux/common/sysctl.c b/libc/sysdeps/linux/common/sysctl.c index 1ba23c9c9..11d53cd8e 100644 --- a/libc/sysdeps/linux/common/sysctl.c +++ b/libc/sysdeps/linux/common/sysctl.c @@ -24,7 +24,7 @@ struct __sysctl_args { unsigned long __unused[4]; }; -static inline +static __always_inline _syscall1(int, _sysctl, struct __sysctl_args *, args) int sysctl(int *name, int nlen, void *oldval, size_t * oldlenp, diff --git a/libc/sysdeps/linux/e1/bits/fenvinline.h b/libc/sysdeps/linux/e1/bits/fenvinline.h index a16fc0fb2..255624713 100644 --- a/libc/sysdeps/linux/e1/bits/fenvinline.h +++ b/libc/sysdeps/linux/e1/bits/fenvinline.h @@ -124,7 +124,7 @@ static __inline__ feclearexcept(int __excepts) * excepts. You can test for an exception either after * an FP instruction or within a SIGFPE handler */ -inline int fetestexcept(int __excepts) +__inline__ int fetestexcept(int __excepts) { unsigned int G2, G2en, G2dis; unsigned int enabled_excepts, disabled_excepts; diff --git a/libc/sysdeps/linux/frv/bits/elf-fdpic.h b/libc/sysdeps/linux/frv/bits/elf-fdpic.h index 905648054..b7e87b8e9 100644 --- a/libc/sysdeps/linux/frv/bits/elf-fdpic.h +++ b/libc/sysdeps/linux/frv/bits/elf-fdpic.h @@ -64,7 +64,7 @@ struct elf32_fdpic_loadaddr { /* Map a pointer's VMA to its corresponding address according to the load map. */ -inline static void * +static __always_inline void * __reloc_pointer (void *p, const struct elf32_fdpic_loadmap *map) { diff --git a/libc/sysdeps/linux/frv/crtreloc.c b/libc/sysdeps/linux/frv/crtreloc.c index e025b619f..ba934bc5a 100644 --- a/libc/sysdeps/linux/frv/crtreloc.c +++ b/libc/sysdeps/linux/frv/crtreloc.c @@ -34,7 +34,7 @@ Cambridge, MA 02139, USA. */ /* Compute the runtime address of pointer in the range [p,e), and then map the pointer pointed by it. */ -inline static void *** +static __always_inline void *** reloc_range_indirect (void ***p, void ***e, const struct elf32_fdpic_loadmap *map) { @@ -79,7 +79,7 @@ __self_reloc (const struct elf32_fdpic_loadmap *map, need. */ /* Remap pointers in [p,e). */ -inline static void** +static __always_inline void** reloc_range (void **p, void **e, const struct elf32_fdpic_loadmap *map) { diff --git a/libc/sysdeps/linux/powerpc/ioctl.c b/libc/sysdeps/linux/powerpc/ioctl.c index 2c37dfb40..e12362783 100644 --- a/libc/sysdeps/linux/powerpc/ioctl.c +++ b/libc/sysdeps/linux/powerpc/ioctl.c @@ -31,7 +31,7 @@ libc_hidden_proto(tcgetattr) using the new-style struct termios, and translate them to old-style. */ #define __NR___syscall_ioctl __NR_ioctl -static inline +static __always_inline _syscall3(int, __syscall_ioctl, int, fd, unsigned long int, request, void *, arg) -- cgit v1.2.3