Source file
src/syscall/types_linux.go
1
2
3
4
5
6
7
10
11
12
13
14 package syscall
15
16
138 import "C"
139
140
141
142 const (
143 sizeofPtr = C.sizeofPtr
144 sizeofShort = C.sizeof_short
145 sizeofInt = C.sizeof_int
146 sizeofLong = C.sizeof_long
147 sizeofLongLong = C.sizeof_longlong
148 PathMax = C.PATH_MAX
149 )
150
151
152
153 type (
154 _C_short C.short
155 _C_int C.int
156 _C_long C.long
157 _C_long_long C.longlong
158 )
159
160
161
162 type Timespec C.struct_timespec
163
164 type Timeval C.struct_timeval
165
166 type Timex C.struct_timex
167
168 type Time_t C.time_t
169
170 type Tms C.struct_tms
171
172 type Utimbuf C.struct_utimbuf
173
174
175
176 type Rusage C.struct_rusage
177
178 type Rlimit C.struct_rlimit
179
180 type _Gid_t C.gid_t
181
182
183
184 type Stat_t C.struct_stat
185
186 type Statfs_t C.struct_statfs
187
188 type Dirent C.struct_dirent
189
190 type Fsid C.fsid_t
191
192 type Flock_t C.struct_flock
193
194
195
196 type RawSockaddrInet4 C.struct_sockaddr_in
197
198 type RawSockaddrInet6 C.struct_sockaddr_in6
199
200 type RawSockaddrUnix C.struct_my_sockaddr_un
201
202 type RawSockaddrLinklayer C.struct_sockaddr_ll
203
204 type RawSockaddrNetlink C.struct_sockaddr_nl
205
206 type RawSockaddr C.struct_sockaddr
207
208 type RawSockaddrAny C.struct_sockaddr_any
209
210 type _Socklen C.socklen_t
211
212 type Linger C.struct_linger
213
214 type Iovec C.struct_iovec
215
216 type IPMreq C.struct_ip_mreq
217
218 type IPMreqn C.struct_ip_mreqn
219
220 type IPv6Mreq C.struct_ipv6_mreq
221
222 type Msghdr C.struct_msghdr
223
224 type Cmsghdr C.struct_cmsghdr
225
226 type Inet4Pktinfo C.struct_in_pktinfo
227
228 type Inet6Pktinfo C.struct_in6_pktinfo
229
230 type IPv6MTUInfo C.struct_ip6_mtuinfo
231
232 type ICMPv6Filter C.struct_icmp6_filter
233
234 type Ucred C.struct_ucred
235
236 type TCPInfo C.struct_tcp_info
237
238 const (
239 SizeofSockaddrInet4 = C.sizeof_struct_sockaddr_in
240 SizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6
241 SizeofSockaddrAny = C.sizeof_struct_sockaddr_any
242 SizeofSockaddrUnix = C.sizeof_struct_sockaddr_un
243 SizeofSockaddrLinklayer = C.sizeof_struct_sockaddr_ll
244 SizeofSockaddrNetlink = C.sizeof_struct_sockaddr_nl
245 SizeofLinger = C.sizeof_struct_linger
246 SizeofIPMreq = C.sizeof_struct_ip_mreq
247 SizeofIPMreqn = C.sizeof_struct_ip_mreqn
248 SizeofIPv6Mreq = C.sizeof_struct_ipv6_mreq
249 SizeofMsghdr = C.sizeof_struct_msghdr
250 SizeofCmsghdr = C.sizeof_struct_cmsghdr
251 SizeofInet4Pktinfo = C.sizeof_struct_in_pktinfo
252 SizeofInet6Pktinfo = C.sizeof_struct_in6_pktinfo
253 SizeofIPv6MTUInfo = C.sizeof_struct_ip6_mtuinfo
254 SizeofICMPv6Filter = C.sizeof_struct_icmp6_filter
255 SizeofUcred = C.sizeof_struct_ucred
256 SizeofTCPInfo = C.sizeof_struct_tcp_info
257 )
258
259
260
261 const (
262 IFA_UNSPEC = C.IFA_UNSPEC
263 IFA_ADDRESS = C.IFA_ADDRESS
264 IFA_LOCAL = C.IFA_LOCAL
265 IFA_LABEL = C.IFA_LABEL
266 IFA_BROADCAST = C.IFA_BROADCAST
267 IFA_ANYCAST = C.IFA_ANYCAST
268 IFA_CACHEINFO = C.IFA_CACHEINFO
269 IFA_MULTICAST = C.IFA_MULTICAST
270 IFLA_UNSPEC = C.IFLA_UNSPEC
271 IFLA_ADDRESS = C.IFLA_ADDRESS
272 IFLA_BROADCAST = C.IFLA_BROADCAST
273 IFLA_IFNAME = C.IFLA_IFNAME
274 IFLA_MTU = C.IFLA_MTU
275 IFLA_LINK = C.IFLA_LINK
276 IFLA_QDISC = C.IFLA_QDISC
277 IFLA_STATS = C.IFLA_STATS
278 IFLA_COST = C.IFLA_COST
279 IFLA_PRIORITY = C.IFLA_PRIORITY
280 IFLA_MASTER = C.IFLA_MASTER
281 IFLA_WIRELESS = C.IFLA_WIRELESS
282 IFLA_PROTINFO = C.IFLA_PROTINFO
283 IFLA_TXQLEN = C.IFLA_TXQLEN
284 IFLA_MAP = C.IFLA_MAP
285 IFLA_WEIGHT = C.IFLA_WEIGHT
286 IFLA_OPERSTATE = C.IFLA_OPERSTATE
287 IFLA_LINKMODE = C.IFLA_LINKMODE
288 IFLA_LINKINFO = C.IFLA_LINKINFO
289 IFLA_NET_NS_PID = C.IFLA_NET_NS_PID
290 IFLA_IFALIAS = C.IFLA_IFALIAS
291 IFLA_MAX = C.IFLA_MAX
292 RT_SCOPE_UNIVERSE = C.RT_SCOPE_UNIVERSE
293 RT_SCOPE_SITE = C.RT_SCOPE_SITE
294 RT_SCOPE_LINK = C.RT_SCOPE_LINK
295 RT_SCOPE_HOST = C.RT_SCOPE_HOST
296 RT_SCOPE_NOWHERE = C.RT_SCOPE_NOWHERE
297 RT_TABLE_UNSPEC = C.RT_TABLE_UNSPEC
298 RT_TABLE_COMPAT = C.RT_TABLE_COMPAT
299 RT_TABLE_DEFAULT = C.RT_TABLE_DEFAULT
300 RT_TABLE_MAIN = C.RT_TABLE_MAIN
301 RT_TABLE_LOCAL = C.RT_TABLE_LOCAL
302 RT_TABLE_MAX = C.RT_TABLE_MAX
303 RTA_UNSPEC = C.RTA_UNSPEC
304 RTA_DST = C.RTA_DST
305 RTA_SRC = C.RTA_SRC
306 RTA_IIF = C.RTA_IIF
307 RTA_OIF = C.RTA_OIF
308 RTA_GATEWAY = C.RTA_GATEWAY
309 RTA_PRIORITY = C.RTA_PRIORITY
310 RTA_PREFSRC = C.RTA_PREFSRC
311 RTA_METRICS = C.RTA_METRICS
312 RTA_MULTIPATH = C.RTA_MULTIPATH
313 RTA_FLOW = C.RTA_FLOW
314 RTA_CACHEINFO = C.RTA_CACHEINFO
315 RTA_TABLE = C.RTA_TABLE
316 RTN_UNSPEC = C.RTN_UNSPEC
317 RTN_UNICAST = C.RTN_UNICAST
318 RTN_LOCAL = C.RTN_LOCAL
319 RTN_BROADCAST = C.RTN_BROADCAST
320 RTN_ANYCAST = C.RTN_ANYCAST
321 RTN_MULTICAST = C.RTN_MULTICAST
322 RTN_BLACKHOLE = C.RTN_BLACKHOLE
323 RTN_UNREACHABLE = C.RTN_UNREACHABLE
324 RTN_PROHIBIT = C.RTN_PROHIBIT
325 RTN_THROW = C.RTN_THROW
326 RTN_NAT = C.RTN_NAT
327 RTN_XRESOLVE = C.RTN_XRESOLVE
328 RTNLGRP_NONE = C.RTNLGRP_NONE
329 RTNLGRP_LINK = C.RTNLGRP_LINK
330 RTNLGRP_NOTIFY = C.RTNLGRP_NOTIFY
331 RTNLGRP_NEIGH = C.RTNLGRP_NEIGH
332 RTNLGRP_TC = C.RTNLGRP_TC
333 RTNLGRP_IPV4_IFADDR = C.RTNLGRP_IPV4_IFADDR
334 RTNLGRP_IPV4_MROUTE = C.RTNLGRP_IPV4_MROUTE
335 RTNLGRP_IPV4_ROUTE = C.RTNLGRP_IPV4_ROUTE
336 RTNLGRP_IPV4_RULE = C.RTNLGRP_IPV4_RULE
337 RTNLGRP_IPV6_IFADDR = C.RTNLGRP_IPV6_IFADDR
338 RTNLGRP_IPV6_MROUTE = C.RTNLGRP_IPV6_MROUTE
339 RTNLGRP_IPV6_ROUTE = C.RTNLGRP_IPV6_ROUTE
340 RTNLGRP_IPV6_IFINFO = C.RTNLGRP_IPV6_IFINFO
341 RTNLGRP_IPV6_PREFIX = C.RTNLGRP_IPV6_PREFIX
342 RTNLGRP_IPV6_RULE = C.RTNLGRP_IPV6_RULE
343 RTNLGRP_ND_USEROPT = C.RTNLGRP_ND_USEROPT
344 SizeofNlMsghdr = C.sizeof_struct_nlmsghdr
345 SizeofNlMsgerr = C.sizeof_struct_nlmsgerr
346 SizeofRtGenmsg = C.sizeof_struct_rtgenmsg
347 SizeofNlAttr = C.sizeof_struct_nlattr
348 SizeofRtAttr = C.sizeof_struct_rtattr
349 SizeofIfInfomsg = C.sizeof_struct_ifinfomsg
350 SizeofIfAddrmsg = C.sizeof_struct_ifaddrmsg
351 SizeofRtMsg = C.sizeof_struct_rtmsg
352 SizeofRtNexthop = C.sizeof_struct_rtnexthop
353 )
354
355 type NlMsghdr C.struct_nlmsghdr
356
357 type NlMsgerr C.struct_nlmsgerr
358
359 type RtGenmsg C.struct_rtgenmsg
360
361 type NlAttr C.struct_nlattr
362
363 type RtAttr C.struct_rtattr
364
365 type IfInfomsg C.struct_ifinfomsg
366
367 type IfAddrmsg C.struct_ifaddrmsg
368
369 type RtMsg C.struct_rtmsg
370
371 type RtNexthop C.struct_rtnexthop
372
373
374
375 const (
376 SizeofSockFilter = C.sizeof_struct_sock_filter
377 SizeofSockFprog = C.sizeof_struct_sock_fprog
378 )
379
380 type SockFilter C.struct_sock_filter
381
382 type SockFprog C.struct_sock_fprog
383
384
385
386 type InotifyEvent C.struct_inotify_event
387
388 const SizeofInotifyEvent = C.sizeof_struct_inotify_event
389
390
391
392
393 type PtraceRegs C.PtraceRegs
394
395
396 type ptracePsw C.ptracePsw
397
398 type ptraceFpregs C.ptraceFpregs
399
400 type ptracePer C.ptracePer
401
402
403
404 type FdSet C.fd_set
405
406 type Sysinfo_t C.struct_sysinfo
407
408 type Utsname C.struct_utsname
409
410 type Ustat_t C.struct_ustat
411
412 type EpollEvent C.struct_my_epoll_event
413
414 const (
415 _AT_FDCWD = C.AT_FDCWD
416 _AT_REMOVEDIR = C.AT_REMOVEDIR
417 _AT_SYMLINK_NOFOLLOW = C.AT_SYMLINK_NOFOLLOW
418 _AT_EACCESS = C.AT_EACCESS
419 )
420
421 type pollFd C.struct_pollfd
422
423
424
425 type Termios C.struct_termios
426
427 const (
428 IUCLC = C.IUCLC
429 OLCUC = C.OLCUC
430 TCGETS = C.TCGETS
431 TCSETS = C.TCSETS
432 XCASE = C.XCASE
433 )
434
View as plain text