blob: 2a8b1e6f73f5197531c913487b9ad316ebb1f678 [file] [log] [blame]
Don Newton98fd8812019-09-23 15:15:02 -04001// 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. Bainbridgee05cf0c2021-08-19 03:16:50 +00004//go:build 386 && openbsd
Don Newton98fd8812019-09-23 15:15:02 -04005// +build 386,openbsd
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 int64
26 Nsec int32
27}
28
29type Timeval struct {
30 Sec int64
31 Usec int32
32}
33
34type 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
53type Rlimit struct {
54 Cur uint64
55 Max uint64
56}
57
58type _Gid_t uint32
59
60type 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
79type 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
105type Flock_t struct {
106 Start int64
107 Len int64
108 Pid int32
109 Type int16
110 Whence int16
111}
112
113type 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
123type Fsid struct {
124 Val [2]int32
125}
126
127const (
128 PathMax = 0x400
129)
130
131type RawSockaddrInet4 struct {
132 Len uint8
133 Family uint8
134 Port uint16
135 Addr [4]byte /* in_addr */
136 Zero [8]int8
137}
138
139type 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
148type RawSockaddrUnix struct {
149 Len uint8
150 Family uint8
151 Path [104]int8
152}
153
154type 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
165type RawSockaddr struct {
166 Len uint8
167 Family uint8
168 Data [14]int8
169}
170
171type RawSockaddrAny struct {
172 Addr RawSockaddr
173 Pad [92]int8
174}
175
176type _Socklen uint32
177
178type Linger struct {
179 Onoff int32
180 Linger int32
181}
182
183type Iovec struct {
184 Base *byte
185 Len uint32
186}
187
188type IPMreq struct {
189 Multiaddr [4]byte /* in_addr */
190 Interface [4]byte /* in_addr */
191}
192
193type IPv6Mreq struct {
194 Multiaddr [16]byte /* in6_addr */
195 Interface uint32
196}
197
198type 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
208type Cmsghdr struct {
209 Len uint32
210 Level int32
211 Type int32
212}
213
214type Inet6Pktinfo struct {
215 Addr [16]byte /* in6_addr */
216 Ifindex uint32
217}
218
219type IPv6MTUInfo struct {
220 Addr RawSockaddrInet6
221 Mtu uint32
222}
223
224type ICMPv6Filter struct {
225 Filt [8]uint32
226}
227
228const (
229 SizeofSockaddrInet4 = 0x10
230 SizeofSockaddrInet6 = 0x1c
231 SizeofSockaddrAny = 0x6c
232 SizeofSockaddrUnix = 0x6a
233 SizeofSockaddrDatalink = 0x20
234 SizeofLinger = 0x8
David K. Bainbridgee05cf0c2021-08-19 03:16:50 +0000235 SizeofIovec = 0x8
Don Newton98fd8812019-09-23 15:15:02 -0400236 SizeofIPMreq = 0x8
237 SizeofIPv6Mreq = 0x14
238 SizeofMsghdr = 0x1c
239 SizeofCmsghdr = 0xc
240 SizeofInet6Pktinfo = 0x14
241 SizeofIPv6MTUInfo = 0x20
242 SizeofICMPv6Filter = 0x20
243)
244
245const (
246 PTRACE_TRACEME = 0x0
247 PTRACE_CONT = 0x7
248 PTRACE_KILL = 0x8
249)
250
251type Kevent_t struct {
252 Ident uint32
253 Filter int16
254 Flags uint16
255 Fflags uint32
256 Data int64
257 Udata *byte
258}
259
260type FdSet struct {
261 Bits [32]uint32
262}
263
264const (
265 SizeofIfMsghdr = 0xec
266 SizeofIfData = 0xd4
267 SizeofIfaMsghdr = 0x18
268 SizeofIfAnnounceMsghdr = 0x1a
269 SizeofRtMsghdr = 0x60
270 SizeofRtMetrics = 0x38
271)
272
273type 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
288type 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
313type 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
327type 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
337type 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
356type 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
371type Mclpool struct {
372 Grown int32
373 Alive uint16
374 Hwm uint16
375 Cwm uint16
376 Lwm uint16
377}
378
379const (
380 SizeofBpfVersion = 0x4
381 SizeofBpfStat = 0x8
382 SizeofBpfProgram = 0x8
383 SizeofBpfInsn = 0x8
384 SizeofBpfHdr = 0x14
385)
386
387type BpfVersion struct {
388 Major uint16
389 Minor uint16
390}
391
392type BpfStat struct {
393 Recv uint32
394 Drop uint32
395}
396
397type BpfProgram struct {
398 Len uint32
399 Insns *BpfInsn
400}
401
402type BpfInsn struct {
403 Code uint16
404 Jt uint8
405 Jf uint8
406 K uint32
407}
408
409type BpfHdr struct {
410 Tstamp BpfTimeval
411 Caplen uint32
412 Datalen uint32
413 Hdrlen uint16
414 Pad_cgo_0 [2]byte
415}
416
417type BpfTimeval struct {
418 Sec uint32
419 Usec uint32
420}
421
422type 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
432type Winsize struct {
433 Row uint16
434 Col uint16
435 Xpixel uint16
436 Ypixel uint16
437}
438
439const (
440 AT_FDCWD = -0x64
David K. Bainbridgee05cf0c2021-08-19 03:16:50 +0000441 AT_EACCESS = 0x1
Don Newton98fd8812019-09-23 15:15:02 -0400442 AT_SYMLINK_NOFOLLOW = 0x2
David K. Bainbridgee05cf0c2021-08-19 03:16:50 +0000443 AT_SYMLINK_FOLLOW = 0x4
444 AT_REMOVEDIR = 0x8
Don Newton98fd8812019-09-23 15:15:02 -0400445)
446
447type PollFd struct {
448 Fd int32
449 Events int16
450 Revents int16
451}
452
453const (
454 POLLERR = 0x8
455 POLLHUP = 0x10
456 POLLIN = 0x1
457 POLLNVAL = 0x20
458 POLLOUT = 0x4
459 POLLPRI = 0x2
460 POLLRDBAND = 0x80
461 POLLRDNORM = 0x40
462 POLLWRBAND = 0x100
463 POLLWRNORM = 0x4
464)
465
466type Sigset_t uint32
467
468type Utsname struct {
469 Sysname [256]byte
470 Nodename [256]byte
471 Release [256]byte
472 Version [256]byte
473 Machine [256]byte
474}
475
476const SizeofUvmexp = 0x158
477
478type Uvmexp struct {
479 Pagesize int32
480 Pagemask int32
481 Pageshift int32
482 Npages int32
483 Free int32
484 Active int32
485 Inactive int32
486 Paging int32
487 Wired int32
488 Zeropages int32
489 Reserve_pagedaemon int32
490 Reserve_kernel int32
491 Anonpages int32
492 Vnodepages int32
493 Vtextpages int32
494 Freemin int32
495 Freetarg int32
496 Inactarg int32
497 Wiredmax int32
498 Anonmin int32
499 Vtextmin int32
500 Vnodemin int32
501 Anonminpct int32
502 Vtextminpct int32
503 Vnodeminpct int32
504 Nswapdev int32
505 Swpages int32
506 Swpginuse int32
507 Swpgonly int32
508 Nswget int32
509 Nanon int32
510 Nanonneeded int32
511 Nfreeanon int32
512 Faults int32
513 Traps int32
514 Intrs int32
515 Swtch int32
516 Softs int32
517 Syscalls int32
518 Pageins int32
519 Obsolete_swapins int32
520 Obsolete_swapouts int32
521 Pgswapin int32
522 Pgswapout int32
523 Forks int32
524 Forks_ppwait int32
525 Forks_sharevm int32
526 Pga_zerohit int32
527 Pga_zeromiss int32
528 Zeroaborts int32
529 Fltnoram int32
530 Fltnoanon int32
531 Fltnoamap int32
532 Fltpgwait int32
533 Fltpgrele int32
534 Fltrelck int32
535 Fltrelckok int32
536 Fltanget int32
537 Fltanretry int32
538 Fltamcopy int32
539 Fltnamap int32
540 Fltnomap int32
541 Fltlget int32
542 Fltget int32
543 Flt_anon int32
544 Flt_acow int32
545 Flt_obj int32
546 Flt_prcopy int32
547 Flt_przero int32
548 Pdwoke int32
549 Pdrevs int32
550 Pdswout int32
551 Pdfreed int32
552 Pdscans int32
553 Pdanscan int32
554 Pdobscan int32
555 Pdreact int32
556 Pdbusy int32
557 Pdpageouts int32
558 Pdpending int32
559 Pddeact int32
560 Pdreanon int32
561 Pdrevnode int32
562 Pdrevtext int32
563 Fpswtch int32
564 Kmapent int32
565}
Don Newton7577f072020-01-06 12:41:11 -0500566
567const SizeofClockinfo = 0x14
568
569type Clockinfo struct {
570 Hz int32
571 Tick int32
572 Tickadj int32
573 Stathz int32
574 Profhz int32
575}