1// cgo -godefs types_freebsd.go | go run mkpost.go 2// Code generated by the command above; see README.md. DO NOT EDIT. 3 4//go:build 386 && freebsd 5// +build 386,freebsd 6 7package unix 8 9const ( 10 SizeofPtr = 0x4 11 SizeofShort = 0x2 12 SizeofInt = 0x4 13 SizeofLong = 0x4 14 SizeofLongLong = 0x8 15) 16 17type ( 18 _C_short int16 19 _C_int int32 20 _C_long int32 21 _C_long_long int64 22) 23 24type Timespec struct { 25 Sec int32 26 Nsec int32 27} 28 29type Timeval struct { 30 Sec int32 31 Usec int32 32} 33 34type Time_t int32 35 36type Rusage struct { 37 Utime Timeval 38 Stime Timeval 39 Maxrss int32 40 Ixrss int32 41 Idrss int32 42 Isrss int32 43 Minflt int32 44 Majflt int32 45 Nswap int32 46 Inblock int32 47 Oublock int32 48 Msgsnd int32 49 Msgrcv int32 50 Nsignals int32 51 Nvcsw int32 52 Nivcsw int32 53} 54 55type Rlimit struct { 56 Cur int64 57 Max int64 58} 59 60type _Gid_t uint32 61 62const ( 63 _statfsVersion = 0x20140518 64 _dirblksiz = 0x400 65) 66 67type Stat_t struct { 68 Dev uint64 69 Ino uint64 70 Nlink uint64 71 Mode uint16 72 _0 int16 73 Uid uint32 74 Gid uint32 75 _1 int32 76 Rdev uint64 77 _ int32 78 Atim Timespec 79 _ int32 80 Mtim Timespec 81 _ int32 82 Ctim Timespec 83 _ int32 84 Btim Timespec 85 Size int64 86 Blocks int64 87 Blksize int32 88 Flags uint32 89 Gen uint64 90 Spare [10]uint64 91} 92 93type stat_freebsd11_t struct { 94 Dev uint32 95 Ino uint32 96 Mode uint16 97 Nlink uint16 98 Uid uint32 99 Gid uint32 100 Rdev uint32 101 Atim Timespec 102 Mtim Timespec 103 Ctim Timespec 104 Size int64 105 Blocks int64 106 Blksize int32 107 Flags uint32 108 Gen uint32 109 Lspare int32 110 Btim Timespec 111 _ [8]byte 112} 113 114type Statfs_t struct { 115 Version uint32 116 Type uint32 117 Flags uint64 118 Bsize uint64 119 Iosize uint64 120 Blocks uint64 121 Bfree uint64 122 Bavail int64 123 Files uint64 124 Ffree int64 125 Syncwrites uint64 126 Asyncwrites uint64 127 Syncreads uint64 128 Asyncreads uint64 129 Spare [10]uint64 130 Namemax uint32 131 Owner uint32 132 Fsid Fsid 133 Charspare [80]int8 134 Fstypename [16]byte 135 Mntfromname [1024]byte 136 Mntonname [1024]byte 137} 138 139type statfs_freebsd11_t struct { 140 Version uint32 141 Type uint32 142 Flags uint64 143 Bsize uint64 144 Iosize uint64 145 Blocks uint64 146 Bfree uint64 147 Bavail int64 148 Files uint64 149 Ffree int64 150 Syncwrites uint64 151 Asyncwrites uint64 152 Syncreads uint64 153 Asyncreads uint64 154 Spare [10]uint64 155 Namemax uint32 156 Owner uint32 157 Fsid Fsid 158 Charspare [80]int8 159 Fstypename [16]byte 160 Mntfromname [88]byte 161 Mntonname [88]byte 162} 163 164type Flock_t struct { 165 Start int64 166 Len int64 167 Pid int32 168 Type int16 169 Whence int16 170 Sysid int32 171} 172 173type Dirent struct { 174 Fileno uint64 175 Off int64 176 Reclen uint16 177 Type uint8 178 Pad0 uint8 179 Namlen uint16 180 Pad1 uint16 181 Name [256]int8 182} 183 184type dirent_freebsd11 struct { 185 Fileno uint32 186 Reclen uint16 187 Type uint8 188 Namlen uint8 189 Name [256]int8 190} 191 192type Fsid struct { 193 Val [2]int32 194} 195 196const ( 197 PathMax = 0x400 198) 199 200const ( 201 FADV_NORMAL = 0x0 202 FADV_RANDOM = 0x1 203 FADV_SEQUENTIAL = 0x2 204 FADV_WILLNEED = 0x3 205 FADV_DONTNEED = 0x4 206 FADV_NOREUSE = 0x5 207) 208 209type RawSockaddrInet4 struct { 210 Len uint8 211 Family uint8 212 Port uint16 213 Addr [4]byte /* in_addr */ 214 Zero [8]int8 215} 216 217type RawSockaddrInet6 struct { 218 Len uint8 219 Family uint8 220 Port uint16 221 Flowinfo uint32 222 Addr [16]byte /* in6_addr */ 223 Scope_id uint32 224} 225 226type RawSockaddrUnix struct { 227 Len uint8 228 Family uint8 229 Path [104]int8 230} 231 232type RawSockaddrDatalink struct { 233 Len uint8 234 Family uint8 235 Index uint16 236 Type uint8 237 Nlen uint8 238 Alen uint8 239 Slen uint8 240 Data [46]int8 241} 242 243type RawSockaddr struct { 244 Len uint8 245 Family uint8 246 Data [14]int8 247} 248 249type RawSockaddrAny struct { 250 Addr RawSockaddr 251 Pad [92]int8 252} 253 254type _Socklen uint32 255 256type Xucred struct { 257 Version uint32 258 Uid uint32 259 Ngroups int16 260 Groups [16]uint32 261 _ *byte 262} 263 264type Linger struct { 265 Onoff int32 266 Linger int32 267} 268 269type Iovec struct { 270 Base *byte 271 Len uint32 272} 273 274type IPMreq struct { 275 Multiaddr [4]byte /* in_addr */ 276 Interface [4]byte /* in_addr */ 277} 278 279type IPMreqn struct { 280 Multiaddr [4]byte /* in_addr */ 281 Address [4]byte /* in_addr */ 282 Ifindex int32 283} 284 285type IPv6Mreq struct { 286 Multiaddr [16]byte /* in6_addr */ 287 Interface uint32 288} 289 290type Msghdr struct { 291 Name *byte 292 Namelen uint32 293 Iov *Iovec 294 Iovlen int32 295 Control *byte 296 Controllen uint32 297 Flags int32 298} 299 300type Cmsghdr struct { 301 Len uint32 302 Level int32 303 Type int32 304} 305 306type Inet6Pktinfo struct { 307 Addr [16]byte /* in6_addr */ 308 Ifindex uint32 309} 310 311type IPv6MTUInfo struct { 312 Addr RawSockaddrInet6 313 Mtu uint32 314} 315 316type ICMPv6Filter struct { 317 Filt [8]uint32 318} 319 320const ( 321 SizeofSockaddrInet4 = 0x10 322 SizeofSockaddrInet6 = 0x1c 323 SizeofSockaddrAny = 0x6c 324 SizeofSockaddrUnix = 0x6a 325 SizeofSockaddrDatalink = 0x36 326 SizeofXucred = 0x50 327 SizeofLinger = 0x8 328 SizeofIovec = 0x8 329 SizeofIPMreq = 0x8 330 SizeofIPMreqn = 0xc 331 SizeofIPv6Mreq = 0x14 332 SizeofMsghdr = 0x1c 333 SizeofCmsghdr = 0xc 334 SizeofInet6Pktinfo = 0x14 335 SizeofIPv6MTUInfo = 0x20 336 SizeofICMPv6Filter = 0x20 337) 338 339const ( 340 PTRACE_ATTACH = 0xa 341 PTRACE_CONT = 0x7 342 PTRACE_DETACH = 0xb 343 PTRACE_GETFPREGS = 0x23 344 PTRACE_GETFSBASE = 0x47 345 PTRACE_GETLWPLIST = 0xf 346 PTRACE_GETNUMLWPS = 0xe 347 PTRACE_GETREGS = 0x21 348 PTRACE_GETXSTATE = 0x45 349 PTRACE_IO = 0xc 350 PTRACE_KILL = 0x8 351 PTRACE_LWPEVENTS = 0x18 352 PTRACE_LWPINFO = 0xd 353 PTRACE_SETFPREGS = 0x24 354 PTRACE_SETREGS = 0x22 355 PTRACE_SINGLESTEP = 0x9 356 PTRACE_TRACEME = 0x0 357) 358 359const ( 360 PIOD_READ_D = 0x1 361 PIOD_WRITE_D = 0x2 362 PIOD_READ_I = 0x3 363 PIOD_WRITE_I = 0x4 364) 365 366const ( 367 PL_FLAG_BORN = 0x100 368 PL_FLAG_EXITED = 0x200 369 PL_FLAG_SI = 0x20 370) 371 372const ( 373 TRAP_BRKPT = 0x1 374 TRAP_TRACE = 0x2 375) 376 377type PtraceLwpInfoStruct struct { 378 Lwpid int32 379 Event int32 380 Flags int32 381 Sigmask Sigset_t 382 Siglist Sigset_t 383 Siginfo __Siginfo 384 Tdname [20]int8 385 Child_pid int32 386 Syscall_code uint32 387 Syscall_narg uint32 388} 389 390type __Siginfo struct { 391 Signo int32 392 Errno int32 393 Code int32 394 Pid int32 395 Uid uint32 396 Status int32 397 Addr *byte 398 Value [4]byte 399 _ [32]byte 400} 401 402type Sigset_t struct { 403 Val [4]uint32 404} 405 406type Reg struct { 407 Fs uint32 408 Es uint32 409 Ds uint32 410 Edi uint32 411 Esi uint32 412 Ebp uint32 413 Isp uint32 414 Ebx uint32 415 Edx uint32 416 Ecx uint32 417 Eax uint32 418 Trapno uint32 419 Err uint32 420 Eip uint32 421 Cs uint32 422 Eflags uint32 423 Esp uint32 424 Ss uint32 425 Gs uint32 426} 427 428type FpReg struct { 429 Env [7]uint32 430 Acc [8][10]uint8 431 Ex_sw uint32 432 Pad [64]uint8 433} 434 435type PtraceIoDesc struct { 436 Op int32 437 Offs *byte 438 Addr *byte 439 Len uint32 440} 441 442type Kevent_t struct { 443 Ident uint32 444 Filter int16 445 Flags uint16 446 Fflags uint32 447 Data int32 448 Udata *byte 449} 450 451type FdSet struct { 452 Bits [32]uint32 453} 454 455const ( 456 sizeofIfMsghdr = 0xa8 457 SizeofIfMsghdr = 0x60 458 sizeofIfData = 0x98 459 SizeofIfData = 0x50 460 SizeofIfaMsghdr = 0x14 461 SizeofIfmaMsghdr = 0x10 462 SizeofIfAnnounceMsghdr = 0x18 463 SizeofRtMsghdr = 0x5c 464 SizeofRtMetrics = 0x38 465) 466 467type ifMsghdr struct { 468 Msglen uint16 469 Version uint8 470 Type uint8 471 Addrs int32 472 Flags int32 473 Index uint16 474 _ uint16 475 Data ifData 476} 477 478type IfMsghdr struct { 479 Msglen uint16 480 Version uint8 481 Type uint8 482 Addrs int32 483 Flags int32 484 Index uint16 485 Data IfData 486} 487 488type ifData struct { 489 Type uint8 490 Physical uint8 491 Addrlen uint8 492 Hdrlen uint8 493 Link_state uint8 494 Vhid uint8 495 Datalen uint16 496 Mtu uint32 497 Metric uint32 498 Baudrate uint64 499 Ipackets uint64 500 Ierrors uint64 501 Opackets uint64 502 Oerrors uint64 503 Collisions uint64 504 Ibytes uint64 505 Obytes uint64 506 Imcasts uint64 507 Omcasts uint64 508 Iqdrops uint64 509 Oqdrops uint64 510 Noproto uint64 511 Hwassist uint64 512 _ [8]byte 513 _ [16]byte 514} 515 516type IfData struct { 517 Type uint8 518 Physical uint8 519 Addrlen uint8 520 Hdrlen uint8 521 Link_state uint8 522 Spare_char1 uint8 523 Spare_char2 uint8 524 Datalen uint8 525 Mtu uint32 526 Metric uint32 527 Baudrate uint32 528 Ipackets uint32 529 Ierrors uint32 530 Opackets uint32 531 Oerrors uint32 532 Collisions uint32 533 Ibytes uint32 534 Obytes uint32 535 Imcasts uint32 536 Omcasts uint32 537 Iqdrops uint32 538 Noproto uint32 539 Hwassist uint32 540 Epoch int32 541 Lastchange Timeval 542} 543 544type IfaMsghdr struct { 545 Msglen uint16 546 Version uint8 547 Type uint8 548 Addrs int32 549 Flags int32 550 Index uint16 551 _ uint16 552 Metric int32 553} 554 555type IfmaMsghdr struct { 556 Msglen uint16 557 Version uint8 558 Type uint8 559 Addrs int32 560 Flags int32 561 Index uint16 562 _ uint16 563} 564 565type IfAnnounceMsghdr struct { 566 Msglen uint16 567 Version uint8 568 Type uint8 569 Index uint16 570 Name [16]int8 571 What uint16 572} 573 574type RtMsghdr struct { 575 Msglen uint16 576 Version uint8 577 Type uint8 578 Index uint16 579 _ uint16 580 Flags int32 581 Addrs int32 582 Pid int32 583 Seq int32 584 Errno int32 585 Fmask int32 586 Inits uint32 587 Rmx RtMetrics 588} 589 590type RtMetrics struct { 591 Locks uint32 592 Mtu uint32 593 Hopcount uint32 594 Expire uint32 595 Recvpipe uint32 596 Sendpipe uint32 597 Ssthresh uint32 598 Rtt uint32 599 Rttvar uint32 600 Pksent uint32 601 Weight uint32 602 Filler [3]uint32 603} 604 605const ( 606 SizeofBpfVersion = 0x4 607 SizeofBpfStat = 0x8 608 SizeofBpfZbuf = 0xc 609 SizeofBpfProgram = 0x8 610 SizeofBpfInsn = 0x8 611 SizeofBpfHdr = 0x14 612 SizeofBpfZbufHeader = 0x20 613) 614 615type BpfVersion struct { 616 Major uint16 617 Minor uint16 618} 619 620type BpfStat struct { 621 Recv uint32 622 Drop uint32 623} 624 625type BpfZbuf struct { 626 Bufa *byte 627 Bufb *byte 628 Buflen uint32 629} 630 631type BpfProgram struct { 632 Len uint32 633 Insns *BpfInsn 634} 635 636type BpfInsn struct { 637 Code uint16 638 Jt uint8 639 Jf uint8 640 K uint32 641} 642 643type BpfHdr struct { 644 Tstamp Timeval 645 Caplen uint32 646 Datalen uint32 647 Hdrlen uint16 648 _ [2]byte 649} 650 651type BpfZbufHeader struct { 652 Kernel_gen uint32 653 Kernel_len uint32 654 User_gen uint32 655 _ [5]uint32 656} 657 658type Termios struct { 659 Iflag uint32 660 Oflag uint32 661 Cflag uint32 662 Lflag uint32 663 Cc [20]uint8 664 Ispeed uint32 665 Ospeed uint32 666} 667 668type Winsize struct { 669 Row uint16 670 Col uint16 671 Xpixel uint16 672 Ypixel uint16 673} 674 675const ( 676 AT_FDCWD = -0x64 677 AT_EACCESS = 0x100 678 AT_SYMLINK_NOFOLLOW = 0x200 679 AT_SYMLINK_FOLLOW = 0x400 680 AT_REMOVEDIR = 0x800 681) 682 683type PollFd struct { 684 Fd int32 685 Events int16 686 Revents int16 687} 688 689const ( 690 POLLERR = 0x8 691 POLLHUP = 0x10 692 POLLIN = 0x1 693 POLLINIGNEOF = 0x2000 694 POLLNVAL = 0x20 695 POLLOUT = 0x4 696 POLLPRI = 0x2 697 POLLRDBAND = 0x80 698 POLLRDNORM = 0x40 699 POLLWRBAND = 0x100 700 POLLWRNORM = 0x4 701) 702 703type CapRights struct { 704 Rights [2]uint64 705} 706 707type Utsname struct { 708 Sysname [256]byte 709 Nodename [256]byte 710 Release [256]byte 711 Version [256]byte 712 Machine [256]byte 713} 714 715const SizeofClockinfo = 0x14 716 717type Clockinfo struct { 718 Hz int32 719 Tick int32 720 Spare int32 721 Stathz int32 722 Profhz int32 723} 724