about summary refs log tree commit diff
path: root/nptl/sysdeps/unix/sysv/linux/sh
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2003-03-12 10:28:07 +0000
committerRoland McGrath <roland@gnu.org>2003-03-12 10:28:07 +0000
commit326132dbdba5be889b8f97430779ea15c9b90ce1 (patch)
tree20a0078294ba2b12cf183a350a00ca86c04546b3 /nptl/sysdeps/unix/sysv/linux/sh
parentda49194d2d1d19baa603b7e98677377cfb00d8dd (diff)
downloadglibc-326132dbdba5be889b8f97430779ea15c9b90ce1.tar.gz
glibc-326132dbdba5be889b8f97430779ea15c9b90ce1.tar.xz
glibc-326132dbdba5be889b8f97430779ea15c9b90ce1.zip
2003-03-12 Roland McGrath <roland@redhat.com>
	* pthread-errnos.sym: New file.
	* Makefile (gen-as-const-headers): New variable, list that file.
	* sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include generated
	header <pthread-errnos.h> instead of defining errno values here.
	* sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
	Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
	Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
	* sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
	* sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
	* sysdeps/i386/i486/pthread_spin_trylock.S: Likewise.
	* sysdeps/x86_64/pthread_spin_trylock.S: Likewise.
	* sysdeps/sh/pthread_spin_trylock.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
	* sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/sh')
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S3
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S5
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S6
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S9
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S9
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S8
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/sem_post.S7
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S7
-rw-r--r--nptl/sysdeps/unix/sysv/linux/sh/sem_trywait.S7
9 files changed, 17 insertions, 44 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S b/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S
index 3a157a0583..ecb0059036 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/lowlevellock.S
@@ -17,6 +17,7 @@
    02111-1307 USA.  */
 
 #include <sysdep.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 	.text
@@ -26,8 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define ETIMEDOUT               110
-
 
 	.globl	__lll_lock_wait
 	.type	__lll_lock_wait,@function
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S b/nptl/sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
index f0be38a797..59aeff70fb 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
@@ -19,6 +19,7 @@
 #include <sysdep.h>
 #include <shlib-compat.h>
 #include <lowlevelcond.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 #define SYS_gettimeofday	__NR_gettimeofday
@@ -26,8 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define ETIMEDOUT		110
-
 
 	.text
 
@@ -164,7 +163,7 @@ __pthread_cond_timedwait:
 	mov.l	.Ldisable1, r1
 	bsrf	r1
 	 mov.l	@r15, r4
-.Ldisable1b:	
+.Ldisable1b:
 
 	/* Lock.  */
 	mov	#1, r3
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S
index 2c6adf81c2..1aa1c72bbf 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S
@@ -19,15 +19,13 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <tcb-offsets.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 #define SYS_futex		240
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EAGAIN		11
-#define EDEADLK		35
-
 
 	.text
 
@@ -207,7 +205,7 @@ __pthread_rwlock_rdlock:
 	.long	__lll_mutex_lock_wait-.Lwait0b
 .Lwake0:
 	.long	__lll_mutex_unlock_wake-.Lwake0b
-.Lwait1:	
+.Lwait1:
 	.long	__lll_mutex_lock_wait-.Lwait1b
 .Lwake1:
 	.long	__lll_mutex_unlock_wake-.Lwake1b
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
index b287dd434b..84b5cdda3b 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
@@ -19,6 +19,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <tcb-offsets.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 #define SYS_gettimeofday	__NR_gettimeofday
@@ -26,10 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EAGAIN		11
-#define EDEADLK		35
-#define ETIMEDOUT	110
-
 
 	.text
 
@@ -263,11 +260,11 @@ pthread_rwlock_timedrdlock:
 .Ltcboff:
 	.word	TLS_PRE_TCB_SIZE
 	.align	2
-.Lwait2:	
+.Lwait2:
 	.long	__lll_mutex_lock_wait-.Lwait2b
 .Lwake2:
 	.long	__lll_mutex_unlock_wake-.Lwake2b
