...
Run Format

Source file src/syscall/ztypes_freebsd_386.go

Documentation: syscall

     1  // Created by cgo -godefs - DO NOT EDIT
     2  // cgo -godefs types_freebsd.go
     3  
     4  // +build 386,freebsd
     5  
     6  package syscall
     7  
     8  const (
     9  	sizeofPtr      = 0x4
    10  	sizeofShort    = 0x2
    11  	sizeofInt      = 0x4
    12  	sizeofLong     = 0x4
    13  	sizeofLongLong = 0x8
    14  )
    15  
    16  type (
    17  	_C_short     int16
    18  	_C_int       int32
    19  	_C_long      int32
    20  	_C_long_long int64
    21  )
    22  
    23  type Timespec struct {
    24  	Sec  int32
    25  	Nsec int32
    26  }
    27  
    28  type Timeval struct {
    29  	Sec  int32
    30  	Usec int32
    31  }
    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 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  	Dev           uint32
    78  	Ino           uint32
    79  	Mode          uint16
    80  	Nlink         uint16
    81  	Uid           uint32
    82  	Gid           uint32
    83  	Rdev          uint32
    84  	Atimespec     Timespec
    85  	Mtimespec     Timespec
    86  	Ctimespec     Timespec
    87  	Size          int64
    88  	Blocks        int64
    89  	Blksize       uint32
    90  	Flags         uint32
    91  	Gen           uint32
    92  	Lspare        int32
    93  	Birthtimespec Timespec
    94  	Pad_cgo_0     [8]byte
    95  }
    96  
    97  type Statfs_t struct {
    98  	Version     uint32
    99  	Type        uint32
   100  	Flags       uint64
   101  	Bsize       uint64
   102  	Iosize      uint64
   103  	Blocks      uint64
   104  	Bfree       uint64
   105  	Bavail      int64
   106  	Files       uint64
   107  	Ffree       int64
   108  	Syncwrites  uint64
   109  	Asyncwrites uint64
   110  	Syncreads   uint64
   111  	Asyncreads  uint64
   112  	Spare       [10]uint64
   113  	Namemax     uint32
   114  	Owner       uint32
   115  	Fsid        Fsid
   116  	Charspare   [80]int8
   117  	Fstypename  [16]int8
   118  	Mntfromname [88]int8
   119  	Mntonname   [88]int8
   120  }
   121  
   122  type Flock_t struct {
   123  	Start  int64
   124  	Len    int64
   125  	Pid    int32
   126  	Type   int16
   127  	Whence int16
   128  	Sysid  int32
   129  }
   130  
   131  type Dirent struct {
   132  	Fileno uint32
   133  	Reclen uint16
   134  	Type   uint8
   135  	Namlen uint8
   136  	Name   [256]int8
   137  }
   138  
   139  type Fsid struct {
   140  	Val [2]int32
   141  }
   142  
   143  const (
   144  	pathMax = 0x400
   145  )
   146  
   147  type RawSockaddrInet4 struct {
   148  	Len    uint8
   149  	Family uint8
   150  	Port   uint16
   151  	Addr   [4]byte /* in_addr */
   152  	Zero   [8]int8
   153  }
   154  
   155  type RawSockaddrInet6 struct {
   156  	Len      uint8
   157  	Family   uint8
   158  	Port     uint16
   159  	Flowinfo uint32
   160  	Addr     [16]byte /* in6_addr */
   161  	Scope_id uint32
   162  }
   163  
   164  type RawSockaddrUnix struct {
   165  	Len    uint8
   166  	Family uint8
   167  	Path   [104]int8
   168  }
   169  
   170  type RawSockaddrDatalink struct {
   171  	Len    uint8
   172  	Family uint8
   173  	Index  uint16
   174  	Type   uint8
   175  	Nlen   uint8
   176  	Alen   uint8
   177  	Slen   uint8
   178  	Data   [46]int8
   179  }
   180  
   181  type RawSockaddr struct {
   182  	Len    uint8
   183  	Family uint8
   184  	Data   [14]int8
   185  }
   186  
   187  type RawSockaddrAny struct {
   188  	Addr RawSockaddr
   189  	Pad  [92]int8
   190  }
   191  
   192  type _Socklen uint32
   193  
   194  type Linger struct {
   195  	Onoff  int32
   196  	Linger int32
   197  }
   198  
   199  type Iovec struct {
   200  	Base *byte
   201  	Len  uint32
   202  }
   203  
   204  type IPMreq struct {
   205  	Multiaddr [4]byte /* in_addr */
   206  	Interface [4]byte /* in_addr */
   207  }
   208  
   209  type IPMreqn struct {
   210  	Multiaddr [4]byte /* in_addr */
   211  	Address   [4]byte /* in_addr */
   212  	Ifindex   int32
   213  }
   214  
   215  type IPv6Mreq struct {
   216  	Multiaddr [16]byte /* in6_addr */
   217  	Interface uint32
   218  }
   219  
   220  type Msghdr struct {
   221  	Name       *byte
   222  	Namelen    uint32
   223  	Iov        *Iovec
   224  	Iovlen     int32
   225  	Control    *byte
   226  	Controllen uint32
   227  	Flags      int32
   228  }
   229  
   230  type Cmsghdr struct {
   231  	Len   uint32
   232  	Level int32
   233  	Type  int32
   234  }
   235  
   236  type Inet6Pktinfo struct {
   237  	Addr    [16]byte /* in6_addr */
   238  	Ifindex uint32
   239  }
   240  
   241  type IPv6MTUInfo struct {
   242  	Addr RawSockaddrInet6
   243  	Mtu  uint32
   244  }
   245  
   246  type ICMPv6Filter struct {
   247  	Filt [8]uint32
   248  }
   249  
   250  const (
   251  	SizeofSockaddrInet4    = 0x10
   252  	SizeofSockaddrInet6    = 0x1c
   253  	SizeofSockaddrAny      = 0x6c
   254  	SizeofSockaddrUnix     = 0x6a
   255  	SizeofSockaddrDatalink = 0x36
   256  	SizeofLinger           = 0x8
   257  	SizeofIPMreq           = 0x8
   258  	SizeofIPMreqn          = 0xc
   259  	SizeofIPv6Mreq         = 0x14
   260  	SizeofMsghdr           = 0x1c
   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  uint32
   275  	Filter int16
   276  	Flags  uint16
   277  	Fflags uint32
   278  	Data   int32
   279  	Udata  *byte
   280  }
   281  
   282  type FdSet struct {
   283  	X__fds_bits [32]uint32
   284  }
   285  
   286  const (
   287  	sizeofIfMsghdr         = 0x64
   288  	SizeofIfMsghdr         = 0x60
   289  	sizeofIfData           = 0x54
   290  	SizeofIfData           = 0x50
   291  	SizeofIfaMsghdr        = 0x14
   292  	SizeofIfmaMsghdr       = 0x10
   293  	SizeofIfAnnounceMsghdr = 0x18
   294  	SizeofRtMsghdr         = 0x5c
   295  	SizeofRtMetrics        = 0x38
   296  )
   297  
   298  type ifMsghdr struct {
   299  	Msglen    uint16
   300  	Version   uint8
   301  	Type      uint8
   302  	Addrs     int32
   303  	Flags     int32
   304  	Index     uint16
   305  	Pad_cgo_0 [2]byte
   306  	Data      ifData
   307  }
   308  
   309  type IfMsghdr struct {
   310  	Msglen    uint16
   311  	Version   uint8
   312  	Type      uint8
   313  	Addrs     int32
   314  	Flags     int32
   315  	Index     uint16
   316  	Pad_cgo_0 [2]byte
   317  	Data      IfData
   318  }
   319  
   320  type ifData struct {
   321  	Type        uint8
   322  	Physical    uint8
   323  	Addrlen     uint8
   324  	Hdrlen      uint8
   325  	Link_state  uint8
   326  	Vhid        uint8
   327  	Baudrate_pf uint8
   328  	Datalen     uint8
   329  	Mtu         uint32
   330  	Metric      uint32
   331  	Baudrate    uint32
   332  	Ipackets    uint32
   333  	Ierrors     uint32
   334  	Opackets    uint32
   335  	Oerrors     uint32
   336  	Collisions  uint32
   337  	Ibytes      uint32
   338  	Obytes      uint32
   339  	Imcasts     uint32
   340  	Omcasts     uint32
   341  	Iqdrops     uint32
   342  	Noproto     uint32
   343  	Hwassist    uint64
   344  	Epoch       int32
   345  	Lastchange  Timeval
   346  }
   347  
   348  type IfData struct {
   349  	Type        uint8
   350  	Physical    uint8
   351  	Addrlen     uint8
   352  	Hdrlen      uint8
   353  	Link_state  uint8
   354  	Spare_char1 uint8
   355  	Spare_char2 uint8
   356  	Datalen     uint8
   357  	Mtu         uint32
   358  	Metric      uint32
   359  	Baudrate    uint32
   360  	Ipackets    uint32
   361  	Ierrors     uint32
   362  	Opackets    uint32
   363  	Oerrors     uint32
   364  	Collisions  uint32
   365  	Ibytes      uint32
   366  	Obytes      uint32
   367  	Imcasts     uint32
   368  	Omcasts     uint32
   369  	Iqdrops     uint32
   370  	Noproto     uint32
   371  	Hwassist    uint32
   372  	Epoch       int32
   373  	Lastchange  Timeval
   374  }
   375  
   376  type IfaMsghdr struct {
   377  	Msglen    uint16
   378  	Version   uint8
   379  	Type      uint8
   380  	Addrs     int32
   381  	Flags     int32
   382  	Index     uint16
   383  	Pad_cgo_0 [2]byte
   384  	Metric    int32
   385  }
   386  
   387  type IfmaMsghdr struct {
   388  	Msglen    uint16
   389  	Version   uint8
   390  	Type      uint8
   391  	Addrs     int32
   392  	Flags     int32
   393  	Index     uint16
   394  	Pad_cgo_0 [2]byte
   395  }
   396  
   397  type IfAnnounceMsghdr struct {
   398  	Msglen  uint16
   399  	Version uint8
   400  	Type    uint8
   401  	Index   uint16
   402  	Name    [16]int8
   403  	What    uint16
   404  }
   405  
   406  type RtMsghdr struct {
   407  	Msglen    uint16
   408  	Version   uint8
   409  	Type      uint8
   410  	Index     uint16
   411  	Pad_cgo_0 [2]byte
   412  	Flags     int32
   413  	Addrs     int32
   414  	Pid       int32
   415  	Seq       int32
   416  	Errno     int32
   417  	Fmask     int32
   418  	Inits     uint32
   419  	Rmx       RtMetrics
   420  }
   421  
   422  type RtMetrics struct {
   423  	Locks    uint32
   424  	Mtu      uint32
   425  	Hopcount uint32
   426  	Expire   uint32
   427  	Recvpipe uint32
   428  	Sendpipe uint32
   429  	Ssthresh uint32
   430  	Rtt      uint32
   431  	Rttvar   uint32
   432  	Pksent   uint32
   433  	Weight   uint32
   434  	Filler   [3]uint32
   435  }
   436  
   437  const (
   438  	SizeofBpfVersion    = 0x4
   439  	SizeofBpfStat       = 0x8
   440  	SizeofBpfZbuf       = 0xc
   441  	SizeofBpfProgram    = 0x8
   442  	SizeofBpfInsn       = 0x8
   443  	SizeofBpfHdr        = 0x14
   444  	SizeofBpfZbufHeader = 0x20
   445  )
   446  
   447  type BpfVersion struct {
   448  	Major uint16
   449  	Minor uint16
   450  }
   451  
   452  type BpfStat struct {
   453  	Recv uint32
   454  	Drop uint32
   455  }
   456  
   457  type BpfZbuf struct {
   458  	Bufa   *byte
   459  	Bufb   *byte
   460  	Buflen uint32
   461  }
   462  
   463  type BpfProgram struct {
   464  	Len   uint32
   465  	Insns *BpfInsn
   466  }
   467  
   468  type BpfInsn struct {
   469  	Code uint16
   470  	Jt   uint8
   471  	Jf   uint8
   472  	K    uint32
   473  }
   474  
   475  type BpfHdr struct {
   476  	Tstamp    Timeval
   477  	Caplen    uint32
   478  	Datalen   uint32
   479  	Hdrlen    uint16
   480  	Pad_cgo_0 [2]byte
   481  }
   482  
   483  type BpfZbufHeader struct {
   484  	Kernel_gen uint32
   485  	Kernel_len uint32
   486  	User_gen   uint32
   487  	X_bzh_pad  [5]uint32
   488  }
   489  
   490  const (
   491  	_AT_FDCWD = -0x64
   492  )
   493  
   494  type Termios struct {
   495  	Iflag  uint32
   496  	Oflag  uint32
   497  	Cflag  uint32
   498  	Lflag  uint32
   499  	Cc     [20]uint8
   500  	Ispeed uint32
   501  	Ospeed uint32
   502  }
   503  

View as plain text