summaryrefslogtreecommitdiff
path: root/libpthread/linuxthreads
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2008-07-23 11:19:00 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2008-07-23 11:19:00 +0000
commitf1775381f91f1250b20f1949dfd0364ddb0ee9fc (patch)
tree1326bd7f4dfd8c57f89c4d6b2f13d4f22f578abf /libpthread/linuxthreads
parentd35b0bc119816825a657f7c9c2a1f062e7048c39 (diff)
- fix inline keyword
Diffstat (limited to 'libpthread/linuxthreads')
-rw-r--r--libpthread/linuxthreads/descr.h4
-rw-r--r--libpthread/linuxthreads/internals.h6
-rw-r--r--libpthread/linuxthreads/manager.c2
-rw-r--r--libpthread/linuxthreads/ptcleanup.c2
-rw-r--r--libpthread/linuxthreads/pthread.c2
-rw-r--r--libpthread/linuxthreads/queue.h8
-rw-r--r--libpthread/linuxthreads/restart.h6
-rw-r--r--libpthread/linuxthreads/spinlock.c2
-rw-r--r--libpthread/linuxthreads/spinlock.h22
-rw-r--r--libpthread/linuxthreads/sysdeps/pthread/list.h8
-rw-r--r--libpthread/linuxthreads/sysdeps/pthread/posix-timer.h18
-rw-r--r--libpthread/linuxthreads/sysdeps/pthread/timer_routines.c20
-rw-r--r--libpthread/linuxthreads/sysdeps/unix/sysv/linux/sh/smp.h2
-rw-r--r--libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c2
-rw-r--r--libpthread/linuxthreads/sysdeps/unix/sysv/linux/smp.h2
15 files changed, 53 insertions, 53 deletions
diff --git a/libpthread/linuxthreads/descr.h b/libpthread/linuxthreads/descr.h
index 0f50d4deb..24ec30b41 100644
--- a/libpthread/linuxthreads/descr.h
+++ b/libpthread/linuxthreads/descr.h
@@ -244,8 +244,8 @@ extern int __pthread_nonstandard_stacks;
extern pthread_descr __pthread_find_self (void) __attribute__ ((pure));
-static inline pthread_descr thread_self (void) __attribute__ ((pure));
-static inline pthread_descr thread_self (void)
+static __inline__ pthread_descr thread_self (void) __attribute__ ((pure));
+static __inline__ pthread_descr thread_self (void)
{
#ifdef THREAD_SELF
return THREAD_SELF;
diff --git a/libpthread/linuxthreads/internals.h b/libpthread/linuxthreads/internals.h
index 8e270e37a..ecb7b03dd 100644
--- a/libpthread/linuxthreads/internals.h
+++ b/libpthread/linuxthreads/internals.h
@@ -174,19 +174,19 @@ extern int __pthread_smp_kernel;
/* Return the handle corresponding to a thread id */
-static inline pthread_handle thread_handle(pthread_t id)
+static __inline__ pthread_handle thread_handle(pthread_t id)
{
return &__pthread_handles[id % PTHREAD_THREADS_MAX];
}
/* Validate a thread handle. Must have acquired h->h_spinlock before. */
-static inline int invalid_handle(pthread_handle h, pthread_t id)
+static __inline__ int invalid_handle(pthread_handle h, pthread_t id)
{
return h->h_descr == NULL || h->h_descr->p_tid != id || h->h_descr->p_terminated;
}
-static inline int nonexisting_handle(pthread_handle h, pthread_t id)
+static __inline__ int nonexisting_handle(pthread_handle h, pthread_t id)
{
return h->h_descr == NULL || h->h_descr->p_tid != id;
}
diff --git a/libpthread/linuxthreads/manager.c b/libpthread/linuxthreads/manager.c
index bbdbd59a0..b0a2a3712 100644
--- a/libpthread/linuxthreads/manager.c
+++ b/libpthread/linuxthreads/manager.c
@@ -68,7 +68,7 @@ static pthread_descr manager_thread;
#if FLOATING_STACKS
# define thread_segment(seq) NULL
#else
-static inline pthread_descr thread_segment(int seg)
+static __inline__ pthread_descr thread_segment(int seg)
{
# ifdef _STACK_GROWS_UP
return (pthread_descr)(THREAD_STACK_START_ADDRESS + (seg - 1) * STACK_SIZE)
diff --git a/libpthread/linuxthreads/ptcleanup.c b/libpthread/linuxthreads/ptcleanup.c
index fa44ea142..6213b56f3 100644
--- a/libpthread/linuxthreads/ptcleanup.c
+++ b/libpthread/linuxthreads/ptcleanup.c
@@ -28,7 +28,7 @@
#endif
#ifndef NO_PTR_DEMANGLE
-static inline uintptr_t
+static __inline__ uintptr_t
demangle_ptr (uintptr_t x)
{
#ifdef PTR_DEMANGLE
diff --git a/libpthread/linuxthreads/pthread.c b/libpthread/linuxthreads/pthread.c
index 64aad7cc1..4c44252ab 100644
--- a/libpthread/linuxthreads/pthread.c
+++ b/libpthread/linuxthreads/pthread.c
@@ -468,7 +468,7 @@ __libc_dl_error_tsd (void)
#endif
#ifdef USE_TLS
-static inline void __attribute__((always_inline))
+static __inline__ void __attribute__((always_inline))
init_one_static_tls (pthread_descr descr, struct link_map *map)
{
# if TLS_TCB_AT_TP
diff --git a/libpthread/linuxthreads/queue.h b/libpthread/linuxthreads/queue.h
index 28bd75531..e50517f77 100644
--- a/libpthread/linuxthreads/queue.h
+++ b/libpthread/linuxthreads/queue.h
@@ -18,7 +18,7 @@
linked through their p_nextwaiting field. The lists are kept
sorted by decreasing priority, and then decreasing waiting time. */
-static inline void enqueue(pthread_descr * q, pthread_descr th)
+static __inline__ void enqueue(pthread_descr * q, pthread_descr th)
{
int prio = th->p_priority;
ASSERT(th->p_nextwaiting == NULL);
@@ -32,7 +32,7 @@ static inline void enqueue(pthread_descr * q, pthread_descr th)
*q = th;
}
-static inline pthread_descr dequeue(pthread_descr * q)
+static __inline__ pthread_descr dequeue(pthread_descr * q)
{
pthread_descr th;
th = *q;
@@ -43,7 +43,7 @@ static inline pthread_descr dequeue(pthread_descr * q)
return th;
}
-static inline int remove_from_queue(pthread_descr * q, pthread_descr th)
+static __inline__ int remove_from_queue(pthread_descr * q, pthread_descr th)
{
for (; *q != NULL; q = &((*q)->p_nextwaiting)) {
if (*q == th) {
@@ -55,7 +55,7 @@ static inline int remove_from_queue(pthread_descr * q, pthread_descr th)
return 0;
}
-static inline int queue_is_empty(pthread_descr * q)
+static __inline__ int queue_is_empty(pthread_descr * q)
{
return *q == NULL;
}
diff --git a/libpthread/linuxthreads/restart.h b/libpthread/linuxthreads/restart.h
index 24d9fab74..f53642eda 100644
--- a/libpthread/linuxthreads/restart.h
+++ b/libpthread/linuxthreads/restart.h
@@ -17,7 +17,7 @@
/* Primitives for controlling thread execution */
-static inline void restart(pthread_descr th)
+static __inline__ void restart(pthread_descr th)
{
/* See pthread.c */
#if __ASSUME_REALTIME_SIGNALS
@@ -27,7 +27,7 @@ static inline void restart(pthread_descr th)
#endif
}
-static inline void suspend(pthread_descr self)
+static __inline__ void suspend(pthread_descr self)
{
/* See pthread.c */
#if __ASSUME_REALTIME_SIGNALS
@@ -37,7 +37,7 @@ static inline void suspend(pthread_descr self)
#endif
}
-static inline int timedsuspend(pthread_descr self,
+static __inline__ int timedsuspend(pthread_descr self,
const struct timespec *abstime)
{
/* See pthread.c */
diff --git a/libpthread/linuxthreads/spinlock.c b/libpthread/linuxthreads/spinlock.c
index 6b6610688..f32540286 100644
--- a/libpthread/linuxthreads/spinlock.c
+++ b/libpthread/linuxthreads/spinlock.c
@@ -26,7 +26,7 @@
static void __pthread_acquire(int * spinlock);
-static inline void __pthread_release(int * spinlock)
+static __inline__ void __pthread_release(int * spinlock)
{
WRITE_MEMORY_BARRIER();
*spinlock = __LT_SPINLOCK_INIT;
diff --git a/libpthread/linuxthreads/spinlock.h b/libpthread/linuxthreads/spinlock.h
index ff96fc336..210ead471 100644
--- a/libpthread/linuxthreads/spinlock.h
+++ b/libpthread/linuxthreads/spinlock.h
@@ -39,7 +39,7 @@ extern int __pthread_has_cas;
extern int __pthread_compare_and_swap(long * ptr, long oldval, long newval,
int * spinlock);
-static inline int compare_and_swap(long * ptr, long oldval, long newval,
+static __inline__ int compare_and_swap(long * ptr, long oldval, long newval,
int * spinlock)
{
if (__builtin_expect (__pthread_has_cas, 1))
@@ -56,7 +56,7 @@ static inline int compare_and_swap(long * ptr, long oldval, long newval,
#ifdef HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS
-static inline int
+static __inline__ int
compare_and_swap_with_release_semantics (long * ptr, long oldval,
long newval, int * spinlock)
{
@@ -66,7 +66,7 @@ compare_and_swap_with_release_semantics (long * ptr, long oldval,
#endif
-static inline int compare_and_swap(long * ptr, long oldval, long newval,
+static __inline__ int compare_and_swap(long * ptr, long oldval, long newval,
int * spinlock)
{
return __compare_and_swap(ptr, oldval, newval);
@@ -77,7 +77,7 @@ static inline int compare_and_swap(long * ptr, long oldval, long newval,
extern int __pthread_compare_and_swap(long * ptr, long oldval, long newval,
int * spinlock);
-static inline int compare_and_swap(long * ptr, long oldval, long newval,
+static __inline__ int compare_and_swap(long * ptr, long oldval, long newval,
int * spinlock)
{
return __pthread_compare_and_swap(ptr, oldval, newval, spinlock);
@@ -96,13 +96,13 @@ extern void internal_function __pthread_lock(struct _pthread_fastlock * lock,
pthread_descr self);
extern int __pthread_unlock(struct _pthread_fastlock *lock);
-static inline void __pthread_init_lock(struct _pthread_fastlock * lock)
+static __inline__ void __pthread_init_lock(struct _pthread_fastlock * lock)
{
lock->__status = 0;
lock->__spinlock = __LT_SPINLOCK_INIT;
}
-static inline int __pthread_trylock (struct _pthread_fastlock * lock)
+static __inline__ int __pthread_trylock (struct _pthread_fastlock * lock)
{
#if defined TEST_FOR_COMPARE_AND_SWAP
if (!__pthread_has_cas)
@@ -133,13 +133,13 @@ extern int __pthread_alt_timedlock(struct _pthread_fastlock * lock,
extern void __pthread_alt_unlock(struct _pthread_fastlock *lock);
-static inline void __pthread_alt_init_lock(struct _pthread_fastlock * lock)
+static __inline__ void __pthread_alt_init_lock(struct _pthread_fastlock * lock)
{
lock->__status = 0;
lock->__spinlock = __LT_SPINLOCK_INIT;
}
-static inline int __pthread_alt_trylock (struct _pthread_fastlock * lock)
+static __inline__ int __pthread_alt_trylock (struct _pthread_fastlock * lock)
{
#if defined TEST_FOR_COMPARE_AND_SWAP
if (!__pthread_has_cas)
@@ -172,7 +172,7 @@ static inline int __pthread_alt_trylock (struct _pthread_fastlock * lock)
/* Operations on pthread_atomic, which is defined in internals.h */
-static inline long atomic_increment(struct pthread_atomic *pa)
+static __inline__ long atomic_increment(struct pthread_atomic *pa)
{
long oldval;
@@ -184,7 +184,7 @@ static inline long atomic_increment(struct pthread_atomic *pa)
}
-static inline long atomic_decrement(struct pthread_atomic *pa)
+static __inline__ long atomic_decrement(struct pthread_atomic *pa)
{
long oldval;
@@ -196,7 +196,7 @@ static inline long atomic_decrement(struct pthread_atomic *pa)
}
-static inline __attribute__((always_inline)) void
+static __inline__ __attribute__((always_inline)) void
__pthread_set_own_extricate_if (pthread_descr self, pthread_extricate_if *peif)
{
/* Only store a non-null peif if the thread has cancellation enabled.
diff --git a/libpthread/linuxthreads/sysdeps/pthread/list.h b/libpthread/linuxthreads/sysdeps/pthread/list.h
index 43186a2d5..75decfbb7 100644
--- a/libpthread/linuxthreads/sysdeps/pthread/list.h
+++ b/libpthread/linuxthreads/sysdeps/pthread/list.h
@@ -43,7 +43,7 @@ typedef struct list_head
/* Add new element at the head of the list. */
-static inline void
+static __inline__ void
list_add (list_t *newp, list_t *head)
{
head->next->prev = newp;
@@ -54,7 +54,7 @@ list_add (list_t *newp, list_t *head)
/* Add new element at the tail of the list. */
-static inline void
+static __inline__ void
list_add_tail (list_t *newp, list_t *head)
{
head->prev->next = newp;
@@ -65,7 +65,7 @@ list_add_tail (list_t *newp, list_t *head)
/* Remove element from list. */
-static inline void
+static __inline__ void
list_del (list_t *elem)
{
elem->next->prev = elem->prev;
@@ -74,7 +74,7 @@ list_del (list_t *elem)
/* Join two lists. */
-static inline void
+static __inline__ void
list_splice (list_t *add, list_t *head)
{
/* Do nothing if the list which gets added is empty. */
diff --git a/libpthread/linuxthreads/sysdeps/pthread/posix-timer.h b/libpthread/linuxthreads/sysdeps/pthread/posix-timer.h
index 1b0a2b65e..5486f7d6a 100644
--- a/libpthread/linuxthreads/sysdeps/pthread/posix-timer.h
+++ b/libpthread/linuxthreads/sysdeps/pthread/posix-timer.h
@@ -88,7 +88,7 @@ extern struct thread_node __timer_signal_thread_rclk;
/* Return pointer to timer structure corresponding to ID. */
-static inline struct timer_node *
+static __inline__ struct timer_node *
timer_id2ptr (timer_t timerid)
{
if (timerid >= 0 && timerid < TIMER_MAX)
@@ -98,14 +98,14 @@ timer_id2ptr (timer_t timerid)
}
/* Return ID of TIMER. */
-static inline int
+static __inline__ int
timer_ptr2id (struct timer_node *timer)
{
return timer - __timer_array;
}
/* Check whether timer is valid; global mutex must be held. */
-static inline int
+static __inline__ int
timer_valid (struct timer_node *timer)
{
return timer && timer->inuse == TIMER_INUSE;
@@ -114,13 +114,13 @@ timer_valid (struct timer_node *timer)
/* Timer refcount functions; need global mutex. */
extern void __timer_dealloc (struct timer_node *timer);
-static inline void
+static __inline__ void
timer_addref (struct timer_node *timer)
{
timer->refcount++;
}
-static inline void
+static __inline__ void
timer_delref (struct timer_node *timer)
{
if (--timer->refcount == 0)
@@ -128,7 +128,7 @@ timer_delref (struct timer_node *timer)
}
/* Timespec helper routines. */
-static inline int
+static __inline__ int
timespec_compare (const struct timespec *left, const struct timespec *right)
{
if (left->tv_sec < right->tv_sec)
@@ -144,7 +144,7 @@ timespec_compare (const struct timespec *left, const struct timespec *right)
return 0;
}
-static inline void
+static __inline__ void
timespec_add (struct timespec *sum, const struct timespec *left,
const struct timespec *right)
{
@@ -158,7 +158,7 @@ timespec_add (struct timespec *sum, const struct timespec *left,
}
}
-static inline void
+static __inline__ void
timespec_sub (struct timespec *diff, const struct timespec *left,
const struct timespec *right)
{
@@ -174,7 +174,7 @@ timespec_sub (struct timespec *diff, const struct timespec *left,
/* We need one of the list functions in the other modules. */
-static inline void
+static __inline__ void
list_unlink_ip (struct list_links *list)
{
struct list_links *lnext = list->next, *lprev = list->prev;
diff --git a/libpthread/linuxthreads/sysdeps/pthread/timer_routines.c b/libpthread/linuxthreads/sysdeps/pthread/timer_routines.c
index 3877b86fb..25b4630ee 100644
--- a/libpthread/linuxthreads/sysdeps/pthread/timer_routines.c
+++ b/libpthread/linuxthreads/sysdeps/pthread/timer_routines.c
@@ -65,13 +65,13 @@ extern int __syscall_rt_sigqueueinfo (int, int, siginfo_t *);
/* List handling functions. */
-static inline void
+static __inline__ void
list_init (struct list_links *list)
{
list->next = list->prev = list;
}
-static inline void
+static __inline__ void
list_append (struct list_links *list, struct list_links *newp)
{
newp->prev = list->prev;
@@ -80,7 +80,7 @@ list_append (struct list_links *list, struct list_links *newp)
list->prev = newp;
}
-static inline void
+static __inline__ void
list_insbefore (struct list_links *list, struct list_links *newp)
{
list_append (list, newp);
@@ -91,7 +91,7 @@ list_insbefore (struct list_links *list, struct list_links *newp)
* is already unlinked is disastrous rather than a noop.
*/
-static inline void
+static __inline__ void
list_unlink (struct list_links *list)
{
struct list_links *lnext = list->next, *lprev = list->prev;
@@ -100,25 +100,25 @@ list_unlink (struct list_links *list)
lprev->next = lnext;
}
-static inline struct list_links *
+static __inline__ struct list_links *
list_first (struct list_links *list)
{
return list->next;
}
-static inline struct list_links *
+static __inline__ struct list_links *
list_null (struct list_links *list)
{
return list;
}
-static inline struct list_links *
+static __inline__ struct list_links *
list_next (struct list_links *list)
{
return list->next;
}
-static inline int
+static __inline__ int
list_isempty (struct list_links *list)
{
return list->next == list;
@@ -126,14 +126,14 @@ list_isempty (struct list_links *list)
/* Functions build on top of the list functions. */
-static inline struct thread_node *
+static __inline__ struct thread_node *
thread_links2ptr (struct list_links *list)
{
return (struct thread_node *) ((char *) list
- offsetof (struct thread_node, links));
}
-static inline struct timer_node *
+static __inline__ struct timer_node *
timer_links2ptr (struct list_links *list)
{
return (struct timer_node *) ((char *) list
diff --git a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sh/smp.h b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sh/smp.h
index 2c0cbe99a..5e2f43cda 100644
--- a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sh/smp.h
+++ b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sh/smp.h
@@ -17,7 +17,7 @@
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-static inline int
+static __inline__ int
is_smp_system (void)
{
return 0;
diff --git a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c
index fdec09455..3432125bb 100644
--- a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c
+++ b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c
@@ -31,7 +31,7 @@ extern int __syscall_rt_sigtimedwait (const sigset_t *__unbounded, siginfo_t *__
/* Return any pending signal or wait for one for the given time. */
-static inline int
+static __inline__ int
do_sigwait (const sigset_t *set, int *sig)
{
int ret;
diff --git a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/smp.h b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/smp.h
index 81289294b..9ab75e8e6 100644
--- a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/smp.h
+++ b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/smp.h
@@ -22,7 +22,7 @@
/* Test whether the machine has more than one processor. This is not the
best test but good enough. More complicated tests would require `malloc'
which is not available at that time. */
-static inline int
+static __inline__ int
is_smp_system (void)
{
static const int sysctl_args[] = { CTL_KERN, KERN_VERSION };