summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/include
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-07-06 17:40:34 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-09-11 14:42:05 -0300
commit7c437d37789939a1411da0c04f748384bc5aee59 (patch)
tree0238e47aced2d9c22ca97457f8773dbd4c500ac2 /sysdeps/unix/sysv/linux/include
parent60a2e28b34b41e1a4e50feec7b38e068c9e33eec (diff)
downloadglibc-7c437d37789939a1411da0c04f748384bc5aee59.tar.gz
glibc-7c437d37789939a1411da0c04f748384bc5aee59.tar.xz
glibc-7c437d37789939a1411da0c04f748384bc5aee59.zip
linux: Add time64 semtimedop support
Either the __NR_semtimedop_time64 (for 32-bit) or the __NR_semtimedop
(for 64-bit) syscall is used as default.  The 32-bit fallback is used
iff __ASSUME_TIME64_SYSCALLS is not defined, which assumes the kernel
ABI provides either __NR_ipc or __NR_semtimeop (for 32-bit time_t).

Checked on x86_64-linux-gnu and i686-linux-gnu (on 5.4 and on 4.15
kernel).

Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Diffstat (limited to 'sysdeps/unix/sysv/linux/include')
-rw-r--r--sysdeps/unix/sysv/linux/include/sys/sem.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/include/sys/sem.h b/sysdeps/unix/sysv/linux/include/sys/sem.h
index a9151e057d..f369c6b6d3 100644
--- a/sysdeps/unix/sysv/linux/include/sys/sem.h
+++ b/sysdeps/unix/sysv/linux/include/sys/sem.h
@@ -7,9 +7,15 @@ __typeof__ (semtimedop) __semtimedop attribute_hidden;
 
 #if __TIMESIZE == 64
 # define __semctl64 __semctl
+# define __semtimedop64 __semtimedop
 #else
+# include <struct___timespec64.h>
+
 extern int __semctl64 (int semid, int semnum, int cmd, ...);
 libc_hidden_proto (__semctl64);
+extern int __semtimedop64 (int semid, struct sembuf *sops, size_t nsops,
+			   const struct __timespec64 *tmo);
+libc_hidden_proto (__semtimedop64);
 #endif
 
 # endif