github.com/m10x/go/src@v0.0.0-20220112094212-ba61592315da/syscall/ztypes_freebsd_arm64.go (about)

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