From 48591e2a259d84247ae38f050bd58e6f7450bb77 Mon Sep 17 00:00:00 2001 From: Dmitry Chestnykh Date: Fri, 12 Apr 2024 19:27:50 +0300 Subject: Provide fixups for riscv32. - Use TIME64 by default for rv32, usage of 32-bit time leads to a lot of incompatibilities with linux kernel 6.6.x and later versions. - Add some other corrections to use proper system calls on riscv32 platform. Signed-off-by: Dmitry Chestnykh --- libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c') diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c b/libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c index 60f2a724c..8c828fbb1 100644 --- a/libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c +++ b/libpthread/nptl/sysdeps/unix/sysv/linux/timer_routines.c @@ -90,8 +90,13 @@ timer_helper_thread (void *arg) /* XXX The size argument hopefully will have to be changed to the real size of the user-level sigset_t. */ +#if defined(__NR_rt_sigtimedwait_time64) && defined(__UCLIBC_USE_TIME64__) + int result = INLINE_SYSCALL (rt_sigtimedwait_time64, 4, &ss, &si, NULL, + _NSIG / 8); +#else int result = INLINE_SYSCALL (rt_sigtimedwait, 4, &ss, &si, NULL, _NSIG / 8); +#endif LIBC_CANCEL_RESET (oldtype); -- cgit v1.2.3