-.Lwait3:	
+.Lwait3:
 	.long	__lll_mutex_lock_wait-.Lwait3b
 .Lwake3:
 	.long	__lll_mutex_unlock_wake-.Lwake3b
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
index 2e9bf05b00..60ff48f90a 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
@@ -19,6 +19,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <tcb-offsets.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 #define SYS_gettimeofday	__NR_gettimeofday
@@ -26,10 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EAGAIN		11
-#define EDEADLK		35
-#define ETIMEDOUT	110
-
 
 	.text
 
@@ -248,11 +245,11 @@ pthread_rwlock_timedwrlock:
 .Ltcboff:
 	.word	TLS_PRE_TCB_SIZE
 	.align	2
-.Lwait6:	
+.Lwait6:
 	.long	__lll_mutex_lock_wait-.Lwait6b
 .Lwake6:
 	.long	__lll_mutex_unlock_wake-.Lwake6b
-.Lwait7:	
+.Lwait7:
 	.long	__lll_mutex_lock_wait-.Lwait7b
 .Lwake7:
 	.long	__lll_mutex_unlock_wake-.Lwake7b
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S
index 20c84235ce..06d56e04cb 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S
@@ -19,15 +19,13 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <tcb-offsets.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 #define SYS_futex		240
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EAGAIN		11
-#define EDEADLK		35
-
 
 	.text
 
@@ -187,11 +185,11 @@ __pthread_rwlock_wrlock:
 .Ltcboff:
 	.word	TLS_PRE_TCB_SIZE
 	.align	2
-.Lwait4:	
+.Lwait4:
 	.long	__lll_mutex_lock_wait-.Lwait4b
 .Lwake4:
 	.long	__lll_mutex_unlock_wake-.Lwake4b
-.Lwait5:	
+.Lwait5:
 	.long	__lll_mutex_lock_wait-.Lwait5b
 .Lwake5:
 	.long	__lll_mutex_unlock_wake-.Lwake5b
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/sem_post.S b/nptl/sysdeps/unix/sysv/linux/sh/sem_post.S
index 9f33847339..90e63ed184 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/sem_post.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/sem_post.S
@@ -18,6 +18,7 @@
 
 #include <sysdep.h>
 #include <shlib-compat.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 
@@ -26,12 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EINTR			4
-#define EAGAIN			11
-#define EWOULDBLOCK		EAGAIN
-#define EINVAL			22
-#define ETIMEDOUT		110
-
 	.text
 
 	.globl	__new_sem_post
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S b/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S
index 741d66383f..b6d4d4c886 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S
@@ -18,6 +18,7 @@
 
 #include <sysdep.h>
 #include <shlib-compat.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 
@@ -26,12 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EINTR			4
-#define EAGAIN			11
-#define EWOULDBLOCK		EAGAIN
-#define EINVAL			22
-#define ETIMEDOUT		110
-
 	.text
 
 	.globl	sem_timedwait
diff --git a/nptl/sysdeps/unix/sysv/linux/sh/sem_trywait.S b/nptl/sysdeps/unix/sysv/linux/sh/sem_trywait.S
index 130536234d..c80839ef30 100644
--- a/nptl/sysdeps/unix/sysv/linux/sh/sem_trywait.S
+++ b/nptl/sysdeps/unix/sysv/linux/sh/sem_trywait.S
@@ -18,6 +18,7 @@
 
 #include <sysdep.h>
 #include <shlib-compat.h>
+#include <pthread-errnos.h>
 #include "lowlevel-atomic.h"
 
 
@@ -26,12 +27,6 @@
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
 
-#define EINTR			4
-#define EAGAIN			11
-#define EWOULDBLOCK		EAGAIN
-#define EINVAL			22
-#define ETIMEDOUT		110
-
 	.text
 
 	.globl	__new_sem_trywait