Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.

645 righe
9.5 KiB

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