github.com/kooksee/kchain@v0.0.0-20180613035215-4aef51c04906/src/golang.org/x/sys/unix/ztypes_linux_amd64.go (about) 1 // cgo -godefs -- -Wall -Werror -static -I/tmp/include -m64 linux/types.go | go run mkpost.go 2 // Code generated by the command above; see README.md. DO NOT EDIT. 3 4 // +build amd64,linux 5 6 package unix 7 8 const ( 9 sizeofPtr = 0x8 10 sizeofShort = 0x2 11 sizeofInt = 0x4 12 sizeofLong = 0x8 13 sizeofLongLong = 0x8 14 PathMax = 0x1000 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 int64 32 } 33 34 type Timex struct { 35 Modes uint32 36 Pad_cgo_0 [4]byte 37 Offset int64 38 Freq int64 39 Maxerror int64 40 Esterror int64 41 Status int32 42 Pad_cgo_1 [4]byte 43 Constant int64 44 Precision int64 45 Tolerance int64 46 Time Timeval 47 Tick int64 48 Ppsfreq int64 49 Jitter int64 50 Shift int32 51 Pad_cgo_2 [4]byte 52 Stabil int64 53 Jitcnt int64 54 Calcnt int64 55 Errcnt int64 56 Stbcnt int64 57 Tai int32 58 Pad_cgo_3 [44]byte 59 } 60 61 type Time_t int64 62 63 type Tms struct { 64 Utime int64 65 Stime int64 66 Cutime int64 67 Cstime int64 68 } 69 70 type Utimbuf struct { 71 Actime int64 72 Modtime int64 73 } 74 75 type Rusage struct { 76 Utime Timeval 77 Stime Timeval 78 Maxrss int64 79 Ixrss int64 80 Idrss int64 81 Isrss int64 82 Minflt int64 83 Majflt int64 84 Nswap int64 85 Inblock int64 86 Oublock int64 87 Msgsnd int64 88 Msgrcv int64 89 Nsignals int64 90 Nvcsw int64 91 Nivcsw int64 92 } 93 94 type Rlimit struct { 95 Cur uint64 96 Max uint64 97 } 98 99 type _Gid_t uint32 100 101 type Stat_t struct { 102 Dev uint64 103 Ino uint64 104 Nlink uint64 105 Mode uint32 106 Uid uint32 107 Gid uint32 108 X__pad0 int32 109 Rdev uint64 110 Size int64 111 Blksize int64 112 Blocks int64 113 Atim Timespec 114 Mtim Timespec 115 Ctim Timespec 116 _ [3]int64 117 } 118 119 type Statfs_t struct { 120 Type int64 121 Bsize int64 122 Blocks uint64 123 Bfree uint64 124 Bavail uint64 125 Files uint64 126 Ffree uint64 127 Fsid Fsid 128 Namelen int64 129 Frsize int64 130 Flags int64 131 Spare [4]int64 132 } 133 134 type Dirent struct { 135 Ino uint64 136 Off int64 137 Reclen uint16 138 Type uint8 139 Name [256]int8 140 Pad_cgo_0 [5]byte 141 } 142 143 type Fsid struct { 144 X__val [2]int32 145 } 146 147 type Flock_t struct { 148 Type int16 149 Whence int16 150 Pad_cgo_0 [4]byte 151 Start int64 152 Len int64 153 Pid int32 154 Pad_cgo_1 [4]byte 155 } 156 157 type FscryptPolicy struct { 158 Version uint8 159 Contents_encryption_mode uint8 160 Filenames_encryption_mode uint8 161 Flags uint8 162 Master_key_descriptor [8]uint8 163 } 164 165 type FscryptKey struct { 166 Mode uint32 167 Raw [64]uint8 168 Size uint32 169 } 170 171 type KeyctlDHParams struct { 172 Private int32 173 Prime int32 174 Base int32 175 } 176 177 const ( 178 FADV_NORMAL = 0x0 179 FADV_RANDOM = 0x1 180 FADV_SEQUENTIAL = 0x2 181 FADV_WILLNEED = 0x3 182 FADV_DONTNEED = 0x4 183 FADV_NOREUSE = 0x5 184 ) 185 186 type RawSockaddrInet4 struct { 187 Family uint16 188 Port uint16 189 Addr [4]byte /* in_addr */ 190 Zero [8]uint8 191 } 192 193 type RawSockaddrInet6 struct { 194 Family uint16 195 Port uint16 196 Flowinfo uint32 197 Addr [16]byte /* in6_addr */ 198 Scope_id uint32 199 } 200 201 type RawSockaddrUnix struct { 202 Family uint16 203 Path [108]int8 204 } 205 206 type RawSockaddrLinklayer struct { 207 Family uint16 208 Protocol uint16 209 Ifindex int32 210 Hatype uint16 211 Pkttype uint8 212 Halen uint8 213 Addr [8]uint8 214 } 215 216 type RawSockaddrNetlink struct { 217 Family uint16 218 Pad uint16 219 Pid uint32 220 Groups uint32 221 } 222 223 type RawSockaddrHCI struct { 224 Family uint16 225 Dev uint16 226 Channel uint16 227 } 228 229 type RawSockaddrCAN struct { 230 Family uint16 231 Pad_cgo_0 [2]byte 232 Ifindex int32 233 Addr [8]byte 234 } 235 236 type RawSockaddrALG struct { 237 Family uint16 238 Type [14]uint8 239 Feat uint32 240 Mask uint32 241 Name [64]uint8 242 } 243 244 type RawSockaddrVM struct { 245 Family uint16 246 Reserved1 uint16 247 Port uint32 248 Cid uint32 249 Zero [4]uint8 250 } 251 252 type RawSockaddr struct { 253 Family uint16 254 Data [14]int8 255 } 256 257 type RawSockaddrAny struct { 258 Addr RawSockaddr 259 Pad [96]int8 260 } 261 262 type _Socklen uint32 263 264 type Linger struct { 265 Onoff int32 266 Linger int32 267 } 268 269 type Iovec struct { 270 Base *byte 271 Len uint64 272 } 273 274 type IPMreq struct { 275 Multiaddr [4]byte /* in_addr */ 276 Interface [4]byte /* in_addr */ 277 } 278 279 type IPMreqn struct { 280 Multiaddr [4]byte /* in_addr */ 281 Address [4]byte /* in_addr */ 282 Ifindex int32 283 } 284 285 type IPv6Mreq struct { 286 Multiaddr [16]byte /* in6_addr */ 287 Interface uint32 288 } 289 290 type Msghdr struct { 291 Name *byte 292 Namelen uint32 293 Pad_cgo_0 [4]byte 294 Iov *Iovec 295 Iovlen uint64 296 Control *byte 297 Controllen uint64 298 Flags int32 299 Pad_cgo_1 [4]byte 300 } 301 302 type Cmsghdr struct { 303 Len uint64 304 Level int32 305 Type int32 306 } 307 308 type Inet4Pktinfo struct { 309 Ifindex int32 310 Spec_dst [4]byte /* in_addr */ 311 Addr [4]byte /* in_addr */ 312 } 313 314 type Inet6Pktinfo struct { 315 Addr [16]byte /* in6_addr */ 316 Ifindex uint32 317 } 318 319 type IPv6MTUInfo struct { 320 Addr RawSockaddrInet6 321 Mtu uint32 322 } 323 324 type ICMPv6Filter struct { 325 Data [8]uint32 326 } 327 328 type Ucred struct { 329 Pid int32 330 Uid uint32 331 Gid uint32 332 } 333 334 type TCPInfo struct { 335 State uint8 336 Ca_state uint8 337 Retransmits uint8 338 Probes uint8 339 Backoff uint8 340 Options uint8 341 Pad_cgo_0 [2]byte 342 Rto uint32 343 Ato uint32 344 Snd_mss uint32 345 Rcv_mss uint32 346 Unacked uint32 347 Sacked uint32 348 Lost uint32 349 Retrans uint32 350 Fackets uint32 351 Last_data_sent uint32 352 Last_ack_sent uint32 353 Last_data_recv uint32 354 Last_ack_recv uint32 355 Pmtu uint32 356 Rcv_ssthresh uint32 357 Rtt uint32 358 Rttvar uint32 359 Snd_ssthresh uint32 360 Snd_cwnd uint32 361 Advmss uint32 362 Reordering uint32 363 Rcv_rtt uint32 364 Rcv_space uint32 365 Total_retrans uint32 366 } 367 368 const ( 369 SizeofSockaddrInet4 = 0x10 370 SizeofSockaddrInet6 = 0x1c 371 SizeofSockaddrAny = 0x70 372 SizeofSockaddrUnix = 0x6e 373 SizeofSockaddrLinklayer = 0x14 374 SizeofSockaddrNetlink = 0xc 375 SizeofSockaddrHCI = 0x6 376 SizeofSockaddrCAN = 0x10 377 SizeofSockaddrALG = 0x58 378 SizeofSockaddrVM = 0x10 379 SizeofLinger = 0x8 380 SizeofIPMreq = 0x8 381 SizeofIPMreqn = 0xc 382 SizeofIPv6Mreq = 0x14 383 SizeofMsghdr = 0x38 384 SizeofCmsghdr = 0x10 385 SizeofInet4Pktinfo = 0xc 386 SizeofInet6Pktinfo = 0x14 387 SizeofIPv6MTUInfo = 0x20 388 SizeofICMPv6Filter = 0x20 389 SizeofUcred = 0xc 390 SizeofTCPInfo = 0x68 391 ) 392 393 const ( 394 IFA_UNSPEC = 0x0 395 IFA_ADDRESS = 0x1 396 IFA_LOCAL = 0x2 397 IFA_LABEL = 0x3 398 IFA_BROADCAST = 0x4 399 IFA_ANYCAST = 0x5 400 IFA_CACHEINFO = 0x6 401 IFA_MULTICAST = 0x7 402 IFLA_UNSPEC = 0x0 403 IFLA_ADDRESS = 0x1 404 IFLA_BROADCAST = 0x2 405 IFLA_IFNAME = 0x3 406 IFLA_MTU = 0x4 407 IFLA_LINK = 0x5 408 IFLA_QDISC = 0x6 409 IFLA_STATS = 0x7 410 IFLA_COST = 0x8 411 IFLA_PRIORITY = 0x9 412 IFLA_MASTER = 0xa 413 IFLA_WIRELESS = 0xb 414 IFLA_PROTINFO = 0xc 415 IFLA_TXQLEN = 0xd 416 IFLA_MAP = 0xe 417 IFLA_WEIGHT = 0xf 418 IFLA_OPERSTATE = 0x10 419 IFLA_LINKMODE = 0x11 420 IFLA_LINKINFO = 0x12 421 IFLA_NET_NS_PID = 0x13 422 IFLA_IFALIAS = 0x14 423 IFLA_MAX = 0x2b 424 RT_SCOPE_UNIVERSE = 0x0 425 RT_SCOPE_SITE = 0xc8 426 RT_SCOPE_LINK = 0xfd 427 RT_SCOPE_HOST = 0xfe 428 RT_SCOPE_NOWHERE = 0xff 429 RT_TABLE_UNSPEC = 0x0 430 RT_TABLE_COMPAT = 0xfc 431 RT_TABLE_DEFAULT = 0xfd 432 RT_TABLE_MAIN = 0xfe 433 RT_TABLE_LOCAL = 0xff 434 RT_TABLE_MAX = 0xffffffff 435 RTA_UNSPEC = 0x0 436 RTA_DST = 0x1 437 RTA_SRC = 0x2 438 RTA_IIF = 0x3 439 RTA_OIF = 0x4 440 RTA_GATEWAY = 0x5 441 RTA_PRIORITY = 0x6 442 RTA_PREFSRC = 0x7 443 RTA_METRICS = 0x8 444 RTA_MULTIPATH = 0x9 445 RTA_FLOW = 0xb 446 RTA_CACHEINFO = 0xc 447 RTA_TABLE = 0xf 448 RTN_UNSPEC = 0x0 449 RTN_UNICAST = 0x1 450 RTN_LOCAL = 0x2 451 RTN_BROADCAST = 0x3 452 RTN_ANYCAST = 0x4 453 RTN_MULTICAST = 0x5 454 RTN_BLACKHOLE = 0x6 455 RTN_UNREACHABLE = 0x7 456 RTN_PROHIBIT = 0x8 457 RTN_THROW = 0x9 458 RTN_NAT = 0xa 459 RTN_XRESOLVE = 0xb 460 RTNLGRP_NONE = 0x0 461 RTNLGRP_LINK = 0x1 462 RTNLGRP_NOTIFY = 0x2 463 RTNLGRP_NEIGH = 0x3 464 RTNLGRP_TC = 0x4 465 RTNLGRP_IPV4_IFADDR = 0x5 466 RTNLGRP_IPV4_MROUTE = 0x6 467 RTNLGRP_IPV4_ROUTE = 0x7 468 RTNLGRP_IPV4_RULE = 0x8 469 RTNLGRP_IPV6_IFADDR = 0x9 470 RTNLGRP_IPV6_MROUTE = 0xa 471 RTNLGRP_IPV6_ROUTE = 0xb 472 RTNLGRP_IPV6_IFINFO = 0xc 473 RTNLGRP_IPV6_PREFIX = 0x12 474 RTNLGRP_IPV6_RULE = 0x13 475 RTNLGRP_ND_USEROPT = 0x14 476 SizeofNlMsghdr = 0x10 477 SizeofNlMsgerr = 0x14 478 SizeofRtGenmsg = 0x1 479 SizeofNlAttr = 0x4 480 SizeofRtAttr = 0x4 481 SizeofIfInfomsg = 0x10 482 SizeofIfAddrmsg = 0x8 483 SizeofRtMsg = 0xc 484 SizeofRtNexthop = 0x8 485 ) 486 487 type NlMsghdr struct { 488 Len uint32 489 Type uint16 490 Flags uint16 491 Seq uint32 492 Pid uint32 493 } 494 495 type NlMsgerr struct { 496 Error int32 497 Msg NlMsghdr 498 } 499 500 type RtGenmsg struct { 501 Family uint8 502 } 503 504 type NlAttr struct { 505 Len uint16 506 Type uint16 507 } 508 509 type RtAttr struct { 510 Len uint16 511 Type uint16 512 } 513 514 type IfInfomsg struct { 515 Family uint8 516 X__ifi_pad uint8 517 Type uint16 518 Index int32 519 Flags uint32 520 Change uint32 521 } 522 523 type IfAddrmsg struct { 524 Family uint8 525 Prefixlen uint8 526 Flags uint8 527 Scope uint8 528 Index uint32 529 } 530 531 type RtMsg struct { 532 Family uint8 533 Dst_len uint8 534 Src_len uint8 535 Tos uint8 536 Table uint8 537 Protocol uint8 538 Scope uint8 539 Type uint8 540 Flags uint32 541 } 542 543 type RtNexthop struct { 544 Len uint16 545 Flags uint8 546 Hops uint8 547 Ifindex int32 548 } 549 550 const ( 551 SizeofSockFilter = 0x8 552 SizeofSockFprog = 0x10 553 ) 554 555 type SockFilter struct { 556 Code uint16 557 Jt uint8 558 Jf uint8 559 K uint32 560 } 561 562 type SockFprog struct { 563 Len uint16 564 Pad_cgo_0 [6]byte 565 Filter *SockFilter 566 } 567 568 type InotifyEvent struct { 569 Wd int32 570 Mask uint32 571 Cookie uint32 572 Len uint32 573 } 574 575 const SizeofInotifyEvent = 0x10 576 577 type PtraceRegs struct { 578 R15 uint64 579 R14 uint64 580 R13 uint64 581 R12 uint64 582 Rbp uint64 583 Rbx uint64 584 R11 uint64 585 R10 uint64 586 R9 uint64 587 R8 uint64 588 Rax uint64 589 Rcx uint64 590 Rdx uint64 591 Rsi uint64 592 Rdi uint64 593 Orig_rax uint64 594 Rip uint64 595 Cs uint64 596 Eflags uint64 597 Rsp uint64 598 Ss uint64 599 Fs_base uint64 600 Gs_base uint64 601 Ds uint64 602 Es uint64 603 Fs uint64 604 Gs uint64 605 } 606 607 type FdSet struct { 608 Bits [16]int64 609 } 610 611 type Sysinfo_t struct { 612 Uptime int64 613 Loads [3]uint64 614 Totalram uint64 615 Freeram uint64 616 Sharedram uint64 617 Bufferram uint64 618 Totalswap uint64 619 Freeswap uint64 620 Procs uint16 621 Pad uint16 622 Pad_cgo_0 [4]byte 623 Totalhigh uint64 624 Freehigh uint64 625 Unit uint32 626 X_f [0]int8 627 Pad_cgo_1 [4]byte 628 } 629 630 type Utsname struct { 631 Sysname [65]int8 632 Nodename [65]int8 633 Release [65]int8 634 Version [65]int8 635 Machine [65]int8 636 Domainname [65]int8 637 } 638 639 type Ustat_t struct { 640 Tfree int32 641 Pad_cgo_0 [4]byte 642 Tinode uint64 643 Fname [6]int8 644 Fpack [6]int8 645 Pad_cgo_1 [4]byte 646 } 647 648 type EpollEvent struct { 649 Events uint32 650 Fd int32 651 Pad int32 652 } 653 654 const ( 655 AT_FDCWD = -0x64 656 AT_REMOVEDIR = 0x200 657 AT_SYMLINK_FOLLOW = 0x400 658 AT_SYMLINK_NOFOLLOW = 0x100 659 ) 660 661 type PollFd struct { 662 Fd int32 663 Events int16 664 Revents int16 665 } 666 667 const ( 668 POLLIN = 0x1 669 POLLPRI = 0x2 670 POLLOUT = 0x4 671 POLLRDHUP = 0x2000 672 POLLERR = 0x8 673 POLLHUP = 0x10 674 POLLNVAL = 0x20 675 ) 676 677 type Sigset_t struct { 678 X__val [16]uint64 679 } 680 681 const RNDGETENTCNT = 0x80045200 682 683 const _SC_PAGESIZE = 0x1e 684 685 type Termios struct { 686 Iflag uint32 687 Oflag uint32 688 Cflag uint32 689 Lflag uint32 690 Line uint8 691 Cc [19]uint8 692 Ispeed uint32 693 Ospeed uint32 694 }