github.com/Aayushi-Bansal/sys@v0.0.0-20180118120756-90d962a959d8/unix/ztypes_dragonfly_amd64.go (about)

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