github.com/varialus/godfly@v0.0.0-20130904042352-1934f9f095ab/src/pkg/syscall/ztypes_darwin_386.go (about)

     1  // Created by cgo -godefs - DO NOT EDIT
     2  // cgo -godefs types_darwin.go
     3  
     4  package syscall
     5  
     6  const (
     7  	sizeofPtr      = 0x4
     8  	sizeofShort    = 0x2
     9  	sizeofInt      = 0x4
    10  	sizeofLong     = 0x4
    11  	sizeofLongLong = 0x8
    12  )
    13  
    14  type (
    15  	_C_short     int16
    16  	_C_int       int32
    17  	_C_long      int32
    18  	_C_long_long int64
    19  )
    20  
    21  type Timespec struct {
    22  	Sec  int32
    23  	Nsec int32
    24  }
    25  
    26  type Timeval struct {
    27  	Sec  int32
    28  	Usec int32
    29  }
    30  
    31  type Timeval32 [0]byte
    32  
    33  type Rusage struct {
    34  	Utime    Timeval
    35  	Stime    Timeval
    36  	Maxrss   int32
    37  	Ixrss    int32
    38  	Idrss    int32
    39  	Isrss    int32
    40  	Minflt   int32
    41  	Majflt   int32
    42  	Nswap    int32
    43  	Inblock  int32
    44  	Oublock  int32
    45  	Msgsnd   int32
    46  	Msgrcv   int32
    47  	Nsignals int32
    48  	Nvcsw    int32
    49  	Nivcsw   int32
    50  }
    51  
    52  type Rlimit struct {
    53  	Cur uint64
    54  	Max uint64
    55  }
    56  
    57  type _Gid_t uint32
    58  
    59  type Stat_t struct {
    60  	Dev           int32
    61  	Mode          uint16
    62  	Nlink         uint16
    63  	Ino           uint64
    64  	Uid           uint32
    65  	Gid           uint32
    66  	Rdev          int32
    67  	Atimespec     Timespec
    68  	Mtimespec     Timespec
    69  	Ctimespec     Timespec
    70  	Birthtimespec Timespec
    71  	Size          int64
    72  	Blocks        int64
    73  	Blksize       int32
    74  	Flags         uint32
    75  	Gen           uint32
    76  	Lspare        int32
    77  	Qspare        [2]int64
    78  }
    79  
    80  type Statfs_t struct {
    81  	Bsize       uint32
    82  	Iosize      int32
    83  	Blocks      uint64
    84  	Bfree       uint64
    85  	Bavail      uint64
    86  	Files       uint64
    87  	Ffree       uint64
    88  	Fsid        Fsid
    89  	Owner       uint32
    90  	Type        uint32
    91  	Flags       uint32
    92  	Fssubtype   uint32
    93  	Fstypename  [16]int8
    94  	Mntonname   [1024]int8
    95  	Mntfromname [1024]int8
    96  	Reserved    [8]uint32
    97  }
    98  
    99  type Flock_t struct {
   100  	Start  int64
   101  	Len    int64
   102  	Pid    int32
   103  	Type   int16
   104  	Whence int16
   105  }
   106  
   107  type Fstore_t struct {
   108  	Flags      uint32
   109  	Posmode    int32
   110  	Offset     int64
   111  	Length     int64
   112  	Bytesalloc int64
   113  }
   114  
   115  type Radvisory_t struct {
   116  	Offset int64
   117  	Count  int32
   118  }
   119  
   120  type Fbootstraptransfer_t struct {
   121  	Offset int64
   122  	Length uint32
   123  	Buffer *byte
   124  }
   125  
   126  type Log2phys_t struct {
   127  	Flags       uint32
   128  	Contigbytes int64
   129  	Devoffset   int64
   130  }
   131  
   132  type Fsid struct {
   133  	Val [2]int32
   134  }
   135  
   136  type Dirent struct {
   137  	Ino       uint64
   138  	Seekoff   uint64
   139  	Reclen    uint16
   140  	Namlen    uint16
   141  	Type      uint8
   142  	Name      [1024]int8
   143  	Pad_cgo_0 [3]byte
   144  }
   145  
   146  type RawSockaddrInet4 struct {
   147  	Len    uint8
   148  	Family uint8
   149  	Port   uint16
   150  	Addr   [4]byte /* in_addr */
   151  	Zero   [8]int8
   152  }
   153  
   154  type RawSockaddrInet6 struct {
   155  	Len      uint8
   156  	Family   uint8
   157  	Port     uint16
   158  	Flowinfo uint32
   159  	Addr     [16]byte /* in6_addr */
   160  	Scope_id uint32
   161  }
   162  
   163  type RawSockaddrUnix struct {
   164  	Len    uint8
   165  	Family uint8
   166  	Path   [104]int8
   167  }
   168  
   169  type RawSockaddrDatalink struct {
   170  	Len    uint8
   171  	Family uint8
   172  	Index  uint16
   173  	Type   uint8
   174  	Nlen   uint8
   175  	Alen   uint8
   176  	Slen   uint8
   177  	Data   [12]int8
   178  }
   179  
   180  type RawSockaddr struct {
   181  	Len    uint8
   182  	Family uint8
   183  	Data   [14]int8
   184  }
   185  
   186  type RawSockaddrAny struct {
   187  	Addr RawSockaddr
   188  	Pad  [92]int8
   189  }
   190  
   191  type _Socklen uint32
   192  
   193  type Linger struct {
   194  	Onoff  int32
   195  	Linger int32
   196  }
   197  
   198  type Iovec struct {
   199  	Base *byte
   200  	Len  uint32
   201  }
   202  
   203  type IPMreq struct {
   204  	Multiaddr [4]byte /* in_addr */
   205  	Interface [4]byte /* in_addr */
   206  }
   207  
   208  type IPv6Mreq struct {
   209  	Multiaddr [16]byte /* in6_addr */
   210  	Interface uint32
   211  }
   212  
   213  type Msghdr struct {
   214  	Name       *byte
   215  	Namelen    uint32
   216  	Iov        *Iovec
   217  	Iovlen     int32
   218  	Control    *byte
   219  	Controllen uint32
   220  	Flags      int32
   221  }
   222  
   223  type Cmsghdr struct {
   224  	Len   uint32
   225  	Level int32
   226  	Type  int32
   227  }
   228  
   229  type Inet4Pktinfo struct {
   230  	Ifindex  uint32
   231  	Spec_dst [4]byte /* in_addr */
   232  	Addr     [4]byte /* in_addr */
   233  }
   234  
   235  type Inet6Pktinfo struct {
   236  	Addr    [16]byte /* in6_addr */
   237  	Ifindex uint32
   238  }
   239  
   240  type IPv6MTUInfo struct {
   241  	Addr RawSockaddrInet6
   242  	Mtu  uint32
   243  }
   244  
   245  type ICMPv6Filter struct {
   246  	Filt [8]uint32
   247  }
   248  
   249  const (
   250  	SizeofSockaddrInet4    = 0x10
   251  	SizeofSockaddrInet6    = 0x1c
   252  	SizeofSockaddrAny      = 0x6c
   253  	SizeofSockaddrUnix     = 0x6a
   254  	SizeofSockaddrDatalink = 0x14
   255  	SizeofLinger           = 0x8
   256  	SizeofIPMreq           = 0x8
   257  	SizeofIPv6Mreq         = 0x14
   258  	SizeofMsghdr           = 0x1c
   259  	SizeofCmsghdr          = 0xc
   260  	SizeofInet4Pktinfo     = 0xc
   261  	SizeofInet6Pktinfo     = 0x14
   262  	SizeofIPv6MTUInfo      = 0x20
   263  	SizeofICMPv6Filter     = 0x20
   264  )
   265  
   266  const (
   267  	PTRACE_TRACEME = 0x0
   268  	PTRACE_CONT    = 0x7
   269  	PTRACE_KILL    = 0x8
   270  )
   271  
   272  type Kevent_t struct {
   273  	Ident  uint32
   274  	Filter int16
   275  	Flags  uint16
   276  	Fflags uint32
   277  	Data   int32
   278  	Udata  *byte
   279  }
   280  
   281  type FdSet struct {
   282  	Bits [32]int32
   283  }
   284  
   285  const (
   286  	SizeofIfMsghdr    = 0x70
   287  	SizeofIfData      = 0x60
   288  	SizeofIfaMsghdr   = 0x14
   289  	SizeofIfmaMsghdr  = 0x10
   290  	SizeofIfmaMsghdr2 = 0x14
   291  	SizeofRtMsghdr    = 0x5c
   292  	SizeofRtMetrics   = 0x38
   293  )
   294  
   295  type IfMsghdr struct {
   296  	Msglen    uint16
   297  	Version   uint8
   298  	Type      uint8
   299  	Addrs     int32
   300  	Flags     int32
   301  	Index     uint16
   302  	Pad_cgo_0 [2]byte
   303  	Data      IfData
   304  }
   305  
   306  type IfData struct {
   307  	Type       uint8
   308  	Typelen    uint8
   309  	Physical   uint8
   310  	Addrlen    uint8
   311  	Hdrlen     uint8
   312  	Recvquota  uint8
   313  	Xmitquota  uint8
   314  	Unused1    uint8
   315  	Mtu        uint32
   316  	Metric     uint32
   317  	Baudrate   uint32
   318  	Ipackets   uint32
   319  	Ierrors    uint32
   320  	Opackets   uint32
   321  	Oerrors    uint32
   322  	Collisions uint32
   323  	Ibytes     uint32
   324  	Obytes     uint32
   325  	Imcasts    uint32
   326  	Omcasts    uint32
   327  	Iqdrops    uint32
   328  	Noproto    uint32
   329  	Recvtiming uint32
   330  	Xmittiming uint32
   331  	Lastchange Timeval
   332  	Unused2    uint32
   333  	Hwassist   uint32
   334  	Reserved1  uint32
   335  	Reserved2  uint32
   336  }
   337  
   338  type IfaMsghdr struct {
   339  	Msglen    uint16
   340  	Version   uint8
   341  	Type      uint8
   342  	Addrs     int32
   343  	Flags     int32
   344  	Index     uint16
   345  	Pad_cgo_0 [2]byte
   346  	Metric    int32
   347  }
   348  
   349  type IfmaMsghdr struct {
   350  	Msglen    uint16
   351  	Version   uint8
   352  	Type      uint8
   353  	Addrs     int32
   354  	Flags     int32
   355  	Index     uint16
   356  	Pad_cgo_0 [2]byte
   357  }
   358  
   359  type IfmaMsghdr2 struct {
   360  	Msglen    uint16
   361  	Version   uint8
   362  	Type      uint8
   363  	Addrs     int32
   364  	Flags     int32
   365  	Index     uint16
   366  	Pad_cgo_0 [2]byte
   367  	Refcount  int32
   368  }
   369  
   370  type RtMsghdr struct {
   371  	Msglen    uint16
   372  	Version   uint8
   373  	Type      uint8
   374  	Index     uint16
   375  	Pad_cgo_0 [2]byte
   376  	Flags     int32
   377  	Addrs     int32
   378  	Pid       int32
   379  	Seq       int32
   380  	Errno     int32
   381  	Use       int32
   382  	Inits     uint32
   383  	Rmx       RtMetrics
   384  }
   385  
   386  type RtMetrics struct {
   387  	Locks    uint32
   388  	Mtu      uint32
   389  	Hopcount uint32
   390  	Expire   int32
   391  	Recvpipe uint32
   392  	Sendpipe uint32
   393  	Ssthresh uint32
   394  	Rtt      uint32
   395  	Rttvar   uint32
   396  	Pksent   uint32
   397  	Filler   [4]uint32
   398  }
   399  
   400  const (
   401  	SizeofBpfVersion = 0x4
   402  	SizeofBpfStat    = 0x8
   403  	SizeofBpfProgram = 0x8
   404  	SizeofBpfInsn    = 0x8
   405  	SizeofBpfHdr     = 0x14
   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  	Insns *BpfInsn
   421  }
   422  
   423  type BpfInsn struct {
   424  	Code uint16
   425  	Jt   uint8
   426  	Jf   uint8
   427  	K    uint32
   428  }
   429  
   430  type BpfHdr struct {
   431  	Tstamp    Timeval
   432  	Caplen    uint32
   433  	Datalen   uint32
   434  	Hdrlen    uint16
   435  	Pad_cgo_0 [2]byte
   436  }
   437  
   438  type Termios struct {
   439  	Iflag  uint32
   440  	Oflag  uint32
   441  	Cflag  uint32
   442  	Lflag  uint32
   443  	Cc     [20]uint8
   444  	Ispeed uint32
   445  	Ospeed uint32
   446  }