[PATCH] provide y2038 safe socket constants

2020-03-28 Thread Vineet Gupta
These will be used by upcoming RV32 and ARC ports and any future ports

Signed-off-by: Vineet Gupta 
---
 sysdeps/unix/sysv/linux/bits/socket-constants.h | 14 --
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/sysdeps/unix/sysv/linux/bits/socket-constants.h 
b/sysdeps/unix/sysv/linux/bits/socket-constants.h
index 9dcc19cd5380..8a48ae7d0ca2 100644
--- a/sysdeps/unix/sysv/linux/bits/socket-constants.h
+++ b/sysdeps/unix/sysv/linux/bits/socket-constants.h
@@ -20,6 +20,8 @@
 # error "Never include  directly; use  
instead."
 #endif
 
+#include 
+
 #define SOL_SOCKET 1
 #define SO_ACCEPTCONN 30
 #define SO_BROADCAST 6
@@ -30,9 +32,17 @@
 #define SO_OOBINLINE 10
 #define SO_RCVBUF 8
 #define SO_RCVLOWAT 18
-#define SO_RCVTIMEO 20
+#if __TIMESIZE == 64 && __WORDSIZE == 32
+# define SO_RCVTIMEO 66
+#else
+# define SO_RCVTIMEO 20
+#endif
 #define SO_REUSEADDR 2
 #define SO_SNDBUF 7
 #define SO_SNDLOWAT 19
-#define SO_SNDTIMEO 21
+#if __TIMESIZE == 64 && __WORDSIZE == 32
+# define SO_SNDTIMEO 67
+#else
+# define SO_SNDTIMEO 21
+#endif
 #define SO_TYPE 3
-- 
2.20.1


___
linux-snps-arc mailing list
linux-snps-arc@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-snps-arc


[PATCH] [ARC] Allow more ABIs in GLIBC_DYNAMIC_LINKER

2020-03-28 Thread Vineet Gupta
Enable big-endian suffixed dynamic linker per glibc multi-abi support.

And to avoid a future churn and version pairingi hassles, also allow
arc700 although glibc for ARC currently doesn't support it.

gcc/
-xx-xx  Vineet Gupta 
+
+   * config/arc/linux.h: GLIBC_DYNAMIC_LINKER support BE/arc700

Signed-off-by: Vineet Gupta 
---
 gcc/ChangeLog  | 4 
 gcc/config/arc/linux.h | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 86ad683a6cb0..c26a748fd51b 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2020-03-28  Vineet Gupta 
+
+   * config/arc/linux.h: GLIBC_DYNAMIC_LINKER support BE/arc700
+
 2020-03-28  Jakub Jelinek  
 
PR c/93573
diff --git a/gcc/config/arc/linux.h b/gcc/config/arc/linux.h
index 0b99da3fcdaf..1bbeccee7115 100644
--- a/gcc/config/arc/linux.h
+++ b/gcc/config/arc/linux.h
@@ -29,7 +29,7 @@ along with GCC; see the file COPYING3.  If not see
 }  \
   while (0)
 
-#define GLIBC_DYNAMIC_LINKER   "/lib/ld-linux-arc.so.2"
+#define GLIBC_DYNAMIC_LINKER   
"/lib/ld-linux-arc%{mbig-endian:eb}%{mcpu=arc700:700}.so.2"
 #define UCLIBC_DYNAMIC_LINKER  "/lib/ld-uClibc.so.0"
 
 /* Note that the default is to link against dynamic libraries, if they are
-- 
2.20.1


___
linux-snps-arc mailing list
linux-snps-arc@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-snps-arc