You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

654 lines
11 KiB

  1. // +build mips64,linux
  2. // Created by cgo -godefs - DO NOT EDIT
  3. // cgo -godefs types_linux.go
  4. package unix
  5. const (
  6. sizeofPtr = 0x8
  7. sizeofShort = 0x2
  8. sizeofInt = 0x4
  9. sizeofLong = 0x8
  10. sizeofLongLong = 0x8
  11. PathMax = 0x1000
  12. )
  13. type (
  14. _C_short int16
  15. _C_int int32
  16. _C_long int64
  17. _C_long_long int64
  18. )
  19. type Timespec struct {
  20. Sec int64
  21. Nsec int64
  22. }
  23. type Timeval struct {
  24. Sec int64
  25. Usec int64
  26. }
  27. type Timex struct {
  28. Modes uint32
  29. Pad_cgo_0 [4]byte
  30. Offset int64
  31. Freq int64
  32. Maxerror int64
  33. Esterror int64
  34. Status int32
  35. Pad_cgo_1 [4]byte
  36. Constant int64
  37. Precision int64
  38. Tolerance int64
  39. Time Timeval
  40. Tick int64
  41. Ppsfreq int64
  42. Jitter int64
  43. Shift int32
  44. Pad_cgo_2 [4]byte
  45. Stabil int64
  46. Jitcnt int64
  47. Calcnt int64
  48. Errcnt int64
  49. Stbcnt int64
  50. Tai int32
  51. Pad_cgo_3 [44]byte
  52. }
  53. type Time_t int64
  54. type Tms struct {
  55. Utime int64
  56. Stime int64
  57. Cutime int64
  58. Cstime int64
  59. }
  60. type Utimbuf struct {
  61. Actime int64
  62. Modtime int64
  63. }
  64. type Rusage struct {
  65. Utime Timeval
  66. Stime Timeval
  67. Maxrss int64
  68. Ixrss int64
  69. Idrss int64
  70. Isrss int64
  71. Minflt int64
  72. Majflt int64
  73. Nswap int64
  74. Inblock int64
  75. Oublock int64
  76. Msgsnd int64
  77. Msgrcv int64
  78. Nsignals int64
  79. Nvcsw int64
  80. Nivcsw int64
  81. }
  82. type Rlimit struct {
  83. Cur uint64
  84. Max uint64
  85. }
  86. type _Gid_t uint32
  87. type Stat_t struct {
  88. Dev uint32
  89. Pad1 [3]int32
  90. Ino uint64
  91. Mode uint32
  92. Nlink uint32
  93. Uid uint32
  94. Gid uint32
  95. Rdev uint32
  96. Pad2 [3]uint32
  97. Size int64
  98. Atim Timespec
  99. Mtim Timespec
  100. Ctim Timespec
  101. Blksize uint32
  102. Pad4 uint32
  103. Blocks int64
  104. }
  105. type Statfs_t struct {
  106. Type int64
  107. Bsize int64
  108. Frsize int64
  109. Blocks uint64
  110. Bfree uint64
  111. Files uint64
  112. Ffree uint64
  113. Bavail uint64
  114. Fsid Fsid
  115. Namelen int64
  116. Flags int64
  117. Spare [5]int64
  118. }
  119. type Dirent struct {
  120. Ino uint64
  121. Off int64
  122. Reclen uint16
  123. Type uint8
  124. Name [256]int8
  125. Pad_cgo_0 [5]byte
  126. }
  127. type Fsid struct {
  128. X__val [2]int32
  129. }
  130. type Flock_t struct {
  131. Type int16
  132. Whence int16
  133. Pad_cgo_0 [4]byte
  134. Start int64
  135. Len int64
  136. Pid int32
  137. Pad_cgo_1 [4]byte
  138. }
  139. const (
  140. FADV_NORMAL = 0x0
  141. FADV_RANDOM = 0x1
  142. FADV_SEQUENTIAL = 0x2
  143. FADV_WILLNEED = 0x3
  144. FADV_DONTNEED = 0x4
  145. FADV_NOREUSE = 0x5
  146. )
  147. type RawSockaddrInet4 struct {
  148. Family uint16
  149. Port uint16
  150. Addr [4]byte /* in_addr */
  151. Zero [8]uint8
  152. }
  153. type RawSockaddrInet6 struct {
  154. Family uint16
  155. Port uint16
  156. Flowinfo uint32
  157. Addr [16]byte /* in6_addr */
  158. Scope_id uint32
  159. }
  160. type RawSockaddrUnix struct {
  161. Family uint16
  162. Path [108]int8
  163. }
  164. type RawSockaddrLinklayer struct {
  165. Family uint16
  166. Protocol uint16
  167. Ifindex int32
  168. Hatype uint16
  169. Pkttype uint8
  170. Halen uint8
  171. Addr [8]uint8
  172. }
  173. type RawSockaddrNetlink struct {
  174. Family uint16
  175. Pad uint16
  176. Pid uint32
  177. Groups uint32
  178. }
  179. type RawSockaddrHCI struct {
  180. Family uint16
  181. Dev uint16
  182. Channel uint16
  183. }
  184. type RawSockaddrCAN struct {
  185. Family uint16
  186. Pad_cgo_0 [2]byte
  187. Ifindex int32
  188. Addr [8]byte
  189. }
  190. type RawSockaddrALG struct {
  191. Family uint16
  192. Type [14]uint8
  193. Feat uint32
  194. Mask uint32
  195. Name [64]uint8
  196. }
  197. type RawSockaddrVM struct {
  198. Family uint16
  199. Reserved1 uint16
  200. Port uint32
  201. Cid uint32
  202. Zero [4]uint8
  203. }
  204. type RawSockaddr struct {
  205. Family uint16
  206. Data [14]int8
  207. }
  208. type RawSockaddrAny struct {
  209. Addr RawSockaddr
  210. Pad [96]int8
  211. }
  212. type _Socklen uint32
  213. type Linger struct {
  214. Onoff int32
  215. Linger int32
  216. }
  217. type Iovec struct {
  218. Base *byte
  219. Len uint64
  220. }
  221. type IPMreq struct {
  222. Multiaddr [4]byte /* in_addr */
  223. Interface [4]byte /* in_addr */
  224. }
  225. type IPMreqn struct {
  226. Multiaddr [4]byte /* in_addr */
  227. Address [4]byte /* in_addr */
  228. Ifindex int32
  229. }
  230. type IPv6Mreq struct {
  231. Multiaddr [16]byte /* in6_addr */
  232. Interface uint32
  233. }
  234. type Msghdr struct {
  235. Name *byte
  236. Namelen uint32
  237. Pad_cgo_0 [4]byte
  238. Iov *Iovec
  239. Iovlen uint64
  240. Control *byte
  241. Controllen uint64
  242. Flags int32
  243. Pad_cgo_1 [4]byte
  244. }
  245. type Cmsghdr struct {
  246. Len uint64
  247. Level int32
  248. Type int32
  249. }
  250. type Inet4Pktinfo struct {
  251. Ifindex int32
  252. Spec_dst [4]byte /* in_addr */
  253. Addr [4]byte /* in_addr */
  254. }
  255. type Inet6Pktinfo struct {
  256. Addr [16]byte /* in6_addr */
  257. Ifindex uint32
  258. }
  259. type IPv6MTUInfo struct {
  260. Addr RawSockaddrInet6
  261. Mtu uint32
  262. }
  263. type ICMPv6Filter struct {
  264. Data [8]uint32
  265. }
  266. type Ucred struct {
  267. Pid int32
  268. Uid uint32
  269. Gid uint32
  270. }
  271. type TCPInfo struct {
  272. State uint8
  273. Ca_state uint8
  274. Retransmits uint8
  275. Probes uint8
  276. Backoff uint8
  277. Options uint8
  278. Pad_cgo_0 [2]byte
  279. Rto uint32
  280. Ato uint32
  281. Snd_mss uint32
  282. Rcv_mss uint32
  283. Unacked uint32
  284. Sacked uint32
  285. Lost uint32
  286. Retrans uint32
  287. Fackets uint32
  288. Last_data_sent uint32
  289. Last_ack_sent uint32
  290. Last_data_recv uint32
  291. Last_ack_recv uint32
  292. Pmtu uint32
  293. Rcv_ssthresh uint32
  294. Rtt uint32
  295. Rttvar uint32
  296. Snd_ssthresh uint32
  297. Snd_cwnd uint32
  298. Advmss uint32
  299. Reordering uint32
  300. Rcv_rtt uint32
  301. Rcv_space uint32
  302. Total_retrans uint32
  303. }
  304. const (
  305. SizeofSockaddrInet4 = 0x10
  306. SizeofSockaddrInet6 = 0x1c
  307. SizeofSockaddrAny = 0x70
  308. SizeofSockaddrUnix = 0x6e
  309. SizeofSockaddrLinklayer = 0x14
  310. SizeofSockaddrNetlink = 0xc
  311. SizeofSockaddrHCI = 0x6
  312. SizeofSockaddrCAN = 0x10
  313. SizeofSockaddrALG = 0x58
  314. SizeofSockaddrVM = 0x10
  315. SizeofLinger = 0x8
  316. SizeofIPMreq = 0x8
  317. SizeofIPMreqn = 0xc
  318. SizeofIPv6Mreq = 0x14
  319. SizeofMsghdr = 0x38
  320. SizeofCmsghdr = 0x10
  321. SizeofInet4Pktinfo = 0xc
  322. SizeofInet6Pktinfo = 0x14
  323. SizeofIPv6MTUInfo = 0x20
  324. SizeofICMPv6Filter = 0x20
  325. SizeofUcred = 0xc
  326. SizeofTCPInfo = 0x68
  327. )
  328. const (
  329. IFA_UNSPEC = 0x0
  330. IFA_ADDRESS = 0x1
  331. IFA_LOCAL = 0x2
  332. IFA_LABEL = 0x3
  333. IFA_BROADCAST = 0x4
  334. IFA_ANYCAST = 0x5
  335. IFA_CACHEINFO = 0x6
  336. IFA_MULTICAST = 0x7
  337. IFLA_UNSPEC = 0x0
  338. IFLA_ADDRESS = 0x1
  339. IFLA_BROADCAST = 0x2
  340. IFLA_IFNAME = 0x3
  341. IFLA_MTU = 0x4
  342. IFLA_LINK = 0x5
  343. IFLA_QDISC = 0x6
  344. IFLA_STATS = 0x7
  345. IFLA_COST = 0x8
  346. IFLA_PRIORITY = 0x9
  347. IFLA_MASTER = 0xa
  348. IFLA_WIRELESS = 0xb
  349. IFLA_PROTINFO = 0xc
  350. IFLA_TXQLEN = 0xd
  351. IFLA_MAP = 0xe
  352. IFLA_WEIGHT = 0xf
  353. IFLA_OPERSTATE = 0x10
  354. IFLA_LINKMODE = 0x11
  355. IFLA_LINKINFO = 0x12
  356. IFLA_NET_NS_PID = 0x13
  357. IFLA_IFALIAS = 0x14
  358. IFLA_MAX = 0x27
  359. RT_SCOPE_UNIVERSE = 0x0
  360. RT_SCOPE_SITE = 0xc8
  361. RT_SCOPE_LINK = 0xfd
  362. RT_SCOPE_HOST = 0xfe
  363. RT_SCOPE_NOWHERE = 0xff
  364. RT_TABLE_UNSPEC = 0x0
  365. RT_TABLE_COMPAT = 0xfc
  366. RT_TABLE_DEFAULT = 0xfd
  367. RT_TABLE_MAIN = 0xfe
  368. RT_TABLE_LOCAL = 0xff
  369. RT_TABLE_MAX = 0xffffffff
  370. RTA_UNSPEC = 0x0
  371. RTA_DST = 0x1
  372. RTA_SRC = 0x2
  373. RTA_IIF = 0x3
  374. RTA_OIF = 0x4
  375. RTA_GATEWAY = 0x5
  376. RTA_PRIORITY = 0x6
  377. RTA_PREFSRC = 0x7
  378. RTA_METRICS = 0x8
  379. RTA_MULTIPATH = 0x9
  380. RTA_FLOW = 0xb
  381. RTA_CACHEINFO = 0xc
  382. RTA_TABLE = 0xf
  383. RTN_UNSPEC = 0x0
  384. RTN_UNICAST = 0x1
  385. RTN_LOCAL = 0x2
  386. RTN_BROADCAST = 0x3
  387. RTN_ANYCAST = 0x4
  388. RTN_MULTICAST = 0x5
  389. RTN_BLACKHOLE = 0x6
  390. RTN_UNREACHABLE = 0x7
  391. RTN_PROHIBIT = 0x8
  392. RTN_THROW = 0x9
  393. RTN_NAT = 0xa
  394. RTN_XRESOLVE = 0xb
  395. RTNLGRP_NONE = 0x0
  396. RTNLGRP_LINK = 0x1
  397. RTNLGRP_NOTIFY = 0x2
  398. RTNLGRP_NEIGH = 0x3
  399. RTNLGRP_TC = 0x4
  400. RTNLGRP_IPV4_IFADDR = 0x5
  401. RTNLGRP_IPV4_MROUTE = 0x6
  402. RTNLGRP_IPV4_ROUTE = 0x7
  403. RTNLGRP_IPV4_RULE = 0x8
  404. RTNLGRP_IPV6_IFADDR = 0x9
  405. RTNLGRP_IPV6_MROUTE = 0xa
  406. RTNLGRP_IPV6_ROUTE = 0xb
  407. RTNLGRP_IPV6_IFINFO = 0xc
  408. RTNLGRP_IPV6_PREFIX = 0x12
  409. RTNLGRP_IPV6_RULE = 0x13
  410. RTNLGRP_ND_USEROPT = 0x14
  411. SizeofNlMsghdr = 0x10
  412. SizeofNlMsgerr = 0x14
  413. SizeofRtGenmsg = 0x1
  414. SizeofNlAttr = 0x4
  415. SizeofRtAttr = 0x4
  416. SizeofIfInfomsg = 0x10
  417. SizeofIfAddrmsg = 0x8
  418. SizeofRtMsg = 0xc
  419. SizeofRtNexthop = 0x8
  420. )
  421. type NlMsghdr struct {
  422. Len uint32
  423. Type uint16
  424. Flags uint16
  425. Seq uint32
  426. Pid uint32
  427. }
  428. type NlMsgerr struct {
  429. Error int32
  430. Msg NlMsghdr
  431. }
  432. type RtGenmsg struct {
  433. Family uint8
  434. }
  435. type NlAttr struct {
  436. Len uint16
  437. Type uint16
  438. }
  439. type RtAttr struct {
  440. Len uint16
  441. Type uint16
  442. }
  443. type IfInfomsg struct {
  444. Family uint8
  445. X__ifi_pad uint8
  446. Type uint16
  447. Index int32
  448. Flags uint32
  449. Change uint32
  450. }
  451. type IfAddrmsg struct {
  452. Family uint8
  453. Prefixlen uint8
  454. Flags uint8
  455. Scope uint8
  456. Index uint32
  457. }
  458. type RtMsg struct {
  459. Family uint8
  460. Dst_len uint8
  461. Src_len uint8
  462. Tos uint8
  463. Table uint8
  464. Protocol uint8
  465. Scope uint8
  466. Type uint8
  467. Flags uint32
  468. }
  469. type RtNexthop struct {
  470. Len uint16
  471. Flags uint8
  472. Hops uint8
  473. Ifindex int32
  474. }
  475. const (
  476. SizeofSockFilter = 0x8
  477. SizeofSockFprog = 0x10
  478. )
  479. type SockFilter struct {
  480. Code uint16
  481. Jt uint8
  482. Jf uint8
  483. K uint32
  484. }
  485. type SockFprog struct {
  486. Len uint16
  487. Pad_cgo_0 [6]byte
  488. Filter *SockFilter
  489. }
  490. type InotifyEvent struct {
  491. Wd int32
  492. Mask uint32
  493. Cookie uint32
  494. Len uint32
  495. }
  496. const SizeofInotifyEvent = 0x10
  497. type PtraceRegs struct {
  498. Regs [102]uint64
  499. U_tsize uint64
  500. U_dsize uint64
  501. U_ssize uint64
  502. Start_code uint64
  503. Start_data uint64
  504. Start_stack uint64
  505. Signal int64
  506. U_ar0 uint64
  507. Magic uint64
  508. U_comm [32]int8
  509. }
  510. type FdSet struct {
  511. Bits [16]int64
  512. }
  513. type Sysinfo_t struct {
  514. Uptime int64
  515. Loads [3]uint64
  516. Totalram uint64
  517. Freeram uint64
  518. Sharedram uint64
  519. Bufferram uint64
  520. Totalswap uint64
  521. Freeswap uint64
  522. Procs uint16
  523. Pad uint16
  524. Pad_cgo_0 [4]byte
  525. Totalhigh uint64
  526. Freehigh uint64
  527. Unit uint32
  528. X_f [0]int8
  529. Pad_cgo_1 [4]byte
  530. }
  531. type Utsname struct {
  532. Sysname [65]int8
  533. Nodename [65]int8
  534. Release [65]int8
  535. Version [65]int8
  536. Machine [65]int8
  537. Domainname [65]int8
  538. }
  539. type Ustat_t struct {
  540. Tfree int32
  541. Pad_cgo_0 [4]byte
  542. Tinode uint64
  543. Fname [6]int8
  544. Fpack [6]int8
  545. Pad_cgo_1 [4]byte
  546. }
  547. type EpollEvent struct {
  548. Events uint32
  549. Fd int32
  550. Pad int32
  551. }
  552. const (
  553. AT_FDCWD = -0x64
  554. AT_REMOVEDIR = 0x200
  555. AT_SYMLINK_FOLLOW = 0x400
  556. AT_SYMLINK_NOFOLLOW = 0x100
  557. )
  558. type PollFd struct {
  559. Fd int32
  560. Events int16
  561. Revents int16
  562. }
  563. const (
  564. POLLIN = 0x1
  565. POLLPRI = 0x2
  566. POLLOUT = 0x4
  567. POLLRDHUP = 0x2000
  568. POLLERR = 0x8
  569. POLLHUP = 0x10
  570. POLLNVAL = 0x20
  571. )
  572. type Sigset_t struct {
  573. X__val [16]uint64
  574. }
  575. type Termios struct {
  576. Iflag uint32
  577. Oflag uint32
  578. Cflag uint32
  579. Lflag uint32
  580. Line uint8
  581. Cc [32]uint8
  582. Pad_cgo_0 [3]byte
  583. }