Source file src/syscall/ztypes_freebsd_386.go

     1  // Code generated by cmd/cgo -godefs; DO NOT EDIT.
     2  // cgo -godefs types_freebsd.go | go run mkpost.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 Rusage struct {
    32  	Utime    Timeval
    33  	Stime    Timeval
    34  	Maxrss   int32
    35  	Ixrss    int32
    36  	Idrss    int32
    37  	Isrss    int32
    38  	Minflt   int32
    39  	Majflt   int32
    40  	Nswap    int32
    41  	Inblock  int32
    42  	Oublock  int32
    43  	Msgsnd   int32
    44  	Msgrcv   int32
    45  	Nsignals int32
    46  	Nvcsw    int32
    47  	Nivcsw   int32
    48  }
    49  
    50  type Rlimit struct {
    51  	Cur int64
    52  	Max int64
    53  }
    54  
    55  type _Gid_t uint32
    56  
    57  const (
    58  	S_IFMT   = 0xf000
    59  	S_IFIFO  = 0x1000
    60  	S_IFCHR  = 0x2000
    61  	S_IFDIR  = 0x4000
    62  	S_IFBLK  = 0x6000
    63  	S_IFREG  = 0x8000
    64  	S_IFLNK  = 0xa000
    65  	S_IFSOCK = 0xc000
    66  	S_ISUID  = 0x800
    67  	S_ISGID  = 0x400
    68  	S_ISVTX  = 0x200
    69  	S_IRUSR  = 0x100
    70  	S_IWUSR  = 0x80
    71  	S_IXUSR  = 0x40
    72  	S_IRWXG  = 0x38
    73  	S_IRWXO  = 0x7
    74  )
    75  
    76  const (
    77  	_statfsVersion = 0x20140518
    78  	_dirblksiz     = 0x400
    79  )
    80  
    81  type Stat_t struct {
    82  	Dev           uint64
    83  	Ino           uint64
    84  	Nlink         uint64
    85  	Mode          uint16
    86  	Padding0      int16
    87  	Uid           uint32
    88  	Gid           uint32
    89  	Padding1      int32
    90  	Rdev          uint64
    91  	Atim_ext      int32
    92  	Atimespec     Timespec
    93  	Mtim_ext      int32
    94  	Mtimespec     Timespec
    95  	Ctim_ext      int32
    96  	Ctimespec     Timespec
    97  	Btim_ext      int32
    98  	Birthtimespec Timespec
    99  	Size          int64
   100  	Blocks        int64
   101  	Blksize       int32
   102  	Flags         uint32
   103  	Gen           uint64
   104  	Spare         [10]uint64
   105  }
   106  
   107  type Statfs_t struct {
   108  	Version     uint32
   109  	Type        uint32
   110  	Flags       uint64
   111  	Bsize       uint64
   112  	Iosize      uint64
   113  	Blocks      uint64
   114  	Bfree       uint64
   115  	Bavail      int64
   116  	Files       uint64
   117  	Ffree       int64
   118  	Syncwrites  uint64
   119  	Asyncwrites uint64
   120  	Syncreads   uint64
   121  	Asyncreads  uint64
   122  	Spare       [10]uint64
   123  	Namemax     uint32
   124  	Owner       uint32
   125  	Fsid        Fsid
   126  	Charspare   [80]int8
   127  	Fstypename  [16]int8
   128  	Mntfromname [1024]int8
   129  	Mntonname   [1024]int8
   130  }
   131  
   132  type Flock_t struct {
   133  	Start  int64
   134  	Len    int64
   135  	Pid    int32
   136  	Type   int16
   137  	Whence int16
   138  	Sysid  int32
   139  }
   140  
   141  type Dirent struct {
   142  	Fileno uint64
   143  	Off    int64
   144  	Reclen uint16
   145  	Type   uint8
   146  	Pad0   uint8
   147  	Namlen uint16
   148  	Pad1   uint16
   149  	Name   [256]int8
   150  }
   151  
   152  type Fsid struct {
   153  	Val [2]int32
   154  }
   155  
   156  const (
   157  	pathMax = 0x400
   158  )
   159  
   160  type RawSockaddrInet4 struct {
   161  	Len    uint8
   162  	Family uint8
   163  	Port   uint16
   164  	Addr   [4]byte /* in_addr */
   165  	Zero   [8]int8
   166  }
   167  
   168  type RawSockaddrInet6 struct {
   169  	Len      uint8
   170  	Family   uint8
   171  	Port     uint16
   172  	Flowinfo uint32
   173  	Addr     [16]byte /* in6_addr */
   174  	Scope_id uint32
   175  }
   176  
   177  type RawSockaddrUnix struct {
   178  	Len    uint8
   179  	Family uint8
   180  	Path   [104]int8
   181  }
   182  
   183  type RawSockaddrDatalink struct {
   184  	Len    uint8
   185  	Family uint8
   186  	Index  uint16
   187  	Type   uint8
   188  	Nlen   uint8
   189  	Alen   uint8
   190  	Slen   uint8
   191  	Data   [46]int8
   192  }
   193  
   194  type RawSockaddr struct {
   195  	Len    uint8
   196  	Family uint8
   197  	Data   [14]int8
   198  }
   199  
   200  type RawSockaddrAny struct {
   201  	Addr RawSockaddr
   202  	Pad  [92]int8
   203  }
   204  
   205  type _Socklen uint32
   206  
   207  type Linger struct {
   208  	Onoff  int32
   209  	Linger int32
   210  }
   211  
   212  type Iovec struct {
   213  	Base *byte
   214  	Len  uint32
   215  }
   216  
   217  type IPMreq struct {
   218  	Multiaddr [4]byte /* in_addr */
   219  	Interface [4]byte /* in_addr */
   220  }
   221  
   222  type IPMreqn struct {
   223  	Multiaddr [4]byte /* in_addr */
   224  	Address   [4]byte /* in_addr */
   225  	Ifindex   int32
   226  }
   227  
   228  type IPv6Mreq struct {
   229  	Multiaddr [16]byte /* in6_addr */
   230  	Interface uint32
   231  }
   232  
   233  type Msghdr struct {
   234  	Name       *byte
   235  	Namelen    uint32
   236  	Iov        *Iovec
   237  	Iovlen     int32
   238  	Control    *byte
   239  	Controllen uint32
   240  	Flags      int32
   241  }
   242  
   243  type Cmsghdr struct {
   244  	Len   uint32
   245  	Level int32
   246  	Type  int32
   247  }
   248  
   249  type Inet6Pktinfo struct {
   250  	Addr    [16]byte /* in6_addr */
   251  	Ifindex uint32
   252  }
   253  
   254  type IPv6MTUInfo struct {
   255  	Addr RawSockaddrInet6
   256  	Mtu  uint32
   257  }
   258  
   259  type ICMPv6Filter struct {
   260  	Filt [8]uint32
   261  }
   262  
   263  const (
   264  	SizeofSockaddrInet4    = 0x10
   265  	SizeofSockaddrInet6    = 0x1c
   266  	SizeofSockaddrAny      = 0x6c
   267  	SizeofSockaddrUnix     = 0x6a
   268  	SizeofSockaddrDatalink = 0x36
   269  	SizeofLinger           = 0x8
   270  	SizeofIPMreq           = 0x8
   271  	SizeofIPMreqn          = 0xc
   272  	SizeofIPv6Mreq         = 0x14
   273  	SizeofMsghdr           = 0x1c
   274  	SizeofCmsghdr          = 0xc
   275  	SizeofInet6Pktinfo     = 0x14
   276  	SizeofIPv6MTUInfo      = 0x20
   277  	SizeofICMPv6Filter     = 0x20
   278  )
   279  
   280  const (
   281  	PTRACE_TRACEME = 0x0
   282  	PTRACE_CONT    = 0x7
   283  	PTRACE_KILL    = 0x8
   284  )
   285  
   286  type Kevent_t struct {
   287  	Ident  uint32
   288  	Filter int16
   289  	Flags  uint16
   290  	Fflags uint32
   291  	Data   int32
   292  	Udata  *byte
   293  }
   294  
   295  type FdSet struct {
   296  	X__fds_bits [32]uint32
   297  }
   298  
   299  const (
   300  	sizeofIfMsghdr         = 0x64
   301  	SizeofIfMsghdr         = 0x60
   302  	sizeofIfData           = 0x54
   303  	SizeofIfData           = 0x50
   304  	SizeofIfaMsghdr        = 0x14
   305  	SizeofIfmaMsghdr       = 0x10
   306  	SizeofIfAnnounceMsghdr = 0x18
   307  	SizeofRtMsghdr         = 0x5c
   308  	SizeofRtMetrics        = 0x38
   309  )
   310  
   311  type ifMsghdr struct {
   312  	Msglen    uint16
   313  	Version   uint8
   314  	Type      uint8
   315  	Addrs     int32
   316  	Flags     int32
   317  	Index     uint16
   318  	Pad_cgo_0 [2]byte
   319  	Data      ifData
   320  }
   321  
   322  type IfMsghdr struct {
   323  	Msglen    uint16
   324  	Version   uint8
   325  	Type      uint8
   326  	Addrs     int32
   327  	Flags     int32
   328  	Index     uint16
   329  	Pad_cgo_0 [2]byte
   330  	Data      IfData
   331  }
   332  
   333  type ifData struct {
   334  	Type        uint8
   335  	Physical    uint8
   336  	Addrlen     uint8
   337  	Hdrlen      uint8
   338  	Link_state  uint8
   339  	Vhid        uint8
   340  	Baudrate_pf uint8
   341  	Datalen     uint8
   342  	Mtu         uint32
   343  	Metric      uint32
   344  	Baudrate    uint32
   345  	Ipackets    uint32
   346  	Ierrors     uint32
   347  	Opackets    uint32
   348  	Oerrors     uint32
   349  	Collisions  uint32
   350  	Ibytes      uint32
   351  	Obytes      uint32
   352  	Imcasts     uint32
   353  	Omcasts     uint32
   354  	Iqdrops     uint32
   355  	Noproto     uint32
   356  	Hwassist    uint64
   357  	Epoch       int32
   358  	Lastchange  Timeval
   359  }
   360  
   361  type IfData struct {
   362  	Type        uint8
   363  	Physical    uint8
   364  	Addrlen     uint8
   365  	Hdrlen      uint8
   366  	Link_state  uint8
   367  	Spare_char1 uint8
   368  	Spare_char2 uint8
   369  	Datalen     uint8
   370  	Mtu         uint32
   371  	Metric      uint32
   372  	Baudrate    uint32
   373  	Ipackets    uint32
   374  	Ierrors     uint32
   375  	Opackets    uint32
   376  	Oerrors     uint32
   377  	Collisions  uint32
   378  	Ibytes      uint32
   379  	Obytes      uint32
   380  	Imcasts     uint32
   381  	Omcasts     uint32
   382  	Iqdrops     uint32
   383  	Noproto     uint32
   384  	Hwassist    uint32
   385  	Epoch       int32
   386  	Lastchange  Timeval
   387  }
   388  
   389  type IfaMsghdr struct {
   390  	Msglen    uint16
   391  	Version   uint8
   392  	Type      uint8
   393  	Addrs     int32
   394  	Flags     int32
   395  	Index     uint16
   396  	Pad_cgo_0 [2]byte
   397  	Metric    int32
   398  }
   399  
   400  type IfmaMsghdr struct {
   401  	Msglen    uint16
   402  	Version   uint8
   403  	Type      uint8
   404  	Addrs     int32
   405  	Flags     int32
   406  	Index     uint16
   407  	Pad_cgo_0 [2]byte
   408  }
   409  
   410  type IfAnnounceMsghdr struct {
   411  	Msglen  uint16
   412  	Version uint8
   413  	Type    uint8
   414  	Index   uint16
   415  	Name    [16]int8
   416  	What    uint16
   417  }
   418  
   419  type RtMsghdr struct {
   420  	Msglen    uint16
   421  	Version   uint8
   422  	Type      uint8
   423  	Index     uint16
   424  	Pad_cgo_0 [2]byte
   425  	Flags     int32
   426  	Addrs     int32
   427  	Pid       int32
   428  	Seq       int32
   429  	Errno     int32
   430  	Fmask     int32
   431  	Inits     uint32
   432  	Rmx       RtMetrics
   433  }
   434  
   435  type RtMetrics struct {
   436  	Locks    uint32
   437  	Mtu      uint32
   438  	Hopcount uint32
   439  	Expire   uint32
   440  	Recvpipe uint32
   441  	Sendpipe uint32
   442  	Ssthresh uint32
   443  	Rtt      uint32
   444  	Rttvar   uint32
   445  	Pksent   uint32
   446  	Weight   uint32
   447  	Filler   [3]uint32
   448  }
   449  
   450  const (
   451  	SizeofBpfVersion    = 0x4
   452  	SizeofBpfStat       = 0x8
   453  	SizeofBpfZbuf       = 0xc
   454  	SizeofBpfProgram    = 0x8
   455  	SizeofBpfInsn       = 0x8
   456  	SizeofBpfHdr        = 0x14
   457  	SizeofBpfZbufHeader = 0x20
   458  )
   459  
   460  type BpfVersion struct {
   461  	Major uint16
   462  	Minor uint16
   463  }
   464  
   465  type BpfStat struct {
   466  	Recv uint32
   467  	Drop uint32
   468  }
   469  
   470  type BpfZbuf struct {
   471  	Bufa   *byte
   472  	Bufb   *byte
   473  	Buflen uint32
   474  }
   475  
   476  type BpfProgram struct {
   477  	Len   uint32
   478  	Insns *BpfInsn
   479  }
   480  
   481  type BpfInsn struct {
   482  	Code uint16
   483  	Jt   uint8
   484  	Jf   uint8
   485  	K    uint32
   486  }
   487  
   488  type BpfHdr struct {
   489  	Tstamp    Timeval
   490  	Caplen    uint32
   491  	Datalen   uint32
   492  	Hdrlen    uint16
   493  	Pad_cgo_0 [2]byte
   494  }
   495  
   496  type BpfZbufHeader struct {
   497  	Kernel_gen uint32
   498  	Kernel_len uint32
   499  	User_gen   uint32
   500  	X_bzh_pad  [5]uint32
   501  }
   502  
   503  const (
   504  	_AT_FDCWD            = -0x64
   505  	_AT_SYMLINK_FOLLOW   = 0x400
   506  	_AT_SYMLINK_NOFOLLOW = 0x200
   507  )
   508  
   509  type Termios struct {
   510  	Iflag  uint32
   511  	Oflag  uint32
   512  	Cflag  uint32
   513  	Lflag  uint32
   514  	Cc     [20]uint8
   515  	Ispeed uint32
   516  	Ospeed uint32
   517  }
   518  

View as plain text