unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Alistair Francis <alistair.francis@wdc.com>
To: libc-alpha@sourceware.org
Cc: arnd@arndb.de, adhemerval.zanella@linaro.org, fweimer@redhat.com,
	palmer@sifive.com, macro@wdc.com, zongbox@gmail.com,
	alistair.francis@wdc.com, alistair23@gmail.com
Subject: [RFC v5 11/21] RISC-V: Define __NR_* as __NR_*_time64/64 for 32-bit
Date: Thu, 29 Aug 2019 09:50:29 -0700	[thread overview]
Message-ID: <21b59d7e48e05d1ce3f6e7c3c0c6063adb20a6b0.1567097252.git.alistair.francis@wdc.com> (raw)
In-Reply-To: <cover.1567097252.git.alistair.francis@wdc.com>

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>

	* sysdeps/unix/sysv/linux/riscv/sysdep.h: Define __NR_* as
	__NR_*_time64/64 for 32-bit.
---
 sysdeps/unix/sysv/linux/riscv/sysdep.h | 73 ++++++++++++++++++++++++++
 1 file changed, 73 insertions(+)

diff --git a/sysdeps/unix/sysv/linux/riscv/sysdep.h b/sysdeps/unix/sysv/linux/riscv/sysdep.h
index 5470ea3d2a6..169d4152ccd 100644
--- a/sysdeps/unix/sysv/linux/riscv/sysdep.h
+++ b/sysdeps/unix/sysv/linux/riscv/sysdep.h
@@ -116,6 +116,79 @@
 
 #include <sysdeps/unix/sysdep.h>
 
+#if __riscv_xlen == 32
+/* Define the __NR_futex as __NR_futex64 as RV32 doesn't have a
+ * __NR_futex syscall.
+ */
+# ifndef __NR_futex
+#  define __NR_futex __NR_futex_time64
+# endif
+
+# ifndef __NR_rt_sigtimedwait
+#  define __NR_rt_sigtimedwait __NR_rt_sigtimedwait_time64
+# endif
+
+# ifndef __NR_ppoll
+#  define __NR_ppoll __NR_ppoll_time64
+# endif
+
+# ifndef __NR_utimensat
+#  define __NR_utimensat __NR_utimensat_time64
+# endif
+
+# ifndef __NR_pselect6
+#  define __NR_pselect6 __NR_pselect6_time64
+# endif
+
+# ifndef __NR_recvmmsg
+#  define __NR_recvmmsg __NR_recvmmsg_time64
+# endif
+
+# ifndef __NR_semtimedop
+#  define __NR_semtimedop __NR_semtimedop_time64
+# endif
+
+# ifndef __NR_mq_timedreceive
+#  define __NR_mq_timedreceive __NR_mq_timedreceive_time64
+# endif
+
+# ifndef __NR_mq_timedsend
+#  define __NR_mq_timedsend __NR_mq_timedsend_time64
+# endif
+
+# ifndef __NR_timer_gettime
+#  define __NR_timer_gettime __NR_timer_gettime64
+# endif
+
+# ifndef __NR_timer_settime
+#  define __NR_timer_settime __NR_timer_settime64
+# endif
+
+# ifndef __NR_clock_getres
+#  define __NR_clock_getres __NR_clock_getres_time64
+# endif
+
+# ifndef __NR_clock_gettime
+#  define __NR_clock_gettime __NR_clock_gettime64
+# endif
+
+# ifndef __NR_timerfd_settime
+#  define __NR_timerfd_settime __NR_timerfd_settime64
+# endif
+
+# ifndef __NR_timerfd_gettime
+#  define __NR_timerfd_gettime __NR_timerfd_gettime64
+# endif
+
+# ifndef __NR_sched_rr_get_interval
+#  define __NR_sched_rr_get_interval __NR_sched_rr_get_interval_time64
+# endif
+
+# ifndef __NR_clock_adjtime
+#  define __NR_clock_adjtime __NR_clock_adjtime64
+# endif
+#endif /* __riscv_xlen == 32 */
+
 #undef SYS_ify
 #define SYS_ify(syscall_name)	__NR_##syscall_name
 
