Source file src/syscall/ztypes_openbsd_riscv64.go

     1  // Code generated by cmd/cgo -godefs; DO NOT EDIT.
     2  // cgo -godefs -- -fsigned-char types_openbsd.go
     3  
     4  package syscall
     5  
     6  const (
     7  	sizeofPtr      = 0x8
     8  	sizeofShort    = 0x2
     9  	sizeofInt      = 0x4
    10  	sizeofLong     = 0x8
    11  	sizeofLongLong = 0x8
    12  )
    13  
    14  type (
    15  	_C_short     int16
    16  	_C_int       int32
    17  	_C_long      int64
    18  	_C_long_long int64
    19  )
    20  
    21  type Timespec struct {
    22  	Sec  int64
    23  	Nsec int64
    24  }
    25  
    26  type Timeval struct {
    27  	Sec  int64
    28  	Usec int64
    29  }
    30  
    31  type Rusage struct {
    32  	Utime    Timeval
    33  	Stime    Timeval
    34  	Maxrss   int64
    35  	Ixrss    int64
    36  	Idrss    int64
    37  	Isrss    int64
    38  	Minflt   int64
    39  	Majflt   int64
    40  	Nswap    int64
    41  	Inblock  int64
    42  	Oublock  int64
    43  	Msgsnd   int64
    44  	Msgrcv   int64
    45  	Nsignals int64
    46  	Nvcsw    int64
    47  	Nivcsw   int64
    48  }
    49  
    50  type Rlimit struct {
    51  	Cur uint64
    52  	Max uint64
    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  type Stat_t struct {
    77  	Mode           uint32
    78  	Dev            int32
    79  	Ino            uint64
    80  	Nlink          uint32
    81  	Uid            uint32
    82  	Gid            uint32
    83  	Rdev           int32
    84  	Atim           Timespec
    85  	Mtim           Timespec
    86  	Ctim           Timespec
    87  	Size           int64
    88  	Blocks         int64
    89  	Blksize        int32
    90  	Flags          uint32
    91  	Gen            uint32
    92  	X__st_birthtim Timespec
    93  }
    94  
    95  type Statfs_t struct {
    96  	F_flags       uint32
    97  	F_bsize       uint32
    98  	F_iosize      uint32
    99  	F_blocks      uint64
   100  	F_bfree       uint64
   101  	F_bavail      int64
   102  	F_files       uint64
   103  	F_ffree       uint64
   104  	F_favail      int64
   105  	F_syncwrites  uint64
   106  	F_syncreads   uint64
   107  	F_asyncwrites uint64
   108  	F_asyncreads  uint64
   109  	F_fsid        Fsid
   110  	F_namemax     uint32
   111  	F_owner       uint32
   112  	F_ctime       uint64
   113  	F_fstypename  [16]int8
   114  	F_mntonname   [90]int8
   115  	F_mntfromname [90]int8
   116  	F_mntfromspec [90]int8
   117  	Pad_cgo_0     [2]byte
   118  	Mount_info    [160]byte
   119  }
   120  
   121  type Flock_t struct {
   122  	Start  int64
   123  	Len    int64
   124  	Pid    int32
   125  	Type   int16
   126  	Whence int16
   127  }
   128  
   129  type Dirent struct {
   130  	Fileno       uint64
   131  	Off          int64
   132  	Reclen       uint16
   133  	Type         uint8
   134  	Namlen       uint8
   135  	X__d_padding [4]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   [24]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  uint64
   202  }
   203  
   204  type IPMreq struct {
   205  	Multiaddr [4]byte /* in_addr */
   206  	Interface [4]byte /* in_addr */
   207  }
   208  
   209  type IPv6Mreq struct {
   210  	Multiaddr [16]byte /* in6_addr */
   211  	Interface uint32
   212  }
   213  
   214  type Msghdr struct {
   215  	Name       *byte
   216  	Namelen    uint32
   217  	Iov        *Iovec
   218  	Iovlen     uint32
   219  	Control    *byte
   220  	Controllen uint32
   221  	Flags      int32
   222  }
   223  
   224  type Cmsghdr struct {
   225  	Len   uint32
   226  	Level int32
   227  	Type  int32
   228  }
   229  
   230  type Inet6Pktinfo struct {
   231  	Addr    [16]byte /* in6_addr */
   232  	Ifindex uint32
   233  }
   234  
   235  type IPv6MTUInfo struct {
   236  	Addr RawSockaddrInet6
   237  	Mtu  uint32
   238  }
   239  
   240  type ICMPv6Filter struct {
   241  	Filt [8]uint32
   242  }
   243  
   244  const (
   245  	SizeofSockaddrInet4    = 0x10
   246  	SizeofSockaddrInet6    = 0x1c
   247  	SizeofSockaddrAny      = 0x6c
   248  	SizeofSockaddrUnix     = 0x6a
   249  	SizeofSockaddrDatalink = 0x20
   250  	SizeofLinger           = 0x8
   251  	SizeofIPMreq           = 0x8
   252  	SizeofIPv6Mreq         = 0x14
   253  	SizeofMsghdr           = 0x30
   254  	SizeofCmsghdr          = 0xc
   255  	SizeofInet6Pktinfo     = 0x14
   256  	SizeofIPv6MTUInfo      = 0x20
   257  	SizeofICMPv6Filter     = 0x20
   258  )
   259  
   260  const (
   261  	PTRACE_TRACEME = 0x0
   262  	PTRACE_CONT    = 0x7
   263  	PTRACE_KILL    = 0x8
   264  )
   265  
   266  type Kevent_t struct {
   267  	Ident  uint64
   268  	Filter int16
   269  	Flags  uint16
   270  	Fflags uint32
   271  	Data   int64
   272  	Udata  *byte
   273  }
   274  
   275  type FdSet struct {
   276  	Bits [32]uint32
   277  }
   278  
   279  const (
   280  	SizeofIfMsghdr         = 0xa8
   281  	SizeofIfData           = 0x90
   282  	SizeofIfaMsghdr        = 0x18
   283  	SizeofIfAnnounceMsghdr = 0x1a
   284  	SizeofRtMsghdr         = 0x60
   285  	SizeofRtMetrics        = 0x38
   286  )
   287  
   288  type IfMsghdr struct {
   289  	Msglen  uint16
   290  	Version uint8
   291  	Type    uint8
   292  	Hdrlen  uint16
   293  	Index   uint16
   294  	Tableid uint16
   295  	Pad1    uint8
   296  	Pad2    uint8
   297  	Addrs   int32
   298  	Flags   int32
   299  	Xflags  int32
   300  	Data    IfData
   301  }
   302  
   303  type IfData struct {
   304  	Type         uint8
   305  	Addrlen      uint8
   306  	Hdrlen       uint8
   307  	Link_state   uint8
   308  	Mtu          uint32
   309  	Metric       uint32
   310  	Rdomain      uint32
   311  	Baudrate     uint64
   312  	Ipackets     uint64
   313  	Ierrors      uint64
   314  	Opackets     uint64
   315  	Oerrors      uint64
   316  	Collisions   uint64
   317  	Ibytes       uint64
   318  	Obytes       uint64
   319  	Imcasts      uint64
   320  	Omcasts      uint64
   321  	Iqdrops      uint64
   322  	Oqdrops      uint64
   323  	Noproto      uint64
   324  	Capabilities uint32
   325  	Lastchange   Timeval
   326  }
   327  
   328  type IfaMsghdr struct {
   329  	Msglen  uint16
   330  	Version uint8
   331  	Type    uint8
   332  	Hdrlen  uint16
   333  	Index   uint16
   334  	Tableid uint16
   335  	Pad1    uint8
   336  	Pad2    uint8
   337  	Addrs   int32
   338  	Flags   int32
   339  	Metric  int32
   340  }
   341  
   342  type IfAnnounceMsghdr struct {
   343  	Msglen  uint16
   344  	Version uint8
   345  	Type    uint8
   346  	Hdrlen  uint16
   347  	Index   uint16
   348  	What    uint16
   349  	Name    [16]int8
   350  }
   351  
   352  type RtMsghdr struct {
   353  	Msglen   uint16
   354  	Version  uint8
   355  	Type     uint8
   356  	Hdrlen   uint16
   357  	Index    uint16
   358  	Tableid  uint16
   359  	Priority uint8
   360  	Mpls     uint8
   361  	Addrs    int32
   362  	Flags    int32
   363  	Fmask    int32
   364  	Pid      int32
   365  	Seq      int32
   366  	Errno    int32
   367  	Inits    uint32
   368  	Rmx      RtMetrics
   369  }
   370  
   371  type RtMetrics struct {
   372  	Pksent   uint64
   373  	Expire   int64
   374  	Locks    uint32
   375  	Mtu      uint32
   376  	Refcnt   uint32
   377  	Hopcount uint32
   378  	Recvpipe uint32
   379  	Sendpipe uint32
   380  	Ssthresh uint32
   381  	Rtt      uint32
   382  	Rttvar   uint32
   383  	Pad      uint32
   384  }
   385  
   386  type Mclpool struct{}
   387  
   388  const (
   389  	SizeofBpfVersion = 0x4
   390  	SizeofBpfStat    = 0x8
   391  	SizeofBpfProgram = 0x10
   392  	SizeofBpfInsn    = 0x8
   393  	SizeofBpfHdr     = 0x18
   394  )
   395  
   396  type BpfVersion struct {
   397  	Major uint16
   398  	Minor uint16
   399  }
   400  
   401  type BpfStat struct {
   402  	Recv uint32
   403  	Drop uint32
   404  }
   405  
   406  type BpfProgram struct {
   407  	Len   uint32
   408  	Insns *BpfInsn
   409  }
   410  
   411  type BpfInsn struct {
   412  	Code uint16
   413  	Jt   uint8
   414  	Jf   uint8
   415  	K    uint32
   416  }
   417  
   418  type BpfHdr struct {
   419  	Tstamp  BpfTimeval
   420  	Caplen  uint32
   421  	Datalen uint32
   422  	Hdrlen  uint16
   423  	Ifidx   uint16
   424  	Flowid  uint16
   425  	Flags   uint8
   426  	Drops   uint8
   427  }
   428  
   429  type BpfTimeval struct {
   430  	Sec  uint32
   431  	Usec uint32
   432  }
   433  
   434  const (
   435  	_AT_FDCWD = -0x64
   436  )
   437  
   438  type Termios struct {
   439  	Iflag  uint32
   440  	Oflag  uint32
   441  	Cflag  uint32
   442  	Lflag  uint32
   443  	Cc     [20]uint8
   444  	Ispeed int32
   445  	Ospeed int32
   446  }
   447  

View as plain text