remove unnecessary sock_type enum and other unused surrounding code to
allow for per arch sockbits to mirror better linux headers for maintenance
Signed-off-by: Carlo Marcelo Arenas Belón
---
linux-user/alpha/sockbits.h | 36
linux-user/hppa/sockbits.h | 30 ---
linux-user/mips/sockbits.h | 35 ---
linux-user/socket.h | 58 ++---
linux-user/sparc/sockbits.h | 35 ---
5 files changed, 29 insertions(+), 165 deletions(-)
diff --git a/linux-user/alpha/sockbits.h b/linux-user/alpha/sockbits.h
index 768579a1f7..defdb806ea 100644
--- a/linux-user/alpha/sockbits.h
+++ b/linux-user/alpha/sockbits.h
@@ -66,39 +66,3 @@
#define TARGET_SCM_TIMESTAMPING_PKTINFO 58
#define TARGET_SO_PEERGROUPS59
#define TARGET_SO_ZEROCOPY 60
-
-/** sock_type - Socket types
- *
- * Please notice that for binary compat reasons ALPHA has to
- * override the enum sock_type in include/linux/net.h, so
- * we define ARCH_HAS_SOCKET_TYPES here.
- *
- * @SOCK_STREAM - stream (connection) socket
- * @SOCK_DGRAM - datagram (conn.less) socket
- * @SOCK_RAW - raw socket
- * @SOCK_RDM - reliably-delivered message
- * @SOCK_SEQPACKET - sequential packet socket
- * @SOCK_DCCP - Datagram Congestion Control Protocol socket
- * @SOCK_PACKET - linux specific way of getting packets at the dev level.
- *For writing rarp and other similar things on the user
- *level.
- * @SOCK_CLOEXEC - sets the close-on-exec (FD_CLOEXEC) flag.
- * @SOCK_NONBLOCK - sets the O_NONBLOCK file status flag.
- */
-
-enum sock_type {
-TARGET_SOCK_STREAM = 1,
-TARGET_SOCK_DGRAM = 2,
-TARGET_SOCK_RAW = 3,
-TARGET_SOCK_RDM = 4,
-TARGET_SOCK_SEQPACKET = 5,
-TARGET_SOCK_DCCP= 6,
-TARGET_SOCK_PACKET = 10,
-TARGET_SOCK_CLOEXEC = 01000,
-TARGET_SOCK_NONBLOCK= 0x4000,
-};
-
-#define TARGET_SOCK_MAX (TARGET_SOCK_PACKET + 1)
-#define TARGET_SOCK_TYPE_MASK 0xf /* Covers up to TARGET_SOCK_MAX - 1. */
-
-#define ARCH_HAS_SOCKET_TYPES 1
diff --git a/linux-user/hppa/sockbits.h b/linux-user/hppa/sockbits.h
index 3dab31a76a..32f81357d6 100644
--- a/linux-user/hppa/sockbits.h
+++ b/linux-user/hppa/sockbits.h
@@ -71,33 +71,3 @@
#define TARGET_SO_PEERGROUPS0x4034
#define TARGET_SO_ZEROCOPY 0x4035
-/** sock_type - Socket types - default values
- *
- * @SOCK_STREAM - stream (connection) socket
- * @SOCK_DGRAM - datagram (conn.less) socket
- * @SOCK_RAW - raw socket
- * @SOCK_RDM - reliably-delivered message
- * @SOCK_SEQPACKET - sequential packet socket
- * @SOCK_DCCP - Datagram Congestion Control Protocol socket
- * @SOCK_PACKET - linux specific way of getting packets at the dev level.
- *For writing rarp and other similar things on the user
- *level.
- * @SOCK_CLOEXEC - sets the close-on-exec (FD_CLOEXEC) flag.
- * @SOCK_NONBLOCK - sets the O_NONBLOCK file status flag.
- */
-enum sock_type {
-TARGET_SOCK_STREAM= 1,
-TARGET_SOCK_DGRAM = 2,
-TARGET_SOCK_RAW = 3,
-TARGET_SOCK_RDM = 4,
-TARGET_SOCK_SEQPACKET = 5,
-TARGET_SOCK_DCCP = 6,
-TARGET_SOCK_PACKET= 10,
-TARGET_SOCK_CLOEXEC = 01000,
-TARGET_SOCK_NONBLOCK = 0x4000,
-};
-
-#define TARGET_SOCK_MAX (TARGET_SOCK_PACKET + 1)
-#define TARGET_SOCK_TYPE_MASK 0xf /* Covers up to TARGET_SOCK_MAX - 1. */
-
-#define ARCH_HAS_SOCKET_TYPES 1
diff --git a/linux-user/mips/sockbits.h b/linux-user/mips/sockbits.h
index 6d8ea8aba2..fa8062391d 100644
--- a/linux-user/mips/sockbits.h
+++ b/linux-user/mips/sockbits.h
@@ -70,38 +70,3 @@
#define TARGET_SCM_TIMESTAMPING_PKTINFO 58
#define TARGET_SO_PEERGROUPS59
#define TARGET_SO_ZEROCOPY 60
-
-/** sock_type - Socket types
- *
- * Please notice that for binary compat reasons MIPS has to
- * override the enum sock_type in include/linux/net.h, so
- * we define ARCH_HAS_SOCKET_TYPES here.
- *
- * @SOCK_DGRAM - datagram (conn.less) socket
- * @SOCK_STREAM - stream (connection) socket
- * @SOCK_RAW - raw socket
- * @SOCK_RDM - reliably-delivered message
- * @SOCK_SEQPACKET - sequential packet socket
- * @SOCK_DCCP - Datagram Congestion Control Protocol socket
- * @SOCK_PACKET - linux specific way of getting packets at the dev level.
- *For writing rarp and other similar things on the user
- *level.
- * @SOCK_CLOEXEC - sets the close-on-exec (FD_CLOEXEC) flag.
- * @SOCK_NONBLOCK - sets the O_NONBLOCK file status flag.
- */
-enum sock_type {
-TARGET_SOCK_DGRAM = 1,
-TARGET_SOCK_STREAM = 2,
-TARGET_SOCK_RAW = 3,
-TARGET_SOCK_RDM = 4,
-TARGET_SOCK_SEQPACKET = 5,
-TARGET_SOCK_DCCP= 6,
-