...
Run Format

Source file src/syscall/zsyscall_linux_mips.go

Documentation: syscall

     1  // mksyscall.pl -b32 -arm -tags linux,mips syscall_linux.go syscall_linux_mipsx.go
     2  // Code generated by the command above; DO NOT EDIT.
     3  
     4  // +build linux,mips
     5  
     6  package syscall
     7  
     8  import "unsafe"
     9  
    10  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    11  
    12  func faccessat(dirfd int, path string, mode uint32) (err error) {
    13  	var _p0 *byte
    14  	_p0, err = BytePtrFromString(path)
    15  	if err != nil {
    16  		return
    17  	}
    18  	_, _, e1 := Syscall(SYS_FACCESSAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(mode))
    19  	if e1 != 0 {
    20  		err = errnoErr(e1)
    21  	}
    22  	return
    23  }
    24  
    25  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    26  
    27  func fchmodat(dirfd int, path string, mode uint32) (err error) {
    28  	var _p0 *byte
    29  	_p0, err = BytePtrFromString(path)
    30  	if err != nil {
    31  		return
    32  	}
    33  	_, _, e1 := Syscall(SYS_FCHMODAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(mode))
    34  	if e1 != 0 {
    35  		err = errnoErr(e1)
    36  	}
    37  	return
    38  }
    39  
    40  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    41  
    42  func linkat(olddirfd int, oldpath string, newdirfd int, newpath string, flags int) (err error) {
    43  	var _p0 *byte
    44  	_p0, err = BytePtrFromString(oldpath)
    45  	if err != nil {
    46  		return
    47  	}
    48  	var _p1 *byte
    49  	_p1, err = BytePtrFromString(newpath)
    50  	if err != nil {
    51  		return
    52  	}
    53  	_, _, e1 := Syscall6(SYS_LINKAT, uintptr(olddirfd), uintptr(unsafe.Pointer(_p0)), uintptr(newdirfd), uintptr(unsafe.Pointer(_p1)), uintptr(flags), 0)
    54  	if e1 != 0 {
    55  		err = errnoErr(e1)
    56  	}
    57  	return
    58  }
    59  
    60  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    61  
    62  func openat(dirfd int, path string, flags int, mode uint32) (fd int, err error) {
    63  	var _p0 *byte
    64  	_p0, err = BytePtrFromString(path)
    65  	if err != nil {
    66  		return
    67  	}
    68  	r0, _, e1 := Syscall6(SYS_OPENAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(flags), uintptr(mode), 0, 0)
    69  	fd = int(r0)
    70  	if e1 != 0 {
    71  		err = errnoErr(e1)
    72  	}
    73  	return
    74  }
    75  
    76  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    77  
    78  func readlinkat(dirfd int, path string, buf []byte) (n int, err error) {
    79  	var _p0 *byte
    80  	_p0, err = BytePtrFromString(path)
    81  	if err != nil {
    82  		return
    83  	}
    84  	var _p1 unsafe.Pointer
    85  	if len(buf) > 0 {
    86  		_p1 = unsafe.Pointer(&buf[0])
    87  	} else {
    88  		_p1 = unsafe.Pointer(&_zero)
    89  	}
    90  	r0, _, e1 := Syscall6(SYS_READLINKAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(_p1), uintptr(len(buf)), 0, 0)
    91  	n = int(r0)
    92  	if e1 != 0 {
    93  		err = errnoErr(e1)
    94  	}
    95  	return
    96  }
    97  
    98  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    99  
   100  func symlinkat(oldpath string, newdirfd int, newpath string) (err error) {
   101  	var _p0 *byte
   102  	_p0, err = BytePtrFromString(oldpath)
   103  	if err != nil {
   104  		return
   105  	}
   106  	var _p1 *byte
   107  	_p1, err = BytePtrFromString(newpath)
   108  	if err != nil {
   109  		return
   110  	}
   111  	_, _, e1 := Syscall(SYS_SYMLINKAT, uintptr(unsafe.Pointer(_p0)), uintptr(newdirfd), uintptr(unsafe.Pointer(_p1)))
   112  	if e1 != 0 {
   113  		err = errnoErr(e1)
   114  	}
   115  	return
   116  }
   117  
   118  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   119  
   120  func unlinkat(dirfd int, path string, flags int) (err error) {
   121  	var _p0 *byte
   122  	_p0, err = BytePtrFromString(path)
   123  	if err != nil {
   124  		return
   125  	}
   126  	_, _, e1 := Syscall(SYS_UNLINKAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(flags))
   127  	if e1 != 0 {
   128  		err = errnoErr(e1)
   129  	}
   130  	return
   131  }
   132  
   133  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   134  
   135  func utimes(path string, times *[2]Timeval) (err error) {
   136  	var _p0 *byte
   137  	_p0, err = BytePtrFromString(path)
   138  	if err != nil {
   139  		return
   140  	}
   141  	_, _, e1 := Syscall(SYS_UTIMES, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(times)), 0)
   142  	if e1 != 0 {
   143  		err = errnoErr(e1)
   144  	}
   145  	return
   146  }
   147  
   148  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   149  
   150  func utimensat(dirfd int, path string, times *[2]Timespec, flag int) (err error) {
   151  	var _p0 *byte
   152  	_p0, err = BytePtrFromString(path)
   153  	if err != nil {
   154  		return
   155  	}
   156  	_, _, e1 := Syscall6(SYS_UTIMENSAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(times)), uintptr(flag), 0, 0)
   157  	if e1 != 0 {
   158  		err = errnoErr(e1)
   159  	}
   160  	return
   161  }
   162  
   163  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   164  
   165  func futimesat(dirfd int, path *byte, times *[2]Timeval) (err error) {
   166  	_, _, e1 := Syscall(SYS_FUTIMESAT, uintptr(dirfd), uintptr(unsafe.Pointer(path)), uintptr(unsafe.Pointer(times)))
   167  	if e1 != 0 {
   168  		err = errnoErr(e1)
   169  	}
   170  	return
   171  }
   172  
   173  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   174  
   175  func Getcwd(buf []byte) (n int, err error) {
   176  	var _p0 unsafe.Pointer
   177  	if len(buf) > 0 {
   178  		_p0 = unsafe.Pointer(&buf[0])
   179  	} else {
   180  		_p0 = unsafe.Pointer(&_zero)
   181  	}
   182  	r0, _, e1 := Syscall(SYS_GETCWD, uintptr(_p0), uintptr(len(buf)), 0)
   183  	n = int(r0)
   184  	if e1 != 0 {
   185  		err = errnoErr(e1)
   186  	}
   187  	return
   188  }
   189  
   190  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   191  
   192  func wait4(pid int, wstatus *_C_int, options int, rusage *Rusage) (wpid int, err error) {
   193  	r0, _, e1 := Syscall6(SYS_WAIT4, uintptr(pid), uintptr(unsafe.Pointer(wstatus)), uintptr(options), uintptr(unsafe.Pointer(rusage)), 0, 0)
   194  	wpid = int(r0)
   195  	if e1 != 0 {
   196  		err = errnoErr(e1)
   197  	}
   198  	return
   199  }
   200  
   201  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   202  
   203  func ptrace(request int, pid int, addr uintptr, data uintptr) (err error) {
   204  	_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
   205  	if e1 != 0 {
   206  		err = errnoErr(e1)
   207  	}
   208  	return
   209  }
   210  
   211  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   212  
   213  func reboot(magic1 uint, magic2 uint, cmd int, arg string) (err error) {
   214  	var _p0 *byte
   215  	_p0, err = BytePtrFromString(arg)
   216  	if err != nil {
   217  		return
   218  	}
   219  	_, _, e1 := Syscall6(SYS_REBOOT, uintptr(magic1), uintptr(magic2), uintptr(cmd), uintptr(unsafe.Pointer(_p0)), 0, 0)
   220  	if e1 != 0 {
   221  		err = errnoErr(e1)
   222  	}
   223  	return
   224  }
   225  
   226  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   227  
   228  func mount(source string, target string, fstype string, flags uintptr, data *byte) (err error) {
   229  	var _p0 *byte
   230  	_p0, err = BytePtrFromString(source)
   231  	if err != nil {
   232  		return
   233  	}
   234  	var _p1 *byte
   235  	_p1, err = BytePtrFromString(target)
   236  	if err != nil {
   237  		return
   238  	}
   239  	var _p2 *byte
   240  	_p2, err = BytePtrFromString(fstype)
   241  	if err != nil {
   242  		return
   243  	}
   244  	_, _, e1 := Syscall6(SYS_MOUNT, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(unsafe.Pointer(_p2)), uintptr(flags), uintptr(unsafe.Pointer(data)), 0)
   245  	if e1 != 0 {
   246  		err = errnoErr(e1)
   247  	}
   248  	return
   249  }
   250  
   251  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   252  
   253  func Acct(path string) (err error) {
   254  	var _p0 *byte
   255  	_p0, err = BytePtrFromString(path)
   256  	if err != nil {
   257  		return
   258  	}
   259  	_, _, e1 := Syscall(SYS_ACCT, uintptr(unsafe.Pointer(_p0)), 0, 0)
   260  	if e1 != 0 {
   261  		err = errnoErr(e1)
   262  	}
   263  	return
   264  }
   265  
   266  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   267  
   268  func Adjtimex(buf *Timex) (state int, err error) {
   269  	r0, _, e1 := Syscall(SYS_ADJTIMEX, uintptr(unsafe.Pointer(buf)), 0, 0)
   270  	state = int(r0)
   271  	if e1 != 0 {
   272  		err = errnoErr(e1)
   273  	}
   274  	return
   275  }
   276  
   277  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   278  
   279  func Chdir(path string) (err error) {
   280  	var _p0 *byte
   281  	_p0, err = BytePtrFromString(path)
   282  	if err != nil {
   283  		return
   284  	}
   285  	_, _, e1 := Syscall(SYS_CHDIR, uintptr(unsafe.Pointer(_p0)), 0, 0)
   286  	if e1 != 0 {
   287  		err = errnoErr(e1)
   288  	}
   289  	return
   290  }
   291  
   292  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   293  
   294  func Chroot(path string) (err error) {
   295  	var _p0 *byte
   296  	_p0, err = BytePtrFromString(path)
   297  	if err != nil {
   298  		return
   299  	}
   300  	_, _, e1 := Syscall(SYS_CHROOT, uintptr(unsafe.Pointer(_p0)), 0, 0)
   301  	if e1 != 0 {
   302  		err = errnoErr(e1)
   303  	}
   304  	return
   305  }
   306  
   307  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   308  
   309  func Close(fd int) (err error) {
   310  	_, _, e1 := Syscall(SYS_CLOSE, uintptr(fd), 0, 0)
   311  	if e1 != 0 {
   312  		err = errnoErr(e1)
   313  	}
   314  	return
   315  }
   316  
   317  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   318  
   319  func Dup(oldfd int) (fd int, err error) {
   320  	r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
   321  	fd = int(r0)
   322  	if e1 != 0 {
   323  		err = errnoErr(e1)
   324  	}
   325  	return
   326  }
   327  
   328  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   329  
   330  func Dup3(oldfd int, newfd int, flags int) (err error) {
   331  	_, _, e1 := Syscall(SYS_DUP3, uintptr(oldfd), uintptr(newfd), uintptr(flags))
   332  	if e1 != 0 {
   333  		err = errnoErr(e1)
   334  	}
   335  	return
   336  }
   337  
   338  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   339  
   340  func EpollCreate(size int) (fd int, err error) {
   341  	r0, _, e1 := RawSyscall(SYS_EPOLL_CREATE, uintptr(size), 0, 0)
   342  	fd = int(r0)
   343  	if e1 != 0 {
   344  		err = errnoErr(e1)
   345  	}
   346  	return
   347  }
   348  
   349  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   350  
   351  func EpollCreate1(flag int) (fd int, err error) {
   352  	r0, _, e1 := RawSyscall(SYS_EPOLL_CREATE1, uintptr(flag), 0, 0)
   353  	fd = int(r0)
   354  	if e1 != 0 {
   355  		err = errnoErr(e1)
   356  	}
   357  	return
   358  }
   359  
   360  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   361  
   362  func EpollCtl(epfd int, op int, fd int, event *EpollEvent) (err error) {
   363  	_, _, e1 := RawSyscall6(SYS_EPOLL_CTL, uintptr(epfd), uintptr(op), uintptr(fd), uintptr(unsafe.Pointer(event)), 0, 0)
   364  	if e1 != 0 {
   365  		err = errnoErr(e1)
   366  	}
   367  	return
   368  }
   369  
   370  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   371  
   372  func Fallocate(fd int, mode uint32, off int64, len int64) (err error) {
   373  	_, _, e1 := Syscall6(SYS_FALLOCATE, uintptr(fd), uintptr(mode), uintptr(off>>32), uintptr(off), uintptr(len>>32), uintptr(len))
   374  	if e1 != 0 {
   375  		err = errnoErr(e1)
   376  	}
   377  	return
   378  }
   379  
   380  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   381  
   382  func Fchdir(fd int) (err error) {
   383  	_, _, e1 := Syscall(SYS_FCHDIR, uintptr(fd), 0, 0)
   384  	if e1 != 0 {
   385  		err = errnoErr(e1)
   386  	}
   387  	return
   388  }
   389  
   390  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   391  
   392  func Fchmod(fd int, mode uint32) (err error) {
   393  	_, _, e1 := Syscall(SYS_FCHMOD, uintptr(fd), uintptr(mode), 0)
   394  	if e1 != 0 {
   395  		err = errnoErr(e1)
   396  	}
   397  	return
   398  }
   399  
   400  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   401  
   402  func Fchownat(dirfd int, path string, uid int, gid int, flags int) (err error) {
   403  	var _p0 *byte
   404  	_p0, err = BytePtrFromString(path)
   405  	if err != nil {
   406  		return
   407  	}
   408  	_, _, e1 := Syscall6(SYS_FCHOWNAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid), uintptr(flags), 0)
   409  	if e1 != 0 {
   410  		err = errnoErr(e1)
   411  	}
   412  	return
   413  }
   414  
   415  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   416  
   417  func fcntl(fd int, cmd int, arg int) (val int, err error) {
   418  	r0, _, e1 := Syscall(SYS_FCNTL, uintptr(fd), uintptr(cmd), uintptr(arg))
   419  	val = int(r0)
   420  	if e1 != 0 {
   421  		err = errnoErr(e1)
   422  	}
   423  	return
   424  }
   425  
   426  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   427  
   428  func Fdatasync(fd int) (err error) {
   429  	_, _, e1 := Syscall(SYS_FDATASYNC, uintptr(fd), 0, 0)
   430  	if e1 != 0 {
   431  		err = errnoErr(e1)
   432  	}
   433  	return
   434  }
   435  
   436  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   437  
   438  func Flock(fd int, how int) (err error) {
   439  	_, _, e1 := Syscall(SYS_FLOCK, uintptr(fd), uintptr(how), 0)
   440  	if e1 != 0 {
   441  		err = errnoErr(e1)
   442  	}
   443  	return
   444  }
   445  
   446  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   447  
   448  func Fsync(fd int) (err error) {
   449  	_, _, e1 := Syscall(SYS_FSYNC, uintptr(fd), 0, 0)
   450  	if e1 != 0 {
   451  		err = errnoErr(e1)
   452  	}
   453  	return
   454  }
   455  
   456  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   457  
   458  func Getdents(fd int, buf []byte) (n int, err error) {
   459  	var _p0 unsafe.Pointer
   460  	if len(buf) > 0 {
   461  		_p0 = unsafe.Pointer(&buf[0])
   462  	} else {
   463  		_p0 = unsafe.Pointer(&_zero)
   464  	}
   465  	r0, _, e1 := Syscall(SYS_GETDENTS64, uintptr(fd), uintptr(_p0), uintptr(len(buf)))
   466  	n = int(r0)
   467  	if e1 != 0 {
   468  		err = errnoErr(e1)
   469  	}
   470  	return
   471  }
   472  
   473  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   474  
   475  func Getpgid(pid int) (pgid int, err error) {
   476  	r0, _, e1 := RawSyscall(SYS_GETPGID, uintptr(pid), 0, 0)
   477  	pgid = int(r0)
   478  	if e1 != 0 {
   479  		err = errnoErr(e1)
   480  	}
   481  	return
   482  }
   483  
   484  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   485  
   486  func Getpid() (pid int) {
   487  	r0, _ := rawSyscallNoError(SYS_GETPID, 0, 0, 0)
   488  	pid = int(r0)
   489  	return
   490  }
   491  
   492  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   493  
   494  func Getppid() (ppid int) {
   495  	r0, _ := rawSyscallNoError(SYS_GETPPID, 0, 0, 0)
   496  	ppid = int(r0)
   497  	return
   498  }
   499  
   500  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   501  
   502  func Getpriority(which int, who int) (prio int, err error) {
   503  	r0, _, e1 := Syscall(SYS_GETPRIORITY, uintptr(which), uintptr(who), 0)
   504  	prio = int(r0)
   505  	if e1 != 0 {
   506  		err = errnoErr(e1)
   507  	}
   508  	return
   509  }
   510  
   511  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   512  
   513  func Getrusage(who int, rusage *Rusage) (err error) {
   514  	_, _, e1 := RawSyscall(SYS_GETRUSAGE, uintptr(who), uintptr(unsafe.Pointer(rusage)), 0)
   515  	if e1 != 0 {
   516  		err = errnoErr(e1)
   517  	}
   518  	return
   519  }
   520  
   521  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   522  
   523  func Gettid() (tid int) {
   524  	r0, _ := rawSyscallNoError(SYS_GETTID, 0, 0, 0)
   525  	tid = int(r0)
   526  	return
   527  }
   528  
   529  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   530  
   531  func Getxattr(path string, attr string, dest []byte) (sz int, err error) {
   532  	var _p0 *byte
   533  	_p0, err = BytePtrFromString(path)
   534  	if err != nil {
   535  		return
   536  	}
   537  	var _p1 *byte
   538  	_p1, err = BytePtrFromString(attr)
   539  	if err != nil {
   540  		return
   541  	}
   542  	var _p2 unsafe.Pointer
   543  	if len(dest) > 0 {
   544  		_p2 = unsafe.Pointer(&dest[0])
   545  	} else {
   546  		_p2 = unsafe.Pointer(&_zero)
   547  	}
   548  	r0, _, e1 := Syscall6(SYS_GETXATTR, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(_p2), uintptr(len(dest)), 0, 0)
   549  	sz = int(r0)
   550  	if e1 != 0 {
   551  		err = errnoErr(e1)
   552  	}
   553  	return
   554  }
   555  
   556  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   557  
   558  func InotifyAddWatch(fd int, pathname string, mask uint32) (watchdesc int, err error) {
   559  	var _p0 *byte
   560  	_p0, err = BytePtrFromString(pathname)
   561  	if err != nil {
   562  		return
   563  	}
   564  	r0, _, e1 := Syscall(SYS_INOTIFY_ADD_WATCH, uintptr(fd), uintptr(unsafe.Pointer(_p0)), uintptr(mask))
   565  	watchdesc = int(r0)
   566  	if e1 != 0 {
   567  		err = errnoErr(e1)
   568  	}
   569  	return
   570  }
   571  
   572  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   573  
   574  func InotifyInit1(flags int) (fd int, err error) {
   575  	r0, _, e1 := RawSyscall(SYS_INOTIFY_INIT1, uintptr(flags), 0, 0)
   576  	fd = int(r0)
   577  	if e1 != 0 {
   578  		err = errnoErr(e1)
   579  	}
   580  	return
   581  }
   582  
   583  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   584  
   585  func InotifyRmWatch(fd int, watchdesc uint32) (success int, err error) {
   586  	r0, _, e1 := RawSyscall(SYS_INOTIFY_RM_WATCH, uintptr(fd), uintptr(watchdesc), 0)
   587  	success = int(r0)
   588  	if e1 != 0 {
   589  		err = errnoErr(e1)
   590  	}
   591  	return
   592  }
   593  
   594  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   595  
   596  func Kill(pid int, sig Signal) (err error) {
   597  	_, _, e1 := RawSyscall(SYS_KILL, uintptr(pid), uintptr(sig), 0)
   598  	if e1 != 0 {
   599  		err = errnoErr(e1)
   600  	}
   601  	return
   602  }
   603  
   604  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   605  
   606  func Klogctl(typ int, buf []byte) (n int, err error) {
   607  	var _p0 unsafe.Pointer
   608  	if len(buf) > 0 {
   609  		_p0 = unsafe.Pointer(&buf[0])
   610  	} else {
   611  		_p0 = unsafe.Pointer(&_zero)
   612  	}
   613  	r0, _, e1 := Syscall(SYS_SYSLOG, uintptr(typ), uintptr(_p0), uintptr(len(buf)))
   614  	n = int(r0)
   615  	if e1 != 0 {
   616  		err = errnoErr(e1)
   617  	}
   618  	return
   619  }
   620  
   621  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   622  
   623  func Listxattr(path string, dest []byte) (sz int, err error) {
   624  	var _p0 *byte
   625  	_p0, err = BytePtrFromString(path)
   626  	if err != nil {
   627  		return
   628  	}
   629  	var _p1 unsafe.Pointer
   630  	if len(dest) > 0 {
   631  		_p1 = unsafe.Pointer(&dest[0])
   632  	} else {
   633  		_p1 = unsafe.Pointer(&_zero)
   634  	}
   635  	r0, _, e1 := Syscall(SYS_LISTXATTR, uintptr(unsafe.Pointer(_p0)), uintptr(_p1), uintptr(len(dest)))
   636  	sz = int(r0)
   637  	if e1 != 0 {
   638  		err = errnoErr(e1)
   639  	}
   640  	return
   641  }
   642  
   643  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   644  
   645  func Mkdirat(dirfd int, path string, mode uint32) (err error) {
   646  	var _p0 *byte
   647  	_p0, err = BytePtrFromString(path)
   648  	if err != nil {
   649  		return
   650  	}
   651  	_, _, e1 := Syscall(SYS_MKDIRAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(mode))
   652  	if e1 != 0 {
   653  		err = errnoErr(e1)
   654  	}
   655  	return
   656  }
   657  
   658  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   659  
   660  func Mknodat(dirfd int, path string, mode uint32, dev int) (err error) {
   661  	var _p0 *byte
   662  	_p0, err = BytePtrFromString(path)
   663  	if err != nil {
   664  		return
   665  	}
   666  	_, _, e1 := Syscall6(SYS_MKNODAT, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(mode), uintptr(dev), 0, 0)
   667  	if e1 != 0 {
   668  		err = errnoErr(e1)
   669  	}
   670  	return
   671  }
   672  
   673  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   674  
   675  func Nanosleep(time *Timespec, leftover *Timespec) (err error) {
   676  	_, _, e1 := Syscall(SYS_NANOSLEEP, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0)
   677  	if e1 != 0 {
   678  		err = errnoErr(e1)
   679  	}
   680  	return
   681  }
   682  
   683  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   684  
   685  func Pause() (err error) {
   686  	_, _, e1 := Syscall(SYS_PAUSE, 0, 0, 0)
   687  	if e1 != 0 {
   688  		err = errnoErr(e1)
   689  	}
   690  	return
   691  }
   692  
   693  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   694  
   695  func PivotRoot(newroot string, putold string) (err error) {
   696  	var _p0 *byte
   697  	_p0, err = BytePtrFromString(newroot)
   698  	if err != nil {
   699  		return
   700  	}
   701  	var _p1 *byte
   702  	_p1, err = BytePtrFromString(putold)
   703  	if err != nil {
   704  		return
   705  	}
   706  	_, _, e1 := Syscall(SYS_PIVOT_ROOT, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
   707  	if e1 != 0 {
   708  		err = errnoErr(e1)
   709  	}
   710  	return
   711  }
   712  
   713  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   714  
   715  func prlimit(pid int, resource int, newlimit *Rlimit, old *Rlimit) (err error) {
   716  	_, _, e1 := RawSyscall6(SYS_PRLIMIT64, uintptr(pid), uintptr(resource), uintptr(unsafe.Pointer(newlimit)), uintptr(unsafe.Pointer(old)), 0, 0)
   717  	if e1 != 0 {
   718  		err = errnoErr(e1)
   719  	}
   720  	return
   721  }
   722  
   723  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   724  
   725  func read(fd int, p []byte) (n int, err error) {
   726  	var _p0 unsafe.Pointer
   727  	if len(p) > 0 {
   728  		_p0 = unsafe.Pointer(&p[0])
   729  	} else {
   730  		_p0 = unsafe.Pointer(&_zero)
   731  	}
   732  	r0, _, e1 := Syscall(SYS_READ, uintptr(fd), uintptr(_p0), uintptr(len(p)))
   733  	n = int(r0)
   734  	if e1 != 0 {
   735  		err = errnoErr(e1)
   736  	}
   737  	return
   738  }
   739  
   740  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   741  
   742  func Removexattr(path string, attr string) (err error) {
   743  	var _p0 *byte
   744  	_p0, err = BytePtrFromString(path)
   745  	if err != nil {
   746  		return
   747  	}
   748  	var _p1 *byte
   749  	_p1, err = BytePtrFromString(attr)
   750  	if err != nil {
   751  		return
   752  	}
   753  	_, _, e1 := Syscall(SYS_REMOVEXATTR, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
   754  	if e1 != 0 {
   755  		err = errnoErr(e1)
   756  	}
   757  	return
   758  }
   759  
   760  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   761  
   762  func Renameat(olddirfd int, oldpath string, newdirfd int, newpath string) (err error) {
   763  	var _p0 *byte
   764  	_p0, err = BytePtrFromString(oldpath)
   765  	if err != nil {
   766  		return
   767  	}
   768  	var _p1 *byte
   769  	_p1, err = BytePtrFromString(newpath)
   770  	if err != nil {
   771  		return
   772  	}
   773  	_, _, e1 := Syscall6(SYS_RENAMEAT, uintptr(olddirfd), uintptr(unsafe.Pointer(_p0)), uintptr(newdirfd), uintptr(unsafe.Pointer(_p1)), 0, 0)
   774  	if e1 != 0 {
   775  		err = errnoErr(e1)
   776  	}
   777  	return
   778  }
   779  
   780  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   781  
   782  func Setdomainname(p []byte) (err error) {
   783  	var _p0 unsafe.Pointer
   784  	if len(p) > 0 {
   785  		_p0 = unsafe.Pointer(&p[0])
   786  	} else {
   787  		_p0 = unsafe.Pointer(&_zero)
   788  	}
   789  	_, _, e1 := Syscall(SYS_SETDOMAINNAME, uintptr(_p0), uintptr(len(p)), 0)
   790  	if e1 != 0 {
   791  		err = errnoErr(e1)
   792  	}
   793  	return
   794  }
   795  
   796  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   797  
   798  func Sethostname(p []byte) (err error) {
   799  	var _p0 unsafe.Pointer
   800  	if len(p) > 0 {
   801  		_p0 = unsafe.Pointer(&p[0])
   802  	} else {
   803  		_p0 = unsafe.Pointer(&_zero)
   804  	}
   805  	_, _, e1 := Syscall(SYS_SETHOSTNAME, uintptr(_p0), uintptr(len(p)), 0)
   806  	if e1 != 0 {
   807  		err = errnoErr(e1)
   808  	}
   809  	return
   810  }
   811  
   812  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   813  
   814  func Setpgid(pid int, pgid int) (err error) {
   815  	_, _, e1 := RawSyscall(SYS_SETPGID, uintptr(pid), uintptr(pgid), 0)
   816  	if e1 != 0 {
   817  		err = errnoErr(e1)
   818  	}
   819  	return
   820  }
   821  
   822  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   823  
   824  func Setsid() (pid int, err error) {
   825  	r0, _, e1 := RawSyscall(SYS_SETSID, 0, 0, 0)
   826  	pid = int(r0)
   827  	if e1 != 0 {
   828  		err = errnoErr(e1)
   829  	}
   830  	return
   831  }
   832  
   833  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   834  
   835  func Settimeofday(tv *Timeval) (err error) {
   836  	_, _, e1 := RawSyscall(SYS_SETTIMEOFDAY, uintptr(unsafe.Pointer(tv)), 0, 0)
   837  	if e1 != 0 {
   838  		err = errnoErr(e1)
   839  	}
   840  	return
   841  }
   842  
   843  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   844  
   845  func Setpriority(which int, who int, prio int) (err error) {
   846  	_, _, e1 := Syscall(SYS_SETPRIORITY, uintptr(which), uintptr(who), uintptr(prio))
   847  	if e1 != 0 {
   848  		err = errnoErr(e1)
   849  	}
   850  	return
   851  }
   852  
   853  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   854  
   855  func Setxattr(path string, attr string, data []byte, flags int) (err error) {
   856  	var _p0 *byte
   857  	_p0, err = BytePtrFromString(path)
   858  	if err != nil {
   859  		return
   860  	}
   861  	var _p1 *byte
   862  	_p1, err = BytePtrFromString(attr)
   863  	if err != nil {
   864  		return
   865  	}
   866  	var _p2 unsafe.Pointer
   867  	if len(data) > 0 {
   868  		_p2 = unsafe.Pointer(&data[0])
   869  	} else {
   870  		_p2 = unsafe.Pointer(&_zero)
   871  	}
   872  	_, _, e1 := Syscall6(SYS_SETXATTR, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(_p2), uintptr(len(data)), uintptr(flags), 0)
   873  	if e1 != 0 {
   874  		err = errnoErr(e1)
   875  	}
   876  	return
   877  }
   878  
   879  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   880  
   881  func Sync() {
   882  	Syscall(SYS_SYNC, 0, 0, 0)
   883  	return
   884  }
   885  
   886  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   887  
   888  func Sysinfo(info *Sysinfo_t) (err error) {
   889  	_, _, e1 := RawSyscall(SYS_SYSINFO, uintptr(unsafe.Pointer(info)), 0, 0)
   890  	if e1 != 0 {
   891  		err = errnoErr(e1)
   892  	}
   893  	return
   894  }
   895  
   896  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   897  
   898  func Tee(rfd int, wfd int, len int, flags int) (n int64, err error) {
   899  	r0, r1, e1 := Syscall6(SYS_TEE, uintptr(rfd), uintptr(wfd), uintptr(len), uintptr(flags), 0, 0)
   900  	n = int64(int64(r0)<<32 | int64(r1))
   901  	if e1 != 0 {
   902  		err = errnoErr(e1)
   903  	}
   904  	return
   905  }
   906  
   907  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   908  
   909  func Tgkill(tgid int, tid int, sig Signal) (err error) {
   910  	_, _, e1 := RawSyscall(SYS_TGKILL, uintptr(tgid), uintptr(tid), uintptr(sig))
   911  	if e1 != 0 {
   912  		err = errnoErr(e1)
   913  	}
   914  	return
   915  }
   916  
   917  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   918  
   919  func Times(tms *Tms) (ticks uintptr, err error) {
   920  	r0, _, e1 := RawSyscall(SYS_TIMES, uintptr(unsafe.Pointer(tms)), 0, 0)
   921  	ticks = uintptr(r0)
   922  	if e1 != 0 {
   923  		err = errnoErr(e1)
   924  	}
   925  	return
   926  }
   927  
   928  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   929  
   930  func Umask(mask int) (oldmask int) {
   931  	r0, _ := rawSyscallNoError(SYS_UMASK, uintptr(mask), 0, 0)
   932  	oldmask = int(r0)
   933  	return
   934  }
   935  
   936  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   937  
   938  func Uname(buf *Utsname) (err error) {
   939  	_, _, e1 := RawSyscall(SYS_UNAME, uintptr(unsafe.Pointer(buf)), 0, 0)
   940  	if e1 != 0 {
   941  		err = errnoErr(e1)
   942  	}
   943  	return
   944  }
   945  
   946  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   947  
   948  func Unmount(target string, flags int) (err error) {
   949  	var _p0 *byte
   950  	_p0, err = BytePtrFromString(target)
   951  	if err != nil {
   952  		return
   953  	}
   954  	_, _, e1 := Syscall(SYS_UMOUNT2, uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
   955  	if e1 != 0 {
   956  		err = errnoErr(e1)
   957  	}
   958  	return
   959  }
   960  
   961  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   962  
   963  func Unshare(flags int) (err error) {
   964  	_, _, e1 := Syscall(SYS_UNSHARE, uintptr(flags), 0, 0)
   965  	if e1 != 0 {
   966  		err = errnoErr(e1)
   967  	}
   968  	return
   969  }
   970  
   971  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   972  
   973  func Ustat(dev int, ubuf *Ustat_t) (err error) {
   974  	_, _, e1 := Syscall(SYS_USTAT, uintptr(dev), uintptr(unsafe.Pointer(ubuf)), 0)
   975  	if e1 != 0 {
   976  		err = errnoErr(e1)
   977  	}
   978  	return
   979  }
   980  
   981  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   982  
   983  func Utime(path string, buf *Utimbuf) (err error) {
   984  	var _p0 *byte
   985  	_p0, err = BytePtrFromString(path)
   986  	if err != nil {
   987  		return
   988  	}
   989  	_, _, e1 := Syscall(SYS_UTIME, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(buf)), 0)
   990  	if e1 != 0 {
   991  		err = errnoErr(e1)
   992  	}
   993  	return
   994  }
   995  
   996  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   997  
   998  func write(fd int, p []byte) (n int, err error) {
   999  	var _p0 unsafe.Pointer
  1000  	if len(p) > 0 {
  1001  		_p0 = unsafe.Pointer(&p[0])
  1002  	} else {
  1003  		_p0 = unsafe.Pointer(&_zero)
  1004  	}
  1005  	r0, _, e1 := Syscall(SYS_WRITE, uintptr(fd), uintptr(_p0), uintptr(len(p)))
  1006  	n = int(r0)
  1007  	if e1 != 0 {
  1008  		err = errnoErr(e1)
  1009  	}
  1010  	return
  1011  }
  1012  
  1013  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1014  
  1015  func exitThread(code int) (err error) {
  1016  	_, _, e1 := Syscall(SYS_EXIT, uintptr(code), 0, 0)
  1017  	if e1 != 0 {
  1018  		err = errnoErr(e1)
  1019  	}
  1020  	return
  1021  }
  1022  
  1023  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1024  
  1025  func readlen(fd int, p *byte, np int) (n int, err error) {
  1026  	r0, _, e1 := Syscall(SYS_READ, uintptr(fd), uintptr(unsafe.Pointer(p)), uintptr(np))
  1027  	n = int(r0)
  1028  	if e1 != 0 {
  1029  		err = errnoErr(e1)
  1030  	}
  1031  	return
  1032  }
  1033  
  1034  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1035  
  1036  func writelen(fd int, p *byte, np int) (n int, err error) {
  1037  	r0, _, e1 := Syscall(SYS_WRITE, uintptr(fd), uintptr(unsafe.Pointer(p)), uintptr(np))
  1038  	n = int(r0)
  1039  	if e1 != 0 {
  1040  		err = errnoErr(e1)
  1041  	}
  1042  	return
  1043  }
  1044  
  1045  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1046  
  1047  func munmap(addr uintptr, length uintptr) (err error) {
  1048  	_, _, e1 := Syscall(SYS_MUNMAP, uintptr(addr), uintptr(length), 0)
  1049  	if e1 != 0 {
  1050  		err = errnoErr(e1)
  1051  	}
  1052  	return
  1053  }
  1054  
  1055  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1056  
  1057  func Madvise(b []byte, advice int) (err error) {
  1058  	var _p0 unsafe.Pointer
  1059  	if len(b) > 0 {
  1060  		_p0 = unsafe.Pointer(&b[0])
  1061  	} else {
  1062  		_p0 = unsafe.Pointer(&_zero)
  1063  	}
  1064  	_, _, e1 := Syscall(SYS_MADVISE, uintptr(_p0), uintptr(len(b)), uintptr(advice))
  1065  	if e1 != 0 {
  1066  		err = errnoErr(e1)
  1067  	}
  1068  	return
  1069  }
  1070  
  1071  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1072  
  1073  func Mprotect(b []byte, prot int) (err error) {
  1074  	var _p0 unsafe.Pointer
  1075  	if len(b) > 0 {
  1076  		_p0 = unsafe.Pointer(&b[0])
  1077  	} else {
  1078  		_p0 = unsafe.Pointer(&_zero)
  1079  	}
  1080  	_, _, e1 := Syscall(SYS_MPROTECT, uintptr(_p0), uintptr(len(b)), uintptr(prot))
  1081  	if e1 != 0 {
  1082  		err = errnoErr(e1)
  1083  	}
  1084  	return
  1085  }
  1086  
  1087  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1088  
  1089  func Mlock(b []byte) (err error) {
  1090  	var _p0 unsafe.Pointer
  1091  	if len(b) > 0 {
  1092  		_p0 = unsafe.Pointer(&b[0])
  1093  	} else {
  1094  		_p0 = unsafe.Pointer(&_zero)
  1095  	}
  1096  	_, _, e1 := Syscall(SYS_MLOCK, uintptr(_p0), uintptr(len(b)), 0)
  1097  	if e1 != 0 {
  1098  		err = errnoErr(e1)
  1099  	}
  1100  	return
  1101  }
  1102  
  1103  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1104  
  1105  func Munlock(b []byte) (err error) {
  1106  	var _p0 unsafe.Pointer
  1107  	if len(b) > 0 {
  1108  		_p0 = unsafe.Pointer(&b[0])
  1109  	} else {
  1110  		_p0 = unsafe.Pointer(&_zero)
  1111  	}
  1112  	_, _, e1 := Syscall(SYS_MUNLOCK, uintptr(_p0), uintptr(len(b)), 0)
  1113  	if e1 != 0 {
  1114  		err = errnoErr(e1)
  1115  	}
  1116  	return
  1117  }
  1118  
  1119  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1120  
  1121  func Mlockall(flags int) (err error) {
  1122  	_, _, e1 := Syscall(SYS_MLOCKALL, uintptr(flags), 0, 0)
  1123  	if e1 != 0 {
  1124  		err = errnoErr(e1)
  1125  	}
  1126  	return
  1127  }
  1128  
  1129  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1130  
  1131  func Munlockall() (err error) {
  1132  	_, _, e1 := Syscall(SYS_MUNLOCKALL, 0, 0, 0)
  1133  	if e1 != 0 {
  1134  		err = errnoErr(e1)
  1135  	}
  1136  	return
  1137  }
  1138  
  1139  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1140  
  1141  func Dup2(oldfd int, newfd int) (err error) {
  1142  	_, _, e1 := Syscall(SYS_DUP2, uintptr(oldfd), uintptr(newfd), 0)
  1143  	if e1 != 0 {
  1144  		err = errnoErr(e1)
  1145  	}
  1146  	return
  1147  }
  1148  
  1149  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1150  
  1151  func Fchown(fd int, uid int, gid int) (err error) {
  1152  	_, _, e1 := Syscall(SYS_FCHOWN, uintptr(fd), uintptr(uid), uintptr(gid))
  1153  	if e1 != 0 {
  1154  		err = errnoErr(e1)
  1155  	}
  1156  	return
  1157  }
  1158  
  1159  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1160  
  1161  func fstatat(dirfd int, path string, stat *Stat_t, flags int) (err error) {
  1162  	var _p0 *byte
  1163  	_p0, err = BytePtrFromString(path)
  1164  	if err != nil {
  1165  		return
  1166  	}
  1167  	_, _, e1 := Syscall6(SYS_FSTATAT64, uintptr(dirfd), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), uintptr(flags), 0, 0)
  1168  	if e1 != 0 {
  1169  		err = errnoErr(e1)
  1170  	}
  1171  	return
  1172  }
  1173  
  1174  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1175  
  1176  func Ftruncate(fd int, length int64) (err error) {
  1177  	_, _, e1 := Syscall6(SYS_FTRUNCATE64, uintptr(fd), 0, uintptr(length>>32), uintptr(length), 0, 0)
  1178  	if e1 != 0 {
  1179  		err = errnoErr(e1)
  1180  	}
  1181  	return
  1182  }
  1183  
  1184  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1185  
  1186  func Getegid() (egid int) {
  1187  	r0, _ := rawSyscallNoError(SYS_GETEGID, 0, 0, 0)
  1188  	egid = int(r0)
  1189  	return
  1190  }
  1191  
  1192  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1193  
  1194  func Geteuid() (euid int) {
  1195  	r0, _ := rawSyscallNoError(SYS_GETEUID, 0, 0, 0)
  1196  	euid = int(r0)
  1197  	return
  1198  }
  1199  
  1200  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1201  
  1202  func Getgid() (gid int) {
  1203  	r0, _ := rawSyscallNoError(SYS_GETGID, 0, 0, 0)
  1204  	gid = int(r0)
  1205  	return
  1206  }
  1207  
  1208  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1209  
  1210  func Getuid() (uid int) {
  1211  	r0, _ := rawSyscallNoError(SYS_GETUID, 0, 0, 0)
  1212  	uid = int(r0)
  1213  	return
  1214  }
  1215  
  1216  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1217  
  1218  func Lchown(path string, uid int, gid int) (err error) {
  1219  	var _p0 *byte
  1220  	_p0, err = BytePtrFromString(path)
  1221  	if err != nil {
  1222  		return
  1223  	}
  1224  	_, _, e1 := Syscall(SYS_LCHOWN, uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid))
  1225  	if e1 != 0 {
  1226  		err = errnoErr(e1)
  1227  	}
  1228  	return
  1229  }
  1230  
  1231  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1232  
  1233  func Listen(s int, n int) (err error) {
  1234  	_, _, e1 := Syscall(SYS_LISTEN, uintptr(s), uintptr(n), 0)
  1235  	if e1 != 0 {
  1236  		err = errnoErr(e1)
  1237  	}
  1238  	return
  1239  }
  1240  
  1241  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1242  
  1243  func Pread(fd int, p []byte, offset int64) (n int, err error) {
  1244  	var _p0 unsafe.Pointer
  1245  	if len(p) > 0 {
  1246  		_p0 = unsafe.Pointer(&p[0])
  1247  	} else {
  1248  		_p0 = unsafe.Pointer(&_zero)
  1249  	}
  1250  	r0, _, e1 := Syscall6(SYS_PREAD64, uintptr(fd), uintptr(_p0), uintptr(len(p)), 0, uintptr(offset>>32), uintptr(offset))
  1251  	n = int(r0)
  1252  	if e1 != 0 {
  1253  		err = errnoErr(e1)
  1254  	}
  1255  	return
  1256  }
  1257  
  1258  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1259  
  1260  func Pwrite(fd int, p []byte, offset int64) (n int, err error) {
  1261  	var _p0 unsafe.Pointer
  1262  	if len(p) > 0 {
  1263  		_p0 = unsafe.Pointer(&p[0])
  1264  	} else {
  1265  		_p0 = unsafe.Pointer(&_zero)
  1266  	}
  1267  	r0, _, e1 := Syscall6(SYS_PWRITE64, uintptr(fd), uintptr(_p0), uintptr(len(p)), 0, uintptr(offset>>32), uintptr(offset))
  1268  	n = int(r0)
  1269  	if e1 != 0 {
  1270  		err = errnoErr(e1)
  1271  	}
  1272  	return
  1273  }
  1274  
  1275  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1276  
  1277  func Select(nfd int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) (n int, err error) {
  1278  	r0, _, e1 := Syscall6(SYS__NEWSELECT, uintptr(nfd), uintptr(unsafe.Pointer(r)), uintptr(unsafe.Pointer(w)), uintptr(unsafe.Pointer(e)), uintptr(unsafe.Pointer(timeout)), 0)
  1279  	n = int(r0)
  1280  	if e1 != 0 {
  1281  		err = errnoErr(e1)
  1282  	}
  1283  	return
  1284  }
  1285  
  1286  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1287  
  1288  func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
  1289  	r0, _, e1 := Syscall6(SYS_SENDFILE64, uintptr(outfd), uintptr(infd), uintptr(unsafe.Pointer(offset)), uintptr(count), 0, 0)
  1290  	written = int(r0)
  1291  	if e1 != 0 {
  1292  		err = errnoErr(e1)
  1293  	}
  1294  	return
  1295  }
  1296  
  1297  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1298  
  1299  func Setfsgid(gid int) (err error) {
  1300  	_, _, e1 := Syscall(SYS_SETFSGID, uintptr(gid), 0, 0)
  1301  	if e1 != 0 {
  1302  		err = errnoErr(e1)
  1303  	}
  1304  	return
  1305  }
  1306  
  1307  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1308  
  1309  func Setfsuid(uid int) (err error) {
  1310  	_, _, e1 := Syscall(SYS_SETFSUID, uintptr(uid), 0, 0)
  1311  	if e1 != 0 {
  1312  		err = errnoErr(e1)
  1313  	}
  1314  	return
  1315  }
  1316  
  1317  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1318  
  1319  func Setregid(rgid int, egid int) (err error) {
  1320  	_, _, e1 := RawSyscall(SYS_SETREGID, uintptr(rgid), uintptr(egid), 0)
  1321  	if e1 != 0 {
  1322  		err = errnoErr(e1)
  1323  	}
  1324  	return
  1325  }
  1326  
  1327  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1328  
  1329  func Setresgid(rgid int, egid int, sgid int) (err error) {
  1330  	_, _, e1 := RawSyscall(SYS_SETRESGID, uintptr(rgid), uintptr(egid), uintptr(sgid))
  1331  	if e1 != 0 {
  1332  		err = errnoErr(e1)
  1333  	}
  1334  	return
  1335  }
  1336  
  1337  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1338  
  1339  func Setresuid(ruid int, euid int, suid int) (err error) {
  1340  	_, _, e1 := RawSyscall(SYS_SETRESUID, uintptr(ruid), uintptr(euid), uintptr(suid))
  1341  	if e1 != 0 {
  1342  		err = errnoErr(e1)
  1343  	}
  1344  	return
  1345  }
  1346  
  1347  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1348  
  1349  func Setreuid(ruid int, euid int) (err error) {
  1350  	_, _, e1 := RawSyscall(SYS_SETREUID, uintptr(ruid), uintptr(euid), 0)
  1351  	if e1 != 0 {
  1352  		err = errnoErr(e1)
  1353  	}
  1354  	return
  1355  }
  1356  
  1357  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1358  
  1359  func Shutdown(fd int, how int) (err error) {
  1360  	_, _, e1 := Syscall(SYS_SHUTDOWN, uintptr(fd), uintptr(how), 0)
  1361  	if e1 != 0 {
  1362  		err = errnoErr(e1)
  1363  	}
  1364  	return
  1365  }
  1366  
  1367  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1368  
  1369  func Splice(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
  1370  	r0, _, e1 := Syscall6(SYS_SPLICE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
  1371  	n = int(r0)
  1372  	if e1 != 0 {
  1373  		err = errnoErr(e1)
  1374  	}
  1375  	return
  1376  }
  1377  
  1378  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1379  
  1380  func SyncFileRange(fd int, off int64, n int64, flags int) (err error) {
  1381  	_, _, e1 := Syscall9(SYS_SYNC_FILE_RANGE, uintptr(fd), 0, uintptr(off>>32), uintptr(off), uintptr(n>>32), uintptr(n), uintptr(flags), 0, 0)
  1382  	if e1 != 0 {
  1383  		err = errnoErr(e1)
  1384  	}
  1385  	return
  1386  }
  1387  
  1388  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1389  
  1390  func Truncate(path string, length int64) (err error) {
  1391  	var _p0 *byte
  1392  	_p0, err = BytePtrFromString(path)
  1393  	if err != nil {
  1394  		return
  1395  	}
  1396  	_, _, e1 := Syscall6(SYS_TRUNCATE64, uintptr(unsafe.Pointer(_p0)), 0, uintptr(length>>32), uintptr(length), 0, 0)
  1397  	if e1 != 0 {
  1398  		err = errnoErr(e1)
  1399  	}
  1400  	return
  1401  }
  1402  
  1403  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1404  
  1405  func accept(s int, rsa *RawSockaddrAny, addrlen *_Socklen) (fd int, err error) {
  1406  	r0, _, e1 := Syscall(SYS_ACCEPT, uintptr(s), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
  1407  	fd = int(r0)
  1408  	if e1 != 0 {
  1409  		err = errnoErr(e1)
  1410  	}
  1411  	return
  1412  }
  1413  
  1414  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1415  
  1416  func accept4(s int, rsa *RawSockaddrAny, addrlen *_Socklen, flags int) (fd int, err error) {
  1417  	r0, _, e1 := Syscall6(SYS_ACCEPT4, uintptr(s), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)), uintptr(flags), 0, 0)
  1418  	fd = int(r0)
  1419  	if e1 != 0 {
  1420  		err = errnoErr(e1)
  1421  	}
  1422  	return
  1423  }
  1424  
  1425  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1426  
  1427  func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
  1428  	_, _, e1 := Syscall(SYS_BIND, uintptr(s), uintptr(addr), uintptr(addrlen))
  1429  	if e1 != 0 {
  1430  		err = errnoErr(e1)
  1431  	}
  1432  	return
  1433  }
  1434  
  1435  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1436  
  1437  func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
  1438  	_, _, e1 := Syscall(SYS_CONNECT, uintptr(s), uintptr(addr), uintptr(addrlen))
  1439  	if e1 != 0 {
  1440  		err = errnoErr(e1)
  1441  	}
  1442  	return
  1443  }
  1444  
  1445  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1446  
  1447  func getgroups(n int, list *_Gid_t) (nn int, err error) {
  1448  	r0, _, e1 := RawSyscall(SYS_GETGROUPS, uintptr(n), uintptr(unsafe.Pointer(list)), 0)
  1449  	nn = int(r0)
  1450  	if e1 != 0 {
  1451  		err = errnoErr(e1)
  1452  	}
  1453  	return
  1454  }
  1455  
  1456  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1457  
  1458  func setgroups(n int, list *_Gid_t) (err error) {
  1459  	_, _, e1 := RawSyscall(SYS_SETGROUPS, uintptr(n), uintptr(unsafe.Pointer(list)), 0)
  1460  	if e1 != 0 {
  1461  		err = errnoErr(e1)
  1462  	}
  1463  	return
  1464  }
  1465  
  1466  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1467  
  1468  func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) {
  1469  	_, _, e1 := Syscall6(SYS_GETSOCKOPT, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(unsafe.Pointer(vallen)), 0)
  1470  	if e1 != 0 {
  1471  		err = errnoErr(e1)
  1472  	}
  1473  	return
  1474  }
  1475  
  1476  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1477  
  1478  func setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) {
  1479  	_, _, e1 := Syscall6(SYS_SETSOCKOPT, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(vallen), 0)
  1480  	if e1 != 0 {
  1481  		err = errnoErr(e1)
  1482  	}
  1483  	return
  1484  }
  1485  
  1486  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1487  
  1488  func socket(domain int, typ int, proto int) (fd int, err error) {
  1489  	r0, _, e1 := RawSyscall(SYS_SOCKET, uintptr(domain), uintptr(typ), uintptr(proto))
  1490  	fd = int(r0)
  1491  	if e1 != 0 {
  1492  		err = errnoErr(e1)
  1493  	}
  1494  	return
  1495  }
  1496  
  1497  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1498  
  1499  func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) {
  1500  	_, _, e1 := RawSyscall6(SYS_SOCKETPAIR, uintptr(domain), uintptr(typ), uintptr(proto), uintptr(unsafe.Pointer(fd)), 0, 0)
  1501  	if e1 != 0 {
  1502  		err = errnoErr(e1)
  1503  	}
  1504  	return
  1505  }
  1506  
  1507  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1508  
  1509  func getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
  1510  	_, _, e1 := RawSyscall(SYS_GETPEERNAME, uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
  1511  	if e1 != 0 {
  1512  		err = errnoErr(e1)
  1513  	}
  1514  	return
  1515  }
  1516  
  1517  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1518  
  1519  func getsockname(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
  1520  	_, _, e1 := RawSyscall(SYS_GETSOCKNAME, uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
  1521  	if e1 != 0 {
  1522  		err = errnoErr(e1)
  1523  	}
  1524  	return
  1525  }
  1526  
  1527  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1528  
  1529  func recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) {
  1530  	var _p0 unsafe.Pointer
  1531  	if len(p) > 0 {
  1532  		_p0 = unsafe.Pointer(&p[0])
  1533  	} else {
  1534  		_p0 = unsafe.Pointer(&_zero)
  1535  	}
  1536  	r0, _, e1 := Syscall6(SYS_RECVFROM, uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(flags), uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(fromlen)))
  1537  	n = int(r0)
  1538  	if e1 != 0 {
  1539  		err = errnoErr(e1)
  1540  	}
  1541  	return
  1542  }
  1543  
  1544  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1545  
  1546  func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) {
  1547  	var _p0 unsafe.Pointer
  1548  	if len(buf) > 0 {
  1549  		_p0 = unsafe.Pointer(&buf[0])
  1550  	} else {
  1551  		_p0 = unsafe.Pointer(&_zero)
  1552  	}
  1553  	_, _, e1 := Syscall6(SYS_SENDTO, uintptr(s), uintptr(_p0), uintptr(len(buf)), uintptr(flags), uintptr(to), uintptr(addrlen))
  1554  	if e1 != 0 {
  1555  		err = errnoErr(e1)
  1556  	}
  1557  	return
  1558  }
  1559  
  1560  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1561  
  1562  func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
  1563  	r0, _, e1 := Syscall(SYS_RECVMSG, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
  1564  	n = int(r0)
  1565  	if e1 != 0 {
  1566  		err = errnoErr(e1)
  1567  	}
  1568  	return
  1569  }
  1570  
  1571  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1572  
  1573  func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) {
  1574  	r0, _, e1 := Syscall(SYS_SENDMSG, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
  1575  	n = int(r0)
  1576  	if e1 != 0 {
  1577  		err = errnoErr(e1)
  1578  	}
  1579  	return
  1580  }
  1581  
  1582  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1583  
  1584  func InotifyInit() (fd int, err error) {
  1585  	r0, _, e1 := RawSyscall(SYS_INOTIFY_INIT, 0, 0, 0)
  1586  	fd = int(r0)
  1587  	if e1 != 0 {
  1588  		err = errnoErr(e1)
  1589  	}
  1590  	return
  1591  }
  1592  
  1593  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1594  
  1595  func Ioperm(from int, num int, on int) (err error) {
  1596  	_, _, e1 := Syscall(SYS_IOPERM, uintptr(from), uintptr(num), uintptr(on))
  1597  	if e1 != 0 {
  1598  		err = errnoErr(e1)
  1599  	}
  1600  	return
  1601  }
  1602  
  1603  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1604  
  1605  func Iopl(level int) (err error) {
  1606  	_, _, e1 := Syscall(SYS_IOPL, uintptr(level), 0, 0)
  1607  	if e1 != 0 {
  1608  		err = errnoErr(e1)
  1609  	}
  1610  	return
  1611  }
  1612  
  1613  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1614  
  1615  func Gettimeofday(tv *Timeval) (err error) {
  1616  	_, _, e1 := RawSyscall(SYS_GETTIMEOFDAY, uintptr(unsafe.Pointer(tv)), 0, 0)
  1617  	if e1 != 0 {
  1618  		err = errnoErr(e1)
  1619  	}
  1620  	return
  1621  }
  1622  
  1623  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1624  
  1625  func Time(t *Time_t) (tt Time_t, err error) {
  1626  	r0, _, e1 := RawSyscall(SYS_TIME, uintptr(unsafe.Pointer(t)), 0, 0)
  1627  	tt = Time_t(r0)
  1628  	if e1 != 0 {
  1629  		err = errnoErr(e1)
  1630  	}
  1631  	return
  1632  }
  1633  
  1634  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1635  
  1636  func Lstat(path string, stat *Stat_t) (err error) {
  1637  	var _p0 *byte
  1638  	_p0, err = BytePtrFromString(path)
  1639  	if err != nil {
  1640  		return
  1641  	}
  1642  	_, _, e1 := Syscall(SYS_LSTAT64, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
  1643  	if e1 != 0 {
  1644  		err = errnoErr(e1)
  1645  	}
  1646  	return
  1647  }
  1648  
  1649  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1650  
  1651  func Fstat(fd int, stat *Stat_t) (err error) {
  1652  	_, _, e1 := Syscall(SYS_FSTAT64, uintptr(fd), uintptr(unsafe.Pointer(stat)), 0)
  1653  	if e1 != 0 {
  1654  		err = errnoErr(e1)
  1655  	}
  1656  	return
  1657  }
  1658  
  1659  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1660  
  1661  func Stat(path string, stat *Stat_t) (err error) {
  1662  	var _p0 *byte
  1663  	_p0, err = BytePtrFromString(path)
  1664  	if err != nil {
  1665  		return
  1666  	}
  1667  	_, _, e1 := Syscall(SYS_STAT64, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
  1668  	if e1 != 0 {
  1669  		err = errnoErr(e1)
  1670  	}
  1671  	return
  1672  }
  1673  
  1674  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1675  
  1676  func EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error) {
  1677  	var _p0 unsafe.Pointer
  1678  	if len(events) > 0 {
  1679  		_p0 = unsafe.Pointer(&events[0])
  1680  	} else {
  1681  		_p0 = unsafe.Pointer(&_zero)
  1682  	}
  1683  	r0, _, e1 := Syscall6(SYS_EPOLL_WAIT, uintptr(epfd), uintptr(_p0), uintptr(len(events)), uintptr(msec), 0, 0)
  1684  	n = int(r0)
  1685  	if e1 != 0 {
  1686  		err = errnoErr(e1)
  1687  	}
  1688  	return
  1689  }
  1690  
  1691  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1692  
  1693  func pipe2(p *[2]_C_int, flags int) (err error) {
  1694  	_, _, e1 := RawSyscall(SYS_PIPE2, uintptr(unsafe.Pointer(p)), uintptr(flags), 0)
  1695  	if e1 != 0 {
  1696  		err = errnoErr(e1)
  1697  	}
  1698  	return
  1699  }
  1700  
  1701  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1702  
  1703  func pipe() (p1 int, p2 int, err error) {
  1704  	r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
  1705  	p1 = int(r0)
  1706  	p2 = int(r1)
  1707  	if e1 != 0 {
  1708  		err = errnoErr(e1)
  1709  	}
  1710  	return
  1711  }
  1712  
  1713  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1714  
  1715  func mmap2(addr uintptr, length uintptr, prot int, flags int, fd int, pageOffset uintptr) (xaddr uintptr, err error) {
  1716  	r0, _, e1 := Syscall6(SYS_MMAP2, uintptr(addr), uintptr(length), uintptr(prot), uintptr(flags), uintptr(fd), uintptr(pageOffset))
  1717  	xaddr = uintptr(r0)
  1718  	if e1 != 0 {
  1719  		err = errnoErr(e1)
  1720  	}
  1721  	return
  1722  }
  1723  
  1724  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1725  
  1726  func getrlimit(resource int, rlim *rlimit32) (err error) {
  1727  	_, _, e1 := RawSyscall(SYS_GETRLIMIT, uintptr(resource), uintptr(unsafe.Pointer(rlim)), 0)
  1728  	if e1 != 0 {
  1729  		err = errnoErr(e1)
  1730  	}
  1731  	return
  1732  }
  1733  
  1734  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1735  
  1736  func setrlimit(resource int, rlim *rlimit32) (err error) {
  1737  	_, _, e1 := RawSyscall(SYS_SETRLIMIT, uintptr(resource), uintptr(unsafe.Pointer(rlim)), 0)
  1738  	if e1 != 0 {
  1739  		err = errnoErr(e1)
  1740  	}
  1741  	return
  1742  }
  1743  

View as plain text