Skip to content

Commit ec00b51

Browse files
dillonaRiku Voipio
authored and
Riku Voipio
committed
linux-user: Add Alpha socket constants
Without these, some networking programs will not work Signed-off-by: Dillon Amburgey <dillona@dillona.com> Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
1 parent fa38891 commit ec00b51

File tree

1 file changed

+69
-0
lines changed

1 file changed

+69
-0
lines changed

linux-user/socket.h

+69
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,75 @@
8787

8888
#define TARGET_SOCK_MAX (SOCK_PACKET + 1)
8989

90+
#elif defined(TARGET_ALPHA)
91+
92+
/* For setsockopt(2) */
93+
#define TARGET_SOL_SOCKET 0xffff
94+
95+
#define TARGET_SO_DEBUG 0x0001
96+
#define TARGET_SO_REUSEADDR 0x0004
97+
#define TARGET_SO_KEEPALIVE 0x0008
98+
#define TARGET_SO_DONTROUTE 0x0010
99+
#define TARGET_SO_BROADCAST 0x0020
100+
#define TARGET_SO_LINGER 0x0080
101+
#define TARGET_SO_OOBINLINE 0x0100
102+
/* To add :#define TARGET_SO_REUSEPORT 0x0200 */
103+
104+
#define TARGET_SO_TYPE 0x1008
105+
#define TARGET_SO_ERROR 0x1007
106+
#define TARGET_SO_SNDBUF 0x1001
107+
#define TARGET_SO_RCVBUF 0x1002
108+
#define TARGET_SO_SNDBUFFORCE 0x100a
109+
#define TARGET_SO_RCVBUFFORCE 0x100b
110+
#define TARGET_SO_RCVLOWAT 0x1010
111+
#define TARGET_SO_SNDLOWAT 0x1011
112+
#define TARGET_SO_RCVTIMEO 0x1012
113+
#define TARGET_SO_SNDTIMEO 0x1013
114+
#define TARGET_SO_ACCEPTCONN 0x1014
115+
#define TARGET_SO_PROTOCOL 0x1028
116+
#define TARGET_SO_DOMAIN 0x1029
117+
118+
/* linux-specific, might as well be the same as on i386 */
119+
#define TARGET_SO_NO_CHECK 11
120+
#define TARGET_SO_PRIORITY 12
121+
#define TARGET_SO_BSDCOMPAT 14
122+
123+
#define TARGET_SO_PASSCRED 17
124+
#define TARGET_SO_PEERCRED 18
125+
#define TARGET_SO_BINDTODEVICE 25
126+
127+
/* Socket filtering */
128+
#define TARGET_SO_ATTACH_FILTER 26
129+
#define TARGET_SO_DETACH_FILTER 27
130+
131+
#define TARGET_SO_PEERNAME 28
132+
#define TARGET_SO_TIMESTAMP 29
133+
#define TARGET_SCM_TIMESTAMP TARGET_SO_TIMESTAMP
134+
135+
#define TARGET_SO_PEERSEC 30
136+
#define TARGET_SO_PASSSEC 34
137+
#define TARGET_SO_TIMESTAMPNS 35
138+
#define TARGET_SCM_TIMESTAMPNS TARGET_SO_TIMESTAMPNS
139+
140+
/* Security levels - as per NRL IPv6 - don't actually do anything */
141+
#define TARGET_SO_SECURITY_AUTHENTICATION 19
142+
#define TARGET_SO_SECURITY_ENCRYPTION_TRANSPORT 20
143+
#define TARGET_SO_SECURITY_ENCRYPTION_NETWORK 21
144+
145+
#define TARGET_SO_MARK 36
146+
147+
#define TARGET_SO_TIMESTAMPING 37
148+
#define TARGET_SCM_TIMESTAMPING TARGET_SO_TIMESTAMPING
149+
150+
#define TARGET_SO_RXQ_OVFL 40
151+
152+
#define TARGET_SO_WIFI_STATUS 41
153+
#define TARGET_SCM_WIFI_STATUS TARGET_SO_WIFI_STATUS
154+
#define TARGET_SO_PEEK_OFF 42
155+
156+
/* Instruct lower device to use last 4-bytes of skb data as FCS */
157+
#define TARGET_SO_NOFCS 43
158+
90159
#else
91160

92161
/* For setsockopt(2) */

0 commit comments

Comments
 (0)