-- 
2.22.0


  parent reply	other threads:[~2019-08-29 16:55 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-29 16:50 [RFC v5 00/21] RISC-V glibc port for the 32-bit Alistair Francis
2019-08-29 16:50 ` [RFC v5 01/21] sunrpc/clnt_udp: Ensure total_deadline is initalised Alistair Francis
2019-08-29 17:22   ` Joseph Myers
2019-08-29 17:34     ` Zack Weinberg
2019-09-05 14:53       ` Alistair Francis
2019-09-05 15:02         ` Joseph Myers
2019-09-05 15:06           ` Jeff Law
2019-09-05 15:21             ` Joseph Myers
2019-09-05 15:27               ` Jeff Law
2019-09-06  0:47               ` Alistair Francis
2019-09-05 15:12           ` Zack Weinberg
2019-09-06  0:46           ` Alistair Francis
2019-09-06  1:31             ` Jeff Law
2019-09-16 21:36               ` Alistair Francis
2019-09-05 15:07         ` Zack Weinberg
2019-08-29 16:50 ` [RFC v5 02/21] sysdeps/nanosleep: Use clock_nanosleep_time64 if avaliable Alistair Francis
2019-08-29 17:25   ` Joseph Myers
2019-08-30 17:40     ` Alistair Francis
2019-10-14 13:59   ` Lukasz Majewski
2019-10-15  0:06     ` Alistair Francis
2019-10-15 15:54       ` Lukasz Majewski
2019-10-15 22:28         ` Alistair Francis
2019-10-16 23:42           ` Alistair Francis
2019-10-17  0:08             ` Alistair Francis
2019-08-29 16:50 ` [RFC v5 03/21] sysdeps/gettimeofday: Use clock_gettime64 " Alistair Francis
2019-08-29 16:50 ` [RFC v5 04/21] sysdeps/wait: Use waitid " Alistair Francis
2019-08-29 16:50 ` [RFC v5 05/21] sysdeps/clock_gettime: Use clock_gettime64 " Alistair Francis
2019-10-29 12:00   ` Lukasz Majewski
2019-08-29 16:50 ` [RFC v5 06/21] sysdeps/timespec_get: " Alistair Francis
2019-08-29 16:50 ` [RFC v5 07/21] sysdeps/stat: Handle 64-bit ino_t types on 32-bit hosts Alistair Francis
2019-08-29 16:50 ` [RFC v5 08/21] sysdeps/statfs: " Alistair Francis
2019-08-29 16:50 ` [RFC v5 09/21] Documentation for the RISC-V 32-bit port Alistair Francis
2019-08-29 16:50 ` [RFC v5 10/21] RISC-V: Use 64-bit time_t and off_t for RV32 and RV64 Alistair Francis
2019-08-29 16:50 ` Alistair Francis [this message]
2019-08-29 16:50 ` [RFC v5 12/21] RISC-V: Use 64-bit timespec in clock_gettime vdso calls Alistair Francis
2019-08-29 16:50 ` [RFC v5 13/21] RISC-V: Support dynamic loader for the 32-bit Alistair Francis
2019-08-29 16:50 ` [RFC v5 14/21] RISC-V: Add path of library directories for RV32 Alistair Francis
2019-08-29 16:50 ` [RFC v5 15/21] RISC-V: The ABI implementation for the 32-bit Alistair Francis
2019-08-29 16:50 ` [RFC v5 16/21] RISC-V: Hard float support for the 32 bit Alistair Francis
2019-08-29 16:50 ` [RFC v5 17/21] RISC-V: Add ABI lists Alistair Francis
2019-08-29 16:50 ` [RFC v5 18/21] RISC-V: Build Infastructure for the 32-bit Alistair Francis
2019-08-29 16:50 ` [RFC v5 19/21] RISC-V: Fix llrint and llround missing exceptions on RV32 Alistair Francis
2019-08-29 16:50 ` [RFC v5 20/21] RISC-V: Use 64-bit vdso syscalls for RV32 Alistair Francis
2019-08-29 16:50 ` [RFC v5 21/21] Add RISC-V 32-bit target to build-many-glibcs.py Alistair Francis
2019-08-29 17:28 ` [RFC v5 00/21] RISC-V glibc port for the 32-bit Joseph Myers
2019-08-29 17:42   ` Alistair Francis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/libc/involved.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=21b59d7e48e05d1ce3f6e7c3c0c6063adb20a6b0.1567097252.git.alistair.francis@wdc.com \
    --to=alistair.francis@wdc.com \
    --cc=adhemerval.zanella@linaro.org \
    --cc=alistair23@gmail.com \
    --cc=arnd@arndb.de \
    --cc=fweimer@redhat.com \
    --cc=libc-alpha@sourceware.org \
    --cc=macro@wdc.com \
    --cc=palmer@sifive.com \
    --cc=zongbox@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).