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.
 
 
 

661 lines
11 KiB

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