Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 1 | // cgo -godefs types_openbsd.go | go run mkpost.go |
| 2 | // Code generated by the command above; see README.md. DO NOT EDIT. |
| 3 | |
David K. Bainbridge | c415efe | 2021-08-19 13:05:21 +0000 | [diff] [blame] | 4 | //go:build 386 && openbsd |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 5 | // +build 386,openbsd |
| 6 | |
| 7 | package unix |
| 8 | |
| 9 | const ( |
| 10 | SizeofPtr = 0x4 |
| 11 | SizeofShort = 0x2 |
| 12 | SizeofInt = 0x4 |
| 13 | SizeofLong = 0x4 |
| 14 | SizeofLongLong = 0x8 |
| 15 | ) |
| 16 | |
| 17 | type ( |
| 18 | _C_short int16 |
| 19 | _C_int int32 |
| 20 | _C_long int32 |
| 21 | _C_long_long int64 |
| 22 | ) |
| 23 | |
| 24 | type Timespec struct { |
| 25 | Sec int64 |
| 26 | Nsec int32 |
| 27 | } |
| 28 | |
| 29 | type Timeval struct { |
| 30 | Sec int64 |
| 31 | Usec int32 |
| 32 | } |
| 33 | |
| 34 | type Rusage struct { |
| 35 | Utime Timeval |
| 36 | Stime Timeval |
| 37 | Maxrss int32 |
| 38 | Ixrss int32 |
| 39 | Idrss int32 |
| 40 | Isrss int32 |
| 41 | Minflt int32 |
| 42 | Majflt int32 |
| 43 | Nswap int32 |
| 44 | Inblock int32 |
| 45 | Oublock int32 |
| 46 | Msgsnd int32 |
| 47 | Msgrcv int32 |
| 48 | Nsignals int32 |
| 49 | Nvcsw int32 |
| 50 | Nivcsw int32 |
| 51 | } |
| 52 | |
| 53 | type Rlimit struct { |
| 54 | Cur uint64 |
| 55 | Max uint64 |
| 56 | } |
| 57 | |
| 58 | type _Gid_t uint32 |
| 59 | |
| 60 | type Stat_t struct { |
| 61 | Mode uint32 |
| 62 | Dev int32 |
| 63 | Ino uint64 |
| 64 | Nlink uint32 |
| 65 | Uid uint32 |
| 66 | Gid uint32 |
| 67 | Rdev int32 |
| 68 | Atim Timespec |
| 69 | Mtim Timespec |
| 70 | Ctim Timespec |
| 71 | Size int64 |
| 72 | Blocks int64 |
| 73 | Blksize uint32 |
| 74 | Flags uint32 |
| 75 | Gen uint32 |
| 76 | X__st_birthtim Timespec |
| 77 | } |
| 78 | |
| 79 | type Statfs_t struct { |
| 80 | F_flags uint32 |
| 81 | F_bsize uint32 |
| 82 | F_iosize uint32 |
| 83 | F_blocks uint64 |
| 84 | F_bfree uint64 |
| 85 | F_bavail int64 |
| 86 | F_files uint64 |
| 87 | F_ffree uint64 |
| 88 | F_favail int64 |
| 89 | F_syncwrites uint64 |
| 90 | F_syncreads uint64 |
| 91 | F_asyncwrites uint64 |
| 92 | F_asyncreads uint64 |
| 93 | F_fsid Fsid |
| 94 | F_namemax uint32 |
| 95 | F_owner uint32 |
| 96 | F_ctime uint64 |
| 97 | F_fstypename [16]int8 |
| 98 | F_mntonname [90]int8 |
| 99 | F_mntfromname [90]int8 |
| 100 | F_mntfromspec [90]int8 |
| 101 | Pad_cgo_0 [2]byte |
| 102 | Mount_info [160]byte |
| 103 | } |
| 104 | |
| 105 | type Flock_t struct { |
| 106 | Start int64 |
| 107 | Len int64 |
| 108 | Pid int32 |
| 109 | Type int16 |
| 110 | Whence int16 |
| 111 | } |
| 112 | |
| 113 | type Dirent struct { |
| 114 | Fileno uint64 |
| 115 | Off int64 |
| 116 | Reclen uint16 |
| 117 | Type uint8 |
| 118 | Namlen uint8 |
| 119 | X__d_padding [4]uint8 |
| 120 | Name [256]int8 |
| 121 | } |
| 122 | |
| 123 | type Fsid struct { |
| 124 | Val [2]int32 |
| 125 | } |
| 126 | |
| 127 | const ( |
| 128 | PathMax = 0x400 |
| 129 | ) |
| 130 | |
| 131 | type RawSockaddrInet4 struct { |
| 132 | Len uint8 |
| 133 | Family uint8 |
| 134 | Port uint16 |
| 135 | Addr [4]byte /* in_addr */ |
| 136 | Zero [8]int8 |
| 137 | } |
| 138 | |
| 139 | type RawSockaddrInet6 struct { |
| 140 | Len uint8 |
| 141 | Family uint8 |
| 142 | Port uint16 |
| 143 | Flowinfo uint32 |
| 144 | Addr [16]byte /* in6_addr */ |
| 145 | Scope_id uint32 |
| 146 | } |
| 147 | |
| 148 | type RawSockaddrUnix struct { |
| 149 | Len uint8 |
| 150 | Family uint8 |
| 151 | Path [104]int8 |
| 152 | } |
| 153 | |
| 154 | type RawSockaddrDatalink struct { |
| 155 | Len uint8 |
| 156 | Family uint8 |
| 157 | Index uint16 |
| 158 | Type uint8 |
| 159 | Nlen uint8 |
| 160 | Alen uint8 |
| 161 | Slen uint8 |
| 162 | Data [24]int8 |
| 163 | } |
| 164 | |
| 165 | type RawSockaddr struct { |
| 166 | Len uint8 |
| 167 | Family uint8 |
| 168 | Data [14]int8 |
| 169 | } |
| 170 | |
| 171 | type RawSockaddrAny struct { |
| 172 | Addr RawSockaddr |
| 173 | Pad [92]int8 |
| 174 | } |
| 175 | |
| 176 | type _Socklen uint32 |
| 177 | |
| 178 | type Linger struct { |
| 179 | Onoff int32 |
| 180 | Linger int32 |
| 181 | } |
| 182 | |
| 183 | type Iovec struct { |
| 184 | Base *byte |
| 185 | Len uint32 |
| 186 | } |
| 187 | |
| 188 | type IPMreq struct { |
| 189 | Multiaddr [4]byte /* in_addr */ |
| 190 | Interface [4]byte /* in_addr */ |
| 191 | } |
| 192 | |
| 193 | type IPv6Mreq struct { |
| 194 | Multiaddr [16]byte /* in6_addr */ |
| 195 | Interface uint32 |
| 196 | } |
| 197 | |
| 198 | type Msghdr struct { |
| 199 | Name *byte |
| 200 | Namelen uint32 |
| 201 | Iov *Iovec |
| 202 | Iovlen uint32 |
| 203 | Control *byte |
| 204 | Controllen uint32 |
| 205 | Flags int32 |
| 206 | } |
| 207 | |
| 208 | type Cmsghdr struct { |
| 209 | Len uint32 |
| 210 | Level int32 |
| 211 | Type int32 |
| 212 | } |
| 213 | |
| 214 | type Inet6Pktinfo struct { |
| 215 | Addr [16]byte /* in6_addr */ |
| 216 | Ifindex uint32 |
| 217 | } |
| 218 | |
| 219 | type IPv6MTUInfo struct { |
| 220 | Addr RawSockaddrInet6 |
| 221 | Mtu uint32 |
| 222 | } |
| 223 | |
| 224 | type ICMPv6Filter struct { |
| 225 | Filt [8]uint32 |
| 226 | } |
| 227 | |
| 228 | const ( |
| 229 | SizeofSockaddrInet4 = 0x10 |
| 230 | SizeofSockaddrInet6 = 0x1c |
| 231 | SizeofSockaddrAny = 0x6c |
| 232 | SizeofSockaddrUnix = 0x6a |
| 233 | SizeofSockaddrDatalink = 0x20 |
| 234 | SizeofLinger = 0x8 |
David K. Bainbridge | c415efe | 2021-08-19 13:05:21 +0000 | [diff] [blame] | 235 | SizeofIovec = 0x8 |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 236 | SizeofIPMreq = 0x8 |
| 237 | SizeofIPv6Mreq = 0x14 |
| 238 | SizeofMsghdr = 0x1c |
| 239 | SizeofCmsghdr = 0xc |
| 240 | SizeofInet6Pktinfo = 0x14 |
| 241 | SizeofIPv6MTUInfo = 0x20 |
| 242 | SizeofICMPv6Filter = 0x20 |
| 243 | ) |
| 244 | |
| 245 | const ( |
| 246 | PTRACE_TRACEME = 0x0 |
| 247 | PTRACE_CONT = 0x7 |
| 248 | PTRACE_KILL = 0x8 |
| 249 | ) |
| 250 | |
| 251 | type Kevent_t struct { |
| 252 | Ident uint32 |
| 253 | Filter int16 |
| 254 | Flags uint16 |
| 255 | Fflags uint32 |
| 256 | Data int64 |
| 257 | Udata *byte |
| 258 | } |
| 259 | |
| 260 | type FdSet struct { |
| 261 | Bits [32]uint32 |
| 262 | } |
| 263 | |
| 264 | const ( |
| 265 | SizeofIfMsghdr = 0xec |
| 266 | SizeofIfData = 0xd4 |
| 267 | SizeofIfaMsghdr = 0x18 |
| 268 | SizeofIfAnnounceMsghdr = 0x1a |
| 269 | SizeofRtMsghdr = 0x60 |
| 270 | SizeofRtMetrics = 0x38 |
| 271 | ) |
| 272 | |
| 273 | type IfMsghdr struct { |
| 274 | Msglen uint16 |
| 275 | Version uint8 |
| 276 | Type uint8 |
| 277 | Hdrlen uint16 |
| 278 | Index uint16 |
| 279 | Tableid uint16 |
| 280 | Pad1 uint8 |
| 281 | Pad2 uint8 |
| 282 | Addrs int32 |
| 283 | Flags int32 |
| 284 | Xflags int32 |
| 285 | Data IfData |
| 286 | } |
| 287 | |
| 288 | type IfData struct { |
| 289 | Type uint8 |
| 290 | Addrlen uint8 |
| 291 | Hdrlen uint8 |
| 292 | Link_state uint8 |
| 293 | Mtu uint32 |
| 294 | Metric uint32 |
| 295 | Pad uint32 |
| 296 | Baudrate uint64 |
| 297 | Ipackets uint64 |
| 298 | Ierrors uint64 |
| 299 | Opackets uint64 |
| 300 | Oerrors uint64 |
| 301 | Collisions uint64 |
| 302 | Ibytes uint64 |
| 303 | Obytes uint64 |
| 304 | Imcasts uint64 |
| 305 | Omcasts uint64 |
| 306 | Iqdrops uint64 |
| 307 | Noproto uint64 |
| 308 | Capabilities uint32 |
| 309 | Lastchange Timeval |
| 310 | Mclpool [7]Mclpool |
| 311 | } |
| 312 | |
| 313 | type IfaMsghdr struct { |
| 314 | Msglen uint16 |
| 315 | Version uint8 |
| 316 | Type uint8 |
| 317 | Hdrlen uint16 |
| 318 | Index uint16 |
| 319 | Tableid uint16 |
| 320 | Pad1 uint8 |
| 321 | Pad2 uint8 |
| 322 | Addrs int32 |
| 323 | Flags int32 |
| 324 | Metric int32 |
| 325 | } |
| 326 | |
| 327 | type IfAnnounceMsghdr struct { |
| 328 | Msglen uint16 |
| 329 | Version uint8 |
| 330 | Type uint8 |
| 331 | Hdrlen uint16 |
| 332 | Index uint16 |
| 333 | What uint16 |
| 334 | Name [16]int8 |
| 335 | } |
| 336 | |
| 337 | type RtMsghdr struct { |
| 338 | Msglen uint16 |
| 339 | Version uint8 |
| 340 | Type uint8 |
| 341 | Hdrlen uint16 |
| 342 | Index uint16 |
| 343 | Tableid uint16 |
| 344 | Priority uint8 |
| 345 | Mpls uint8 |
| 346 | Addrs int32 |
| 347 | Flags int32 |
| 348 | Fmask int32 |
| 349 | Pid int32 |
| 350 | Seq int32 |
| 351 | Errno int32 |
| 352 | Inits uint32 |
| 353 | Rmx RtMetrics |
| 354 | } |
| 355 | |
| 356 | type RtMetrics struct { |
| 357 | Pksent uint64 |
| 358 | Expire int64 |
| 359 | Locks uint32 |
| 360 | Mtu uint32 |
| 361 | Refcnt uint32 |
| 362 | Hopcount uint32 |
| 363 | Recvpipe uint32 |
| 364 | Sendpipe uint32 |
| 365 | Ssthresh uint32 |
| 366 | Rtt uint32 |
| 367 | Rttvar uint32 |
| 368 | Pad uint32 |
| 369 | } |
| 370 | |
| 371 | type Mclpool struct { |
| 372 | Grown int32 |
| 373 | Alive uint16 |
| 374 | Hwm uint16 |
| 375 | Cwm uint16 |
| 376 | Lwm uint16 |
| 377 | } |
| 378 | |
| 379 | const ( |
| 380 | SizeofBpfVersion = 0x4 |
| 381 | SizeofBpfStat = 0x8 |
| 382 | SizeofBpfProgram = 0x8 |
| 383 | SizeofBpfInsn = 0x8 |
| 384 | SizeofBpfHdr = 0x14 |
| 385 | ) |
| 386 | |
| 387 | type BpfVersion struct { |
| 388 | Major uint16 |
| 389 | Minor uint16 |
| 390 | } |
| 391 | |
| 392 | type BpfStat struct { |
| 393 | Recv uint32 |
| 394 | Drop uint32 |
| 395 | } |
| 396 | |
| 397 | type BpfProgram struct { |
| 398 | Len uint32 |
| 399 | Insns *BpfInsn |
| 400 | } |
| 401 | |
| 402 | type BpfInsn struct { |
| 403 | Code uint16 |
| 404 | Jt uint8 |
| 405 | Jf uint8 |
| 406 | K uint32 |
| 407 | } |
| 408 | |
| 409 | type BpfHdr struct { |
| 410 | Tstamp BpfTimeval |
| 411 | Caplen uint32 |
| 412 | Datalen uint32 |
| 413 | Hdrlen uint16 |
| 414 | Pad_cgo_0 [2]byte |
| 415 | } |
| 416 | |
| 417 | type BpfTimeval struct { |
| 418 | Sec uint32 |
| 419 | Usec uint32 |
| 420 | } |
| 421 | |
| 422 | type Termios struct { |
| 423 | Iflag uint32 |
| 424 | Oflag uint32 |
| 425 | Cflag uint32 |
| 426 | Lflag uint32 |
| 427 | Cc [20]uint8 |
| 428 | Ispeed int32 |
| 429 | Ospeed int32 |
| 430 | } |
| 431 | |
| 432 | type Winsize struct { |
| 433 | Row uint16 |
| 434 | Col uint16 |
| 435 | Xpixel uint16 |
| 436 | Ypixel uint16 |
| 437 | } |
| 438 | |
| 439 | const ( |
| 440 | AT_FDCWD = -0x64 |
David K. Bainbridge | c415efe | 2021-08-19 13:05:21 +0000 | [diff] [blame] | 441 | AT_SYMLINK_FOLLOW = 0x4 |
Matteo Scandolo | a6a3aee | 2019-11-26 13:30:14 -0700 | [diff] [blame] | 442 | AT_SYMLINK_NOFOLLOW = 0x2 |
| 443 | ) |
| 444 | |
| 445 | type PollFd struct { |
| 446 | Fd int32 |
| 447 | Events int16 |
| 448 | Revents int16 |
| 449 | } |
| 450 | |
| 451 | const ( |
| 452 | POLLERR = 0x8 |
| 453 | POLLHUP = 0x10 |
| 454 | POLLIN = 0x1 |
| 455 | POLLNVAL = 0x20 |
| 456 | POLLOUT = 0x4 |
| 457 | POLLPRI = 0x2 |
| 458 | POLLRDBAND = 0x80 |
| 459 | POLLRDNORM = 0x40 |
| 460 | POLLWRBAND = 0x100 |
| 461 | POLLWRNORM = 0x4 |
| 462 | ) |
| 463 | |
| 464 | type Sigset_t uint32 |
| 465 | |
| 466 | type Utsname struct { |
| 467 | Sysname [256]byte |
| 468 | Nodename [256]byte |
| 469 | Release [256]byte |
| 470 | Version [256]byte |
| 471 | Machine [256]byte |
| 472 | } |
| 473 | |
| 474 | const SizeofUvmexp = 0x158 |
| 475 | |
| 476 | type Uvmexp struct { |
| 477 | Pagesize int32 |
| 478 | Pagemask int32 |
| 479 | Pageshift int32 |
| 480 | Npages int32 |
| 481 | Free int32 |
| 482 | Active int32 |
| 483 | Inactive int32 |
| 484 | Paging int32 |
| 485 | Wired int32 |
| 486 | Zeropages int32 |
| 487 | Reserve_pagedaemon int32 |
| 488 | Reserve_kernel int32 |
| 489 | Anonpages int32 |
| 490 | Vnodepages int32 |
| 491 | Vtextpages int32 |
| 492 | Freemin int32 |
| 493 | Freetarg int32 |
| 494 | Inactarg int32 |
| 495 | Wiredmax int32 |
| 496 | Anonmin int32 |
| 497 | Vtextmin int32 |
| 498 | Vnodemin int32 |
| 499 | Anonminpct int32 |
| 500 | Vtextminpct int32 |
| 501 | Vnodeminpct int32 |
| 502 | Nswapdev int32 |
| 503 | Swpages int32 |
| 504 | Swpginuse int32 |
| 505 | Swpgonly int32 |
| 506 | Nswget int32 |
| 507 | Nanon int32 |
| 508 | Nanonneeded int32 |
| 509 | Nfreeanon int32 |
| 510 | Faults int32 |
| 511 | Traps int32 |
| 512 | Intrs int32 |
| 513 | Swtch int32 |
| 514 | Softs int32 |
| 515 | Syscalls int32 |
| 516 | Pageins int32 |
| 517 | Obsolete_swapins int32 |
| 518 | Obsolete_swapouts int32 |
| 519 | Pgswapin int32 |
| 520 | Pgswapout int32 |
| 521 | Forks int32 |
| 522 | Forks_ppwait int32 |
| 523 | Forks_sharevm int32 |
| 524 | Pga_zerohit int32 |
| 525 | Pga_zeromiss int32 |
| 526 | Zeroaborts int32 |
| 527 | Fltnoram int32 |
| 528 | Fltnoanon int32 |
| 529 | Fltnoamap int32 |
| 530 | Fltpgwait int32 |
| 531 | Fltpgrele int32 |
| 532 | Fltrelck int32 |
| 533 | Fltrelckok int32 |
| 534 | Fltanget int32 |
| 535 | Fltanretry int32 |
| 536 | Fltamcopy int32 |
| 537 | Fltnamap int32 |
| 538 | Fltnomap int32 |
| 539 | Fltlget int32 |
| 540 | Fltget int32 |
| 541 | Flt_anon int32 |
| 542 | Flt_acow int32 |
| 543 | Flt_obj int32 |
| 544 | Flt_prcopy int32 |
| 545 | Flt_przero int32 |
| 546 | Pdwoke int32 |
| 547 | Pdrevs int32 |
| 548 | Pdswout int32 |
| 549 | Pdfreed int32 |
| 550 | Pdscans int32 |
| 551 | Pdanscan int32 |
| 552 | Pdobscan int32 |
| 553 | Pdreact int32 |
| 554 | Pdbusy int32 |
| 555 | Pdpageouts int32 |
| 556 | Pdpending int32 |
| 557 | Pddeact int32 |
| 558 | Pdreanon int32 |
| 559 | Pdrevnode int32 |
| 560 | Pdrevtext int32 |
| 561 | Fpswtch int32 |
| 562 | Kmapent int32 |
| 563 | } |
| 564 | |
| 565 | const SizeofClockinfo = 0x14 |
| 566 | |
| 567 | type Clockinfo struct { |
| 568 | Hz int32 |
| 569 | Tick int32 |
| 570 | Tickadj int32 |
| 571 | Stathz int32 |
| 572 | Profhz int32 |
| 573 | } |