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.

ztypes_freebsd_386.go 9.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603
  1. // cgo -godefs types_freebsd.go | go run mkpost.go
  2. // Code generated by the command above; see README.md. DO NOT EDIT.
  3. // +build 386,freebsd
  4. package unix
  5. const (
  6. SizeofPtr = 0x4
  7. SizeofShort = 0x2
  8. SizeofInt = 0x4
  9. SizeofLong = 0x4
  10. SizeofLongLong = 0x8
  11. )
  12. type (
  13. _C_short int16
  14. _C_int int32
  15. _C_long int32
  16. _C_long_long int64
  17. )
  18. type Timespec struct {
  19. Sec int32
  20. Nsec int32
  21. }
  22. type Timeval struct {
  23. Sec int32
  24. Usec int32
  25. }
  26. type Rusage struct {
  27. Utime Timeval
  28. Stime Timeval
  29. Maxrss int32
  30. Ixrss int32
  31. Idrss int32
  32. Isrss int32
  33. Minflt int32
  34. Majflt int32
  35. Nswap int32
  36. Inblock int32
  37. Oublock int32
  38. Msgsnd int32
  39. Msgrcv int32
  40. Nsignals int32
  41. Nvcsw int32
  42. Nivcsw int32
  43. }
  44. type Rlimit struct {
  45. Cur int64
  46. Max int64
  47. }
  48. type _Gid_t uint32
  49. const (
  50. _statfsVersion = 0x20140518
  51. _dirblksiz = 0x400
  52. )
  53. type Stat_t struct {
  54. Dev uint64
  55. Ino uint64
  56. Nlink uint64
  57. Mode uint16
  58. _0 int16
  59. Uid uint32
  60. Gid uint32
  61. _1 int32
  62. Rdev uint64
  63. _ int32
  64. Atim Timespec
  65. _ int32
  66. Mtim Timespec
  67. _ int32
  68. Ctim Timespec
  69. _ int32
  70. Btim Timespec
  71. Size int64
  72. Blocks int64
  73. Blksize int32
  74. Flags uint32
  75. Gen uint64
  76. Spare [10]uint64
  77. }
  78. type stat_freebsd11_t struct {
  79. Dev uint32
  80. Ino uint32
  81. Mode uint16
  82. Nlink uint16
  83. Uid uint32
  84. Gid uint32
  85. Rdev uint32
  86. Atim Timespec
  87. Mtim Timespec
  88. Ctim Timespec
  89. Size int64
  90. Blocks int64
  91. Blksize int32
  92. Flags uint32
  93. Gen uint32
  94. Lspare int32
  95. Btim Timespec
  96. _ [8]byte
  97. }
  98. type Statfs_t struct {
  99. Version uint32
  100. Type uint32
  101. Flags uint64
  102. Bsize uint64
  103. Iosize uint64
  104. Blocks uint64
  105. Bfree uint64
  106. Bavail int64
  107. Files uint64
  108. Ffree int64
  109. Syncwrites uint64
  110. Asyncwrites uint64
  111. Syncreads uint64
  112. Asyncreads uint64
  113. Spare [10]uint64
  114. Namemax uint32
  115. Owner uint32
  116. Fsid Fsid
  117. Charspare [80]int8
  118. Fstypename [16]int8
  119. Mntfromname [1024]int8
  120. Mntonname [1024]int8
  121. }
  122. type statfs_freebsd11_t struct {
  123. Version uint32
  124. Type uint32
  125. Flags uint64
  126. Bsize uint64
  127. Iosize uint64
  128. Blocks uint64
  129. Bfree uint64
  130. Bavail int64
  131. Files uint64
  132. Ffree int64
  133. Syncwrites uint64
  134. Asyncwrites uint64
  135. Syncreads uint64
  136. Asyncreads uint64
  137. Spare [10]uint64
  138. Namemax uint32
  139. Owner uint32
  140. Fsid Fsid
  141. Charspare [80]int8
  142. Fstypename [16]int8
  143. Mntfromname [88]int8
  144. Mntonname [88]int8
  145. }
  146. type Flock_t struct {
  147. Start int64
  148. Len int64
  149. Pid int32
  150. Type int16
  151. Whence int16
  152. Sysid int32
  153. }
  154. type Dirent struct {
  155. Fileno uint64
  156. Off int64
  157. Reclen uint16
  158. Type uint8
  159. Pad0 uint8
  160. Namlen uint16
  161. Pad1 uint16
  162. Name [256]int8
  163. }
  164. type dirent_freebsd11 struct {
  165. Fileno uint32
  166. Reclen uint16
  167. Type uint8
  168. Namlen uint8
  169. Name [256]int8
  170. }
  171. type Fsid struct {
  172. Val [2]int32
  173. }
  174. const (
  175. PathMax = 0x400
  176. )
  177. const (
  178. FADV_NORMAL = 0x0
  179. FADV_RANDOM = 0x1
  180. FADV_SEQUENTIAL = 0x2
  181. FADV_WILLNEED = 0x3
  182. FADV_DONTNEED = 0x4
  183. FADV_NOREUSE = 0x5
  184. )
  185. type RawSockaddrInet4 struct {
  186. Len uint8
  187. Family uint8
  188. Port uint16
  189. Addr [4]byte /* in_addr */
  190. Zero [8]int8
  191. }
  192. type RawSockaddrInet6 struct {
  193. Len uint8
  194. Family uint8
  195. Port uint16
  196. Flowinfo uint32
  197. Addr [16]byte /* in6_addr */
  198. Scope_id uint32
  199. }
  200. type RawSockaddrUnix struct {
  201. Len uint8
  202. Family uint8
  203. Path [104]int8
  204. }
  205. type RawSockaddrDatalink struct {
  206. Len uint8
  207. Family uint8
  208. Index uint16
  209. Type uint8
  210. Nlen uint8
  211. Alen uint8
  212. Slen uint8
  213. Data [46]int8
  214. }
  215. type RawSockaddr struct {
  216. Len uint8
  217. Family uint8
  218. Data [14]int8
  219. }
  220. type RawSockaddrAny struct {
  221. Addr RawSockaddr
  222. Pad [92]int8
  223. }
  224. type _Socklen uint32
  225. type Linger struct {
  226. Onoff int32
  227. Linger int32
  228. }
  229. type Iovec struct {
  230. Base *byte
  231. Len uint32
  232. }
  233. type IPMreq struct {
  234. Multiaddr [4]byte /* in_addr */
  235. Interface [4]byte /* in_addr */
  236. }
  237. type IPMreqn struct {
  238. Multiaddr [4]byte /* in_addr */
  239. Address [4]byte /* in_addr */
  240. Ifindex int32
  241. }
  242. type IPv6Mreq struct {
  243. Multiaddr [16]byte /* in6_addr */
  244. Interface uint32
  245. }
  246. type Msghdr struct {
  247. Name *byte
  248. Namelen uint32
  249. Iov *Iovec
  250. Iovlen int32
  251. Control *byte
  252. Controllen uint32
  253. Flags int32
  254. }
  255. type Cmsghdr struct {
  256. Len uint32
  257. Level int32
  258. Type int32
  259. }
  260. type Inet6Pktinfo struct {
  261. Addr [16]byte /* in6_addr */
  262. Ifindex uint32
  263. }
  264. type IPv6MTUInfo struct {
  265. Addr RawSockaddrInet6
  266. Mtu uint32
  267. }
  268. type ICMPv6Filter struct {
  269. Filt [8]uint32
  270. }
  271. const (
  272. SizeofSockaddrInet4 = 0x10
  273. SizeofSockaddrInet6 = 0x1c
  274. SizeofSockaddrAny = 0x6c
  275. SizeofSockaddrUnix = 0x6a
  276. SizeofSockaddrDatalink = 0x36
  277. SizeofLinger = 0x8
  278. SizeofIPMreq = 0x8
  279. SizeofIPMreqn = 0xc
  280. SizeofIPv6Mreq = 0x14
  281. SizeofMsghdr = 0x1c
  282. SizeofCmsghdr = 0xc
  283. SizeofInet6Pktinfo = 0x14
  284. SizeofIPv6MTUInfo = 0x20
  285. SizeofICMPv6Filter = 0x20
  286. )
  287. const (
  288. PTRACE_TRACEME = 0x0
  289. PTRACE_CONT = 0x7
  290. PTRACE_KILL = 0x8
  291. )
  292. type Kevent_t struct {
  293. Ident uint32
  294. Filter int16
  295. Flags uint16
  296. Fflags uint32
  297. Data int32
  298. Udata *byte
  299. }
  300. type FdSet struct {
  301. Bits [32]uint32
  302. }
  303. const (
  304. sizeofIfMsghdr = 0xa8
  305. SizeofIfMsghdr = 0x60
  306. sizeofIfData = 0x98
  307. SizeofIfData = 0x50
  308. SizeofIfaMsghdr = 0x14
  309. SizeofIfmaMsghdr = 0x10
  310. SizeofIfAnnounceMsghdr = 0x18
  311. SizeofRtMsghdr = 0x5c
  312. SizeofRtMetrics = 0x38
  313. )
  314. type ifMsghdr struct {
  315. Msglen uint16
  316. Version uint8
  317. Type uint8
  318. Addrs int32
  319. Flags int32
  320. Index uint16
  321. _ [2]byte
  322. Data ifData
  323. }
  324. type IfMsghdr struct {
  325. Msglen uint16
  326. Version uint8
  327. Type uint8
  328. Addrs int32
  329. Flags int32
  330. Index uint16
  331. _ [2]byte
  332. Data IfData
  333. }
  334. type ifData struct {
  335. Type uint8
  336. Physical uint8
  337. Addrlen uint8
  338. Hdrlen uint8
  339. Link_state uint8
  340. Vhid uint8
  341. Datalen uint16
  342. Mtu uint32
  343. Metric uint32
  344. Baudrate uint64
  345. Ipackets uint64
  346. Ierrors uint64
  347. Opackets uint64
  348. Oerrors uint64
  349. Collisions uint64
  350. Ibytes uint64
  351. Obytes uint64
  352. Imcasts uint64
  353. Omcasts uint64
  354. Iqdrops uint64
  355. Oqdrops uint64
  356. Noproto uint64
  357. Hwassist uint64
  358. _ [8]byte
  359. _ [16]byte
  360. }
  361. type IfData struct {
  362. Type uint8
  363. Physical uint8
  364. Addrlen uint8
  365. Hdrlen uint8
  366. Link_state uint8
  367. Spare_char1 uint8
  368. Spare_char2 uint8
  369. Datalen uint8
  370. Mtu uint32
  371. Metric uint32
  372. Baudrate uint32
  373. Ipackets uint32
  374. Ierrors uint32
  375. Opackets uint32
  376. Oerrors uint32
  377. Collisions uint32
  378. Ibytes uint32
  379. Obytes uint32
  380. Imcasts uint32
  381. Omcasts uint32
  382. Iqdrops uint32
  383. Noproto uint32
  384. Hwassist uint32
  385. Epoch int32
  386. Lastchange Timeval
  387. }
  388. type IfaMsghdr struct {
  389. Msglen uint16
  390. Version uint8
  391. Type uint8
  392. Addrs int32
  393. Flags int32
  394. Index uint16
  395. _ [2]byte
  396. Metric int32
  397. }
  398. type IfmaMsghdr struct {
  399. Msglen uint16
  400. Version uint8
  401. Type uint8
  402. Addrs int32
  403. Flags int32
  404. Index uint16
  405. _ [2]byte
  406. }
  407. type IfAnnounceMsghdr struct {
  408. Msglen uint16
  409. Version uint8
  410. Type uint8
  411. Index uint16
  412. Name [16]int8
  413. What uint16
  414. }
  415. type RtMsghdr struct {
  416. Msglen uint16
  417. Version uint8
  418. Type uint8
  419. Index uint16
  420. _ [2]byte
  421. Flags int32
  422. Addrs int32
  423. Pid int32
  424. Seq int32
  425. Errno int32
  426. Fmask int32
  427. Inits uint32
  428. Rmx RtMetrics
  429. }
  430. type RtMetrics struct {
  431. Locks uint32
  432. Mtu uint32
  433. Hopcount uint32
  434. Expire uint32
  435. Recvpipe uint32
  436. Sendpipe uint32
  437. Ssthresh uint32
  438. Rtt uint32
  439. Rttvar uint32
  440. Pksent uint32
  441. Weight uint32
  442. Filler [3]uint32
  443. }
  444. const (
  445. SizeofBpfVersion = 0x4
  446. SizeofBpfStat = 0x8
  447. SizeofBpfZbuf = 0xc
  448. SizeofBpfProgram = 0x8
  449. SizeofBpfInsn = 0x8
  450. SizeofBpfHdr = 0x14
  451. SizeofBpfZbufHeader = 0x20
  452. )
  453. type BpfVersion struct {
  454. Major uint16
  455. Minor uint16
  456. }
  457. type BpfStat struct {
  458. Recv uint32
  459. Drop uint32
  460. }
  461. type BpfZbuf struct {
  462. Bufa *byte
  463. Bufb *byte
  464. Buflen uint32
  465. }
  466. type BpfProgram struct {
  467. Len uint32
  468. Insns *BpfInsn
  469. }
  470. type BpfInsn struct {
  471. Code uint16
  472. Jt uint8
  473. Jf uint8
  474. K uint32
  475. }
  476. type BpfHdr struct {
  477. Tstamp Timeval
  478. Caplen uint32
  479. Datalen uint32
  480. Hdrlen uint16
  481. _ [2]byte
  482. }
  483. type BpfZbufHeader struct {
  484. Kernel_gen uint32
  485. Kernel_len uint32
  486. User_gen uint32
  487. _ [5]uint32
  488. }
  489. type Termios struct {
  490. Iflag uint32
  491. Oflag uint32
  492. Cflag uint32
  493. Lflag uint32
  494. Cc [20]uint8
  495. Ispeed uint32
  496. Ospeed uint32
  497. }
  498. type Winsize struct {
  499. Row uint16
  500. Col uint16
  501. Xpixel uint16
  502. Ypixel uint16
  503. }
  504. const (
  505. AT_FDCWD = -0x64
  506. AT_REMOVEDIR = 0x800
  507. AT_SYMLINK_FOLLOW = 0x400
  508. AT_SYMLINK_NOFOLLOW = 0x200
  509. )
  510. type PollFd struct {
  511. Fd int32
  512. Events int16
  513. Revents int16
  514. }
  515. const (
  516. POLLERR = 0x8
  517. POLLHUP = 0x10
  518. POLLIN = 0x1
  519. POLLINIGNEOF = 0x2000
  520. POLLNVAL = 0x20
  521. POLLOUT = 0x4
  522. POLLPRI = 0x2
  523. POLLRDBAND = 0x80
  524. POLLRDNORM = 0x40
  525. POLLWRBAND = 0x100
  526. POLLWRNORM = 0x4
  527. )
  528. type CapRights struct {
  529. Rights [2]uint64
  530. }
  531. type Utsname struct {
  532. Sysname [256]byte
  533. Nodename [256]byte
  534. Release [256]byte
  535. Version [256]byte
  536. Machine [256]byte
  537. }