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