From dac0f7723437aa52232eb98500be1608b32fc657 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Fri, 14 Feb 2003 06:11:21 +0000 Subject: Update. 2003-02-13 Jakub Jelinek * sysdeps/alpha/dl-machine.h (elf_machine_rela): Add instead of subtracting map->l_tls_offset. --- nptl/sysdeps/s390/tls.h | 8 ++++---- nptl/sysdeps/unix/sysv/linux/s390/jmp-unwind.c | 2 +- nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.c | 1 + nptl/sysdeps/unix/sysv/linux/s390/sem_post.c | 9 ++++++++- 4 files changed, 14 insertions(+), 6 deletions(-) (limited to 'nptl/sysdeps') diff --git a/nptl/sysdeps/s390/tls.h b/nptl/sysdeps/s390/tls.h index fd43564..9b186f6 100644 --- a/nptl/sysdeps/s390/tls.h +++ b/nptl/sysdeps/s390/tls.h @@ -136,13 +136,13 @@ typedef struct /* Access to data in the thread descriptor is easy. */ #define THREAD_GETMEM(descr, member) \ - THREAD_SELF->member + descr->member #define THREAD_GETMEM_NC(descr, member, idx) \ - THREAD_SELF->member[idx] + descr->member[idx] #define THREAD_SETMEM(descr, member, value) \ - THREAD_SELF->member = (value) + descr->member = (value) #define THREAD_SETMEM_NC(descr, member, idx, value) \ - THREAD_SELF->member[idx] = (value) + descr->member[idx] = (value) #endif /* __ASSEMBLER__ */ diff --git a/nptl/sysdeps/unix/sysv/linux/s390/jmp-unwind.c b/nptl/sysdeps/unix/sysv/linux/s390/jmp-unwind.c index e41c12f..3e81475 100644 --- a/nptl/sysdeps/unix/sysv/linux/s390/jmp-unwind.c +++ b/nptl/sysdeps/unix/sysv/linux/s390/jmp-unwind.c @@ -34,7 +34,7 @@ _longjmp_unwind (jmp_buf env, int val) # define fptr __pthread_cleanup_upto #endif - unsigned int local_var; + unsigned char local_var; if (fptr != NULL) fptr (env, &local_var); diff --git a/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.c b/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.c index 42ed830..bc501c7 100644 --- a/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.c +++ b/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.c @@ -20,6 +20,7 @@ #include #include #include +#include void diff --git a/nptl/sysdeps/unix/sysv/linux/s390/sem_post.c b/nptl/sysdeps/unix/sysv/linux/s390/sem_post.c index 4c26857..df64c03 100644 --- a/nptl/sysdeps/unix/sysv/linux/s390/sem_post.c +++ b/nptl/sysdeps/unix/sysv/linux/s390/sem_post.c @@ -30,9 +30,16 @@ __new_sem_post (sem_t *sem) { int oldval; int newval; + int err; lll_compare_and_swap ((int *) sem, oldval, newval, "lr %2,%1; ahi %2,1"); - lll_futex_wake ((int *) sem, newval); + err = lll_futex_wake(((int *) sem), newval); + if (err != 0) + { + __set_errno(-err); + return -1; + } + return 0; } versioned_symbol (libpthread, __new_sem_post, sem_post, GLIBC_2_1); #if SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1) -- cgit v1.1