From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa1.hgst.iphmx.com (esa1.hgst.iphmx.com [68.232.141.245]) by sourceware.org (Postfix) with ESMTPS id 5738B384242C for ; Wed, 19 Aug 2020 15:48:58 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 5738B384242C IronPort-SDR: h5BMEux/NQNi/xWtnraJC7n741/ac0a15XAVJ3ItSiMq/g90vHJ+WkDiU11WGqZhFYpIGKhq1A SgkjewKajXNxJfUgNw01iOFKi0jUCKTJHhR/SzsdvIH0N838EUikEkPTeDLjNLxtkJywDmRg1V UrRxqZwkNvJOD03pNurllmV0AUAjP3X8ly6pQXUfPr9OdgZBzFYekaQ6QQpnqhRjz17DD9z7BM Y7/RHuNbMFc3VJYnL+cUJobUHDh8ifTIFqmk/9jrTSLfrQkWHS4GCdsKj6dcqMEpdUo725UNrL /+o= X-IronPort-AV: E=Sophos;i="5.76,331,1592841600"; d="scan'208";a="254766933" Received: from h199-255-45-15.hgst.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 19 Aug 2020 23:48:57 +0800 IronPort-SDR: FH4HUtHWQiIs3E9IZzbeFqozuY3mcS+UEJU60tzLKKYqks4SG9P+ZB/UtTP5uu6lqcDsYTeqMy lKdRFjnFWpzQ== Received: from uls-op-cesaip01.wdc.com ([10.248.3.36]) by uls-op-cesaep02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Aug 2020 08:35:55 -0700 IronPort-SDR: xwCWyCWYQNP5SROVXPQYX2s5K1k3OuJi4XgvM/N2bi/G3ztS3ZDATA7jOdUIy36M2x/8Aph6E1 sNgVIZ37BirQ== WDCIronportException: Internal Received: from lpt-kalia-a.ad.shared (HELO risc6-mainframe.hgst.com) ([10.86.59.58]) by uls-op-cesaip01.wdc.com with ESMTP; 19 Aug 2020 08:48:57 -0700 From: Alistair Francis To: libc-alpha@sourceware.org Cc: alistair.francis@wdc.com, alistair23@gmail.com Subject: [PATCH v5 04/17] RISC-V: Add support for 32-bit vDSO calls Date: Wed, 19 Aug 2020 08:38:49 -0700 Message-Id: <1d36bb7cfe138b6e552afc53536cf60f5d14ccd7.1597851293.git.alistair.francis@wdc.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-13.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Aug 2020 15:48:59 -0000 Reviewed-by: Maciej W. Rozycki --- sysdeps/unix/sysv/linux/riscv/sysdep.h | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/sysdeps/unix/sysv/linux/riscv/sysdep.h b/sysdeps/unix/sysv/linux/riscv/sysdep.h index 430fa23a58..e94afbf106 100644 --- a/sysdeps/unix/sysv/linux/riscv/sysdep.h +++ b/sysdeps/unix/sysv/linux/riscv/sysdep.h @@ -135,13 +135,24 @@ #else /* !__ASSEMBLER__ */ -# define VDSO_NAME "LINUX_4.15" -# define VDSO_HASH 182943605 +# if __WORDSIZE == 64 +# define VDSO_NAME "LINUX_4.15" +# define VDSO_HASH 182943605 + +/* List of system calls which are supported as vsyscalls only + for RV64. */ +# define HAVE_CLOCK_GETRES64_VSYSCALL "__vdso_clock_getres" +# define HAVE_CLOCK_GETTIME64_VSYSCALL "__vdso_clock_gettime" +# define HAVE_GETTIMEOFDAY_VSYSCALL "__vdso_gettimeofday" +# else +# define VDSO_NAME "LINUX_5.4" +# define VDSO_HASH 61765876 + +/* RV32 does not support the gettime VDSO syscalls. */ +# endif -/* List of system calls which are supported as vsyscalls. */ -# define HAVE_CLOCK_GETRES64_VSYSCALL "__vdso_clock_getres" -# define HAVE_CLOCK_GETTIME64_VSYSCALL "__vdso_clock_gettime" -# define HAVE_GETTIMEOFDAY_VSYSCALL "__vdso_gettimeofday" +/* List of system calls which are supported as vsyscalls (for RV32 and + RV64). */ # define HAVE_GETCPU_VSYSCALL "__vdso_getcpu" # define INTERNAL_SYSCALL(name, nr, args...) \ -- 2.28.0