summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2019-10-31 16:48:30 -0400
committerRich Felker <dalias@aerifal.cx>2019-11-02 18:30:56 -0400
commit0bbc04c98115440d15a51d6b2ba087ea79c56ad9 (patch)
treea715706ca7dd2651e6db8f2e71611e69d99d6947 /include
parentde90f38e3b105802655d19d965d66335d25d59ef (diff)
downloadmusl-0bbc04c98115440d15a51d6b2ba087ea79c56ad9.tar.gz
make time-related socket options overridable by arch bits files
SO_RCVTIMEO and SO_SNDTIMEO already were, but only in aggregate with SO_DEBUG and all of the other low/traditional options that varied per arch. SO_TIMESTAMP* are newly overridable. the two groups have to be done separately since mips64 and powerpc64 will override the former but not the latter. at some point this should be cleaned up to use bits headers more idiomatically.
Diffstat (limited to 'include')
-rw-r--r--include/sys/socket.h17
1 files changed, 11 insertions, 6 deletions
diff --git a/include/sys/socket.h b/include/sys/socket.h
index 318a98ef..6be699d9 100644
--- a/include/sys/socket.h
+++ b/include/sys/socket.h
@@ -182,8 +182,6 @@ struct linger {
#define SO_PEERCRED 17
#define SO_RCVLOWAT 18
#define SO_SNDLOWAT 19
-#define SO_RCVTIMEO 20
-#define SO_SNDTIMEO 21
#define SO_ACCEPTCONN 30
#define SO_PEERSEC 31
#define SO_SNDBUFFORCE 32
@@ -192,6 +190,17 @@ struct linger {
#define SO_DOMAIN 39
#endif
+#ifndef SO_RCVTIMEO
+#define SO_RCVTIMEO 20
+#define SO_SNDTIMEO 21
+#endif
+
+#ifndef SO_TIMESTAMP
+#define SO_TIMESTAMP 29
+#define SO_TIMESTAMPNS 35
+#define SO_TIMESTAMPING 37
+#endif
+
#define SO_SECURITY_AUTHENTICATION 22
#define SO_SECURITY_ENCRYPTION_TRANSPORT 23
#define SO_SECURITY_ENCRYPTION_NETWORK 24
@@ -203,14 +212,10 @@ struct linger {
#define SO_GET_FILTER SO_ATTACH_FILTER
#define SO_PEERNAME 28
-#define SO_TIMESTAMP 29
#define SCM_TIMESTAMP SO_TIMESTAMP
-
#define SO_PASSSEC 34
-#define SO_TIMESTAMPNS 35
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
#define SO_MARK 36
-#define SO_TIMESTAMPING 37
#define SCM_TIMESTAMPING SO_TIMESTAMPING
#define SO_RXQ_OVFL 40
#define SO_WIFI_STATUS 41