Home | History | Annotate | Download | only in syscall
      1 // mksyscall.pl -l32 syscall_bsd.go syscall_freebsd.go syscall_freebsd_386.go
      2 // MACHINE GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
      3 
      4 // +build 386,freebsd
      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 getgroups(ngid int, gid *_Gid_t) (n int, err error) {
     13 	r0, _, e1 := RawSyscall(SYS_GETGROUPS, uintptr(ngid), uintptr(unsafe.Pointer(gid)), 0)
     14 	n = int(r0)
     15 	if e1 != 0 {
     16 		err = errnoErr(e1)
     17 	}
     18 	return
     19 }
     20 
     21 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     22 
     23 func setgroups(ngid int, gid *_Gid_t) (err error) {
     24 	_, _, e1 := RawSyscall(SYS_SETGROUPS, uintptr(ngid), uintptr(unsafe.Pointer(gid)), 0)
     25 	if e1 != 0 {
     26 		err = errnoErr(e1)
     27 	}
     28 	return
     29 }
     30 
     31 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     32 
     33 func wait4(pid int, wstatus *_C_int, options int, rusage *Rusage) (wpid int, err error) {
     34 	r0, _, e1 := Syscall6(SYS_WAIT4, uintptr(pid), uintptr(unsafe.Pointer(wstatus)), uintptr(options), uintptr(unsafe.Pointer(rusage)), 0, 0)
     35 	wpid = int(r0)
     36 	if e1 != 0 {
     37 		err = errnoErr(e1)
     38 	}
     39 	return
     40 }
     41 
     42 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     43 
     44 func accept(s int, rsa *RawSockaddrAny, addrlen *_Socklen) (fd int, err error) {
     45 	r0, _, e1 := Syscall(SYS_ACCEPT, uintptr(s), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
     46 	fd = int(r0)
     47 	if e1 != 0 {
     48 		err = errnoErr(e1)
     49 	}
     50 	return
     51 }
     52 
     53 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     54 
     55 func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
     56 	_, _, e1 := Syscall(SYS_BIND, uintptr(s), uintptr(addr), uintptr(addrlen))
     57 	if e1 != 0 {
     58 		err = errnoErr(e1)
     59 	}
     60 	return
     61 }
     62 
     63 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     64 
     65 func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
     66 	_, _, e1 := Syscall(SYS_CONNECT, uintptr(s), uintptr(addr), uintptr(addrlen))
     67 	if e1 != 0 {
     68 		err = errnoErr(e1)
     69 	}
     70 	return
     71 }
     72 
     73 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     74 
     75 func socket(domain int, typ int, proto int) (fd int, err error) {
     76 	r0, _, e1 := RawSyscall(SYS_SOCKET, uintptr(domain), uintptr(typ), uintptr(proto))
     77 	fd = int(r0)
     78 	if e1 != 0 {
     79 		err = errnoErr(e1)
     80 	}
     81 	return
     82 }
     83 
     84 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     85 
     86 func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) {
     87 	_, _, e1 := Syscall6(SYS_GETSOCKOPT, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(unsafe.Pointer(vallen)), 0)
     88 	if e1 != 0 {
     89 		err = errnoErr(e1)
     90 	}
     91 	return
     92 }
     93 
     94 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
     95 
     96 func setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) {
     97 	_, _, e1 := Syscall6(SYS_SETSOCKOPT, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(vallen), 0)
     98 	if e1 != 0 {
     99 		err = errnoErr(e1)
    100 	}
    101 	return
    102 }
    103 
    104 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    105 
    106 func getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
    107 	_, _, e1 := RawSyscall(SYS_GETPEERNAME, uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
    108 	if e1 != 0 {
    109 		err = errnoErr(e1)
    110 	}
    111 	return
    112 }
    113 
    114 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    115 
    116 func getsockname(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
    117 	_, _, e1 := RawSyscall(SYS_GETSOCKNAME, uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
    118 	if e1 != 0 {
    119 		err = errnoErr(e1)
    120 	}
    121 	return
    122 }
    123 
    124 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    125 
    126 func Shutdown(s int, how int) (err error) {
    127 	_, _, e1 := Syscall(SYS_SHUTDOWN, uintptr(s), uintptr(how), 0)
    128 	if e1 != 0 {
    129 		err = errnoErr(e1)
    130 	}
    131 	return
    132 }
    133 
    134 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    135 
    136 func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) {
    137 	_, _, e1 := RawSyscall6(SYS_SOCKETPAIR, uintptr(domain), uintptr(typ), uintptr(proto), uintptr(unsafe.Pointer(fd)), 0, 0)
    138 	if e1 != 0 {
    139 		err = errnoErr(e1)
    140 	}
    141 	return
    142 }
    143 
    144 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    145 
    146 func recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) {
    147 	var _p0 unsafe.Pointer
    148 	if len(p) > 0 {
    149 		_p0 = unsafe.Pointer(&p[0])
    150 	} else {
    151 		_p0 = unsafe.Pointer(&_zero)
    152 	}
    153 	r0, _, e1 := Syscall6(SYS_RECVFROM, uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(flags), uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(fromlen)))
    154 	n = int(r0)
    155 	if e1 != 0 {
    156 		err = errnoErr(e1)
    157 	}
    158 	return
    159 }
    160 
    161 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    162 
    163 func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) {
    164 	var _p0 unsafe.Pointer
    165 	if len(buf) > 0 {
    166 		_p0 = unsafe.Pointer(&buf[0])
    167 	} else {
    168 		_p0 = unsafe.Pointer(&_zero)
    169 	}
    170 	_, _, e1 := Syscall6(SYS_SENDTO, uintptr(s), uintptr(_p0), uintptr(len(buf)), uintptr(flags), uintptr(to), uintptr(addrlen))
    171 	if e1 != 0 {
    172 		err = errnoErr(e1)
    173 	}
    174 	return
    175 }
    176 
    177 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    178 
    179 func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
    180 	r0, _, e1 := Syscall(SYS_RECVMSG, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
    181 	n = int(r0)
    182 	if e1 != 0 {
    183 		err = errnoErr(e1)
    184 	}
    185 	return
    186 }
    187 
    188 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    189 
    190 func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) {
    191 	r0, _, e1 := Syscall(SYS_SENDMSG, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
    192 	n = int(r0)
    193 	if e1 != 0 {
    194 		err = errnoErr(e1)
    195 	}
    196 	return
    197 }
    198 
    199 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    200 
    201 func kevent(kq int, change unsafe.Pointer, nchange int, event unsafe.Pointer, nevent int, timeout *Timespec) (n int, err error) {
    202 	r0, _, e1 := Syscall6(SYS_KEVENT, uintptr(kq), uintptr(change), uintptr(nchange), uintptr(event), uintptr(nevent), uintptr(unsafe.Pointer(timeout)))
    203 	n = int(r0)
    204 	if e1 != 0 {
    205 		err = errnoErr(e1)
    206 	}
    207 	return
    208 }
    209 
    210 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    211 
    212 func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
    213 	var _p0 unsafe.Pointer
    214 	if len(mib) > 0 {
    215 		_p0 = unsafe.Pointer(&mib[0])
    216 	} else {
    217 		_p0 = unsafe.Pointer(&_zero)
    218 	}
    219 	_, _, e1 := Syscall6(SYS___SYSCTL, uintptr(_p0), uintptr(len(mib)), uintptr(unsafe.Pointer(old)), uintptr(unsafe.Pointer(oldlen)), uintptr(unsafe.Pointer(new)), uintptr(newlen))
    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 utimes(path string, timeval *[2]Timeval) (err error) {
    229 	var _p0 *byte
    230 	_p0, err = BytePtrFromString(path)
    231 	if err != nil {
    232 		return
    233 	}
    234 	_, _, e1 := Syscall(SYS_UTIMES, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(timeval)), 0)
    235 	use(unsafe.Pointer(_p0))
    236 	if e1 != 0 {
    237 		err = errnoErr(e1)
    238 	}
    239 	return
    240 }
    241 
    242 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    243 
    244 func futimes(fd int, timeval *[2]Timeval) (err error) {
    245 	_, _, e1 := Syscall(SYS_FUTIMES, uintptr(fd), uintptr(unsafe.Pointer(timeval)), 0)
    246 	if e1 != 0 {
    247 		err = errnoErr(e1)
    248 	}
    249 	return
    250 }
    251 
    252 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    253 
    254 func fcntl(fd int, cmd int, arg int) (val int, err error) {
    255 	r0, _, e1 := Syscall(SYS_FCNTL, uintptr(fd), uintptr(cmd), uintptr(arg))
    256 	val = int(r0)
    257 	if e1 != 0 {
    258 		err = errnoErr(e1)
    259 	}
    260 	return
    261 }
    262 
    263 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    264 
    265 func pipe() (r int, w int, err error) {
    266 	r0, r1, e1 := RawSyscall(SYS_PIPE, 0, 0, 0)
    267 	r = int(r0)
    268 	w = int(r1)
    269 	if e1 != 0 {
    270 		err = errnoErr(e1)
    271 	}
    272 	return
    273 }
    274 
    275 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    276 
    277 func Access(path string, mode uint32) (err error) {
    278 	var _p0 *byte
    279 	_p0, err = BytePtrFromString(path)
    280 	if err != nil {
    281 		return
    282 	}
    283 	_, _, e1 := Syscall(SYS_ACCESS, uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
    284 	use(unsafe.Pointer(_p0))
    285 	if e1 != 0 {
    286 		err = errnoErr(e1)
    287 	}
    288 	return
    289 }
    290 
    291 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    292 
    293 func Adjtime(delta *Timeval, olddelta *Timeval) (err error) {
    294 	_, _, e1 := Syscall(SYS_ADJTIME, uintptr(unsafe.Pointer(delta)), uintptr(unsafe.Pointer(olddelta)), 0)
    295 	if e1 != 0 {
    296 		err = errnoErr(e1)
    297 	}
    298 	return
    299 }
    300 
    301 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    302 
    303 func Chdir(path string) (err error) {
    304 	var _p0 *byte
    305 	_p0, err = BytePtrFromString(path)
    306 	if err != nil {
    307 		return
    308 	}
    309 	_, _, e1 := Syscall(SYS_CHDIR, uintptr(unsafe.Pointer(_p0)), 0, 0)
    310 	use(unsafe.Pointer(_p0))
    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 Chflags(path string, flags int) (err error) {
    320 	var _p0 *byte
    321 	_p0, err = BytePtrFromString(path)
    322 	if err != nil {
    323 		return
    324 	}
    325 	_, _, e1 := Syscall(SYS_CHFLAGS, uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
    326 	use(unsafe.Pointer(_p0))
    327 	if e1 != 0 {
    328 		err = errnoErr(e1)
    329 	}
    330 	return
    331 }
    332 
    333 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    334 
    335 func Chmod(path string, mode uint32) (err error) {
    336 	var _p0 *byte
    337 	_p0, err = BytePtrFromString(path)
    338 	if err != nil {
    339 		return
    340 	}
    341 	_, _, e1 := Syscall(SYS_CHMOD, uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
    342 	use(unsafe.Pointer(_p0))
    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 Chown(path string, uid int, gid int) (err error) {
    352 	var _p0 *byte
    353 	_p0, err = BytePtrFromString(path)
    354 	if err != nil {
    355 		return
    356 	}
    357 	_, _, e1 := Syscall(SYS_CHOWN, uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid))
    358 	use(unsafe.Pointer(_p0))
    359 	if e1 != 0 {
    360 		err = errnoErr(e1)
    361 	}
    362 	return
    363 }
    364 
    365 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    366 
    367 func Chroot(path string) (err error) {
    368 	var _p0 *byte
    369 	_p0, err = BytePtrFromString(path)
    370 	if err != nil {
    371 		return
    372 	}
    373 	_, _, e1 := Syscall(SYS_CHROOT, uintptr(unsafe.Pointer(_p0)), 0, 0)
    374 	use(unsafe.Pointer(_p0))
    375 	if e1 != 0 {
    376 		err = errnoErr(e1)
    377 	}
    378 	return
    379 }
    380 
    381 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    382 
    383 func Close(fd int) (err error) {
    384 	_, _, e1 := Syscall(SYS_CLOSE, uintptr(fd), 0, 0)
    385 	if e1 != 0 {
    386 		err = errnoErr(e1)
    387 	}
    388 	return
    389 }
    390 
    391 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    392 
    393 func Dup(fd int) (nfd int, err error) {
    394 	r0, _, e1 := Syscall(SYS_DUP, uintptr(fd), 0, 0)
    395 	nfd = int(r0)
    396 	if e1 != 0 {
    397 		err = errnoErr(e1)
    398 	}
    399 	return
    400 }
    401 
    402 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    403 
    404 func Dup2(from int, to int) (err error) {
    405 	_, _, e1 := Syscall(SYS_DUP2, uintptr(from), uintptr(to), 0)
    406 	if e1 != 0 {
    407 		err = errnoErr(e1)
    408 	}
    409 	return
    410 }
    411 
    412 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    413 
    414 func Exit(code int) {
    415 	Syscall(SYS_EXIT, uintptr(code), 0, 0)
    416 	return
    417 }
    418 
    419 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    420 
    421 func Fchdir(fd int) (err error) {
    422 	_, _, e1 := Syscall(SYS_FCHDIR, uintptr(fd), 0, 0)
    423 	if e1 != 0 {
    424 		err = errnoErr(e1)
    425 	}
    426 	return
    427 }
    428 
    429 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    430 
    431 func Fchflags(fd int, flags int) (err error) {
    432 	_, _, e1 := Syscall(SYS_FCHFLAGS, uintptr(fd), uintptr(flags), 0)
    433 	if e1 != 0 {
    434 		err = errnoErr(e1)
    435 	}
    436 	return
    437 }
    438 
    439 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    440 
    441 func Fchmod(fd int, mode uint32) (err error) {
    442 	_, _, e1 := Syscall(SYS_FCHMOD, uintptr(fd), uintptr(mode), 0)
    443 	if e1 != 0 {
    444 		err = errnoErr(e1)
    445 	}
    446 	return
    447 }
    448 
    449 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    450 
    451 func Fchown(fd int, uid int, gid int) (err error) {
    452 	_, _, e1 := Syscall(SYS_FCHOWN, uintptr(fd), uintptr(uid), uintptr(gid))
    453 	if e1 != 0 {
    454 		err = errnoErr(e1)
    455 	}
    456 	return
    457 }
    458 
    459 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    460 
    461 func Flock(fd int, how int) (err error) {
    462 	_, _, e1 := Syscall(SYS_FLOCK, uintptr(fd), uintptr(how), 0)
    463 	if e1 != 0 {
    464 		err = errnoErr(e1)
    465 	}
    466 	return
    467 }
    468 
    469 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    470 
    471 func Fpathconf(fd int, name int) (val int, err error) {
    472 	r0, _, e1 := Syscall(SYS_FPATHCONF, uintptr(fd), uintptr(name), 0)
    473 	val = int(r0)
    474 	if e1 != 0 {
    475 		err = errnoErr(e1)
    476 	}
    477 	return
    478 }
    479 
    480 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    481 
    482 func Fstat(fd int, stat *Stat_t) (err error) {
    483 	_, _, e1 := Syscall(SYS_FSTAT, uintptr(fd), uintptr(unsafe.Pointer(stat)), 0)
    484 	if e1 != 0 {
    485 		err = errnoErr(e1)
    486 	}
    487 	return
    488 }
    489 
    490 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    491 
    492 func Fstatfs(fd int, stat *Statfs_t) (err error) {
    493 	_, _, e1 := Syscall(SYS_FSTATFS, uintptr(fd), uintptr(unsafe.Pointer(stat)), 0)
    494 	if e1 != 0 {
    495 		err = errnoErr(e1)
    496 	}
    497 	return
    498 }
    499 
    500 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    501 
    502 func Fsync(fd int) (err error) {
    503 	_, _, e1 := Syscall(SYS_FSYNC, uintptr(fd), 0, 0)
    504 	if e1 != 0 {
    505 		err = errnoErr(e1)
    506 	}
    507 	return
    508 }
    509 
    510 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    511 
    512 func Ftruncate(fd int, length int64) (err error) {
    513 	_, _, e1 := Syscall(SYS_FTRUNCATE, uintptr(fd), uintptr(length), uintptr(length>>32))
    514 	if e1 != 0 {
    515 		err = errnoErr(e1)
    516 	}
    517 	return
    518 }
    519 
    520 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    521 
    522 func Getdirentries(fd int, buf []byte, basep *uintptr) (n int, err error) {
    523 	var _p0 unsafe.Pointer
    524 	if len(buf) > 0 {
    525 		_p0 = unsafe.Pointer(&buf[0])
    526 	} else {
    527 		_p0 = unsafe.Pointer(&_zero)
    528 	}
    529 	r0, _, e1 := Syscall6(SYS_GETDIRENTRIES, uintptr(fd), uintptr(_p0), uintptr(len(buf)), uintptr(unsafe.Pointer(basep)), 0, 0)
    530 	n = int(r0)
    531 	if e1 != 0 {
    532 		err = errnoErr(e1)
    533 	}
    534 	return
    535 }
    536 
    537 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    538 
    539 func Getdtablesize() (size int) {
    540 	r0, _, _ := Syscall(SYS_GETDTABLESIZE, 0, 0, 0)
    541 	size = int(r0)
    542 	return
    543 }
    544 
    545 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    546 
    547 func Getegid() (egid int) {
    548 	r0, _, _ := RawSyscall(SYS_GETEGID, 0, 0, 0)
    549 	egid = int(r0)
    550 	return
    551 }
    552 
    553 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    554 
    555 func Geteuid() (uid int) {
    556 	r0, _, _ := RawSyscall(SYS_GETEUID, 0, 0, 0)
    557 	uid = int(r0)
    558 	return
    559 }
    560 
    561 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    562 
    563 func Getgid() (gid int) {
    564 	r0, _, _ := RawSyscall(SYS_GETGID, 0, 0, 0)
    565 	gid = int(r0)
    566 	return
    567 }
    568 
    569 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    570 
    571 func Getpgid(pid int) (pgid int, err error) {
    572 	r0, _, e1 := RawSyscall(SYS_GETPGID, uintptr(pid), 0, 0)
    573 	pgid = int(r0)
    574 	if e1 != 0 {
    575 		err = errnoErr(e1)
    576 	}
    577 	return
    578 }
    579 
    580 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    581 
    582 func Getpgrp() (pgrp int) {
    583 	r0, _, _ := RawSyscall(SYS_GETPGRP, 0, 0, 0)
    584 	pgrp = int(r0)
    585 	return
    586 }
    587 
    588 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    589 
    590 func Getpid() (pid int) {
    591 	r0, _, _ := RawSyscall(SYS_GETPID, 0, 0, 0)
    592 	pid = int(r0)
    593 	return
    594 }
    595 
    596 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    597 
    598 func Getppid() (ppid int) {
    599 	r0, _, _ := RawSyscall(SYS_GETPPID, 0, 0, 0)
    600 	ppid = int(r0)
    601 	return
    602 }
    603 
    604 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    605 
    606 func Getpriority(which int, who int) (prio int, err error) {
    607 	r0, _, e1 := Syscall(SYS_GETPRIORITY, uintptr(which), uintptr(who), 0)
    608 	prio = int(r0)
    609 	if e1 != 0 {
    610 		err = errnoErr(e1)
    611 	}
    612 	return
    613 }
    614 
    615 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    616 
    617 func Getrlimit(which int, lim *Rlimit) (err error) {
    618 	_, _, e1 := RawSyscall(SYS_GETRLIMIT, uintptr(which), uintptr(unsafe.Pointer(lim)), 0)
    619 	if e1 != 0 {
    620 		err = errnoErr(e1)
    621 	}
    622 	return
    623 }
    624 
    625 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    626 
    627 func Getrusage(who int, rusage *Rusage) (err error) {
    628 	_, _, e1 := RawSyscall(SYS_GETRUSAGE, uintptr(who), uintptr(unsafe.Pointer(rusage)), 0)
    629 	if e1 != 0 {
    630 		err = errnoErr(e1)
    631 	}
    632 	return
    633 }
    634 
    635 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    636 
    637 func Getsid(pid int) (sid int, err error) {
    638 	r0, _, e1 := RawSyscall(SYS_GETSID, uintptr(pid), 0, 0)
    639 	sid = int(r0)
    640 	if e1 != 0 {
    641 		err = errnoErr(e1)
    642 	}
    643 	return
    644 }
    645 
    646 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    647 
    648 func Gettimeofday(tv *Timeval) (err error) {
    649 	_, _, e1 := RawSyscall(SYS_GETTIMEOFDAY, uintptr(unsafe.Pointer(tv)), 0, 0)
    650 	if e1 != 0 {
    651 		err = errnoErr(e1)
    652 	}
    653 	return
    654 }
    655 
    656 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    657 
    658 func Getuid() (uid int) {
    659 	r0, _, _ := RawSyscall(SYS_GETUID, 0, 0, 0)
    660 	uid = int(r0)
    661 	return
    662 }
    663 
    664 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    665 
    666 func Issetugid() (tainted bool) {
    667 	r0, _, _ := Syscall(SYS_ISSETUGID, 0, 0, 0)
    668 	tainted = bool(r0 != 0)
    669 	return
    670 }
    671 
    672 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    673 
    674 func Kill(pid int, signum Signal) (err error) {
    675 	_, _, e1 := Syscall(SYS_KILL, uintptr(pid), uintptr(signum), 0)
    676 	if e1 != 0 {
    677 		err = errnoErr(e1)
    678 	}
    679 	return
    680 }
    681 
    682 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    683 
    684 func Kqueue() (fd int, err error) {
    685 	r0, _, e1 := Syscall(SYS_KQUEUE, 0, 0, 0)
    686 	fd = int(r0)
    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 Lchown(path string, uid int, gid int) (err error) {
    696 	var _p0 *byte
    697 	_p0, err = BytePtrFromString(path)
    698 	if err != nil {
    699 		return
    700 	}
    701 	_, _, e1 := Syscall(SYS_LCHOWN, uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid))
    702 	use(unsafe.Pointer(_p0))
    703 	if e1 != 0 {
    704 		err = errnoErr(e1)
    705 	}
    706 	return
    707 }
    708 
    709 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    710 
    711 func Link(path string, link string) (err error) {
    712 	var _p0 *byte
    713 	_p0, err = BytePtrFromString(path)
    714 	if err != nil {
    715 		return
    716 	}
    717 	var _p1 *byte
    718 	_p1, err = BytePtrFromString(link)
    719 	if err != nil {
    720 		return
    721 	}
    722 	_, _, e1 := Syscall(SYS_LINK, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
    723 	use(unsafe.Pointer(_p0))
    724 	use(unsafe.Pointer(_p1))
    725 	if e1 != 0 {
    726 		err = errnoErr(e1)
    727 	}
    728 	return
    729 }
    730 
    731 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    732 
    733 func Listen(s int, backlog int) (err error) {
    734 	_, _, e1 := Syscall(SYS_LISTEN, uintptr(s), uintptr(backlog), 0)
    735 	if e1 != 0 {
    736 		err = errnoErr(e1)
    737 	}
    738 	return
    739 }
    740 
    741 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    742 
    743 func Lstat(path string, stat *Stat_t) (err error) {
    744 	var _p0 *byte
    745 	_p0, err = BytePtrFromString(path)
    746 	if err != nil {
    747 		return
    748 	}
    749 	_, _, e1 := Syscall(SYS_LSTAT, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
    750 	use(unsafe.Pointer(_p0))
    751 	if e1 != 0 {
    752 		err = errnoErr(e1)
    753 	}
    754 	return
    755 }
    756 
    757 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    758 
    759 func Mkdir(path string, mode uint32) (err error) {
    760 	var _p0 *byte
    761 	_p0, err = BytePtrFromString(path)
    762 	if err != nil {
    763 		return
    764 	}
    765 	_, _, e1 := Syscall(SYS_MKDIR, uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
    766 	use(unsafe.Pointer(_p0))
    767 	if e1 != 0 {
    768 		err = errnoErr(e1)
    769 	}
    770 	return
    771 }
    772 
    773 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    774 
    775 func Mkfifo(path string, mode uint32) (err error) {
    776 	var _p0 *byte
    777 	_p0, err = BytePtrFromString(path)
    778 	if err != nil {
    779 		return
    780 	}
    781 	_, _, e1 := Syscall(SYS_MKFIFO, uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
    782 	use(unsafe.Pointer(_p0))
    783 	if e1 != 0 {
    784 		err = errnoErr(e1)
    785 	}
    786 	return
    787 }
    788 
    789 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    790 
    791 func Mknod(path string, mode uint32, dev int) (err error) {
    792 	var _p0 *byte
    793 	_p0, err = BytePtrFromString(path)
    794 	if err != nil {
    795 		return
    796 	}
    797 	_, _, e1 := Syscall(SYS_MKNOD, uintptr(unsafe.Pointer(_p0)), uintptr(mode), uintptr(dev))
    798 	use(unsafe.Pointer(_p0))
    799 	if e1 != 0 {
    800 		err = errnoErr(e1)
    801 	}
    802 	return
    803 }
    804 
    805 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    806 
    807 func Nanosleep(time *Timespec, leftover *Timespec) (err error) {
    808 	_, _, e1 := Syscall(SYS_NANOSLEEP, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0)
    809 	if e1 != 0 {
    810 		err = errnoErr(e1)
    811 	}
    812 	return
    813 }
    814 
    815 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    816 
    817 func Open(path string, mode int, perm uint32) (fd int, err error) {
    818 	var _p0 *byte
    819 	_p0, err = BytePtrFromString(path)
    820 	if err != nil {
    821 		return
    822 	}
    823 	r0, _, e1 := Syscall(SYS_OPEN, uintptr(unsafe.Pointer(_p0)), uintptr(mode), uintptr(perm))
    824 	use(unsafe.Pointer(_p0))
    825 	fd = int(r0)
    826 	if e1 != 0 {
    827 		err = errnoErr(e1)
    828 	}
    829 	return
    830 }
    831 
    832 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    833 
    834 func Pathconf(path string, name int) (val int, err error) {
    835 	var _p0 *byte
    836 	_p0, err = BytePtrFromString(path)
    837 	if err != nil {
    838 		return
    839 	}
    840 	r0, _, e1 := Syscall(SYS_PATHCONF, uintptr(unsafe.Pointer(_p0)), uintptr(name), 0)
    841 	use(unsafe.Pointer(_p0))
    842 	val = int(r0)
    843 	if e1 != 0 {
    844 		err = errnoErr(e1)
    845 	}
    846 	return
    847 }
    848 
    849 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    850 
    851 func Pread(fd int, p []byte, offset int64) (n int, err error) {
    852 	var _p0 unsafe.Pointer
    853 	if len(p) > 0 {
    854 		_p0 = unsafe.Pointer(&p[0])
    855 	} else {
    856 		_p0 = unsafe.Pointer(&_zero)
    857 	}
    858 	r0, _, e1 := Syscall6(SYS_PREAD, uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(offset), uintptr(offset>>32), 0)
    859 	n = int(r0)
    860 	if e1 != 0 {
    861 		err = errnoErr(e1)
    862 	}
    863 	return
    864 }
    865 
    866 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    867 
    868 func Pwrite(fd int, p []byte, offset int64) (n int, err error) {
    869 	var _p0 unsafe.Pointer
    870 	if len(p) > 0 {
    871 		_p0 = unsafe.Pointer(&p[0])
    872 	} else {
    873 		_p0 = unsafe.Pointer(&_zero)
    874 	}
    875 	r0, _, e1 := Syscall6(SYS_PWRITE, uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(offset), uintptr(offset>>32), 0)
    876 	n = int(r0)
    877 	if e1 != 0 {
    878 		err = errnoErr(e1)
    879 	}
    880 	return
    881 }
    882 
    883 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    884 
    885 func read(fd int, p []byte) (n int, err error) {
    886 	var _p0 unsafe.Pointer
    887 	if len(p) > 0 {
    888 		_p0 = unsafe.Pointer(&p[0])
    889 	} else {
    890 		_p0 = unsafe.Pointer(&_zero)
    891 	}
    892 	r0, _, e1 := Syscall(SYS_READ, uintptr(fd), uintptr(_p0), uintptr(len(p)))
    893 	n = int(r0)
    894 	if e1 != 0 {
    895 		err = errnoErr(e1)
    896 	}
    897 	return
    898 }
    899 
    900 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    901 
    902 func Readlink(path string, buf []byte) (n int, err error) {
    903 	var _p0 *byte
    904 	_p0, err = BytePtrFromString(path)
    905 	if err != nil {
    906 		return
    907 	}
    908 	var _p1 unsafe.Pointer
    909 	if len(buf) > 0 {
    910 		_p1 = unsafe.Pointer(&buf[0])
    911 	} else {
    912 		_p1 = unsafe.Pointer(&_zero)
    913 	}
    914 	r0, _, e1 := Syscall(SYS_READLINK, uintptr(unsafe.Pointer(_p0)), uintptr(_p1), uintptr(len(buf)))
    915 	use(unsafe.Pointer(_p0))
    916 	n = int(r0)
    917 	if e1 != 0 {
    918 		err = errnoErr(e1)
    919 	}
    920 	return
    921 }
    922 
    923 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    924 
    925 func Rename(from string, to string) (err error) {
    926 	var _p0 *byte
    927 	_p0, err = BytePtrFromString(from)
    928 	if err != nil {
    929 		return
    930 	}
    931 	var _p1 *byte
    932 	_p1, err = BytePtrFromString(to)
    933 	if err != nil {
    934 		return
    935 	}
    936 	_, _, e1 := Syscall(SYS_RENAME, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
    937 	use(unsafe.Pointer(_p0))
    938 	use(unsafe.Pointer(_p1))
    939 	if e1 != 0 {
    940 		err = errnoErr(e1)
    941 	}
    942 	return
    943 }
    944 
    945 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    946 
    947 func Revoke(path string) (err error) {
    948 	var _p0 *byte
    949 	_p0, err = BytePtrFromString(path)
    950 	if err != nil {
    951 		return
    952 	}
    953 	_, _, e1 := Syscall(SYS_REVOKE, uintptr(unsafe.Pointer(_p0)), 0, 0)
    954 	use(unsafe.Pointer(_p0))
    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 Rmdir(path string) (err error) {
    964 	var _p0 *byte
    965 	_p0, err = BytePtrFromString(path)
    966 	if err != nil {
    967 		return
    968 	}
    969 	_, _, e1 := Syscall(SYS_RMDIR, uintptr(unsafe.Pointer(_p0)), 0, 0)
    970 	use(unsafe.Pointer(_p0))
    971 	if e1 != 0 {
    972 		err = errnoErr(e1)
    973 	}
    974 	return
    975 }
    976 
    977 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    978 
    979 func Seek(fd int, offset int64, whence int) (newoffset int64, err error) {
    980 	r0, r1, e1 := Syscall6(SYS_LSEEK, uintptr(fd), uintptr(offset), uintptr(offset>>32), uintptr(whence), 0, 0)
    981 	newoffset = int64(int64(r1)<<32 | int64(r0))
    982 	if e1 != 0 {
    983 		err = errnoErr(e1)
    984 	}
    985 	return
    986 }
    987 
    988 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    989 
    990 func Select(n int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) (err error) {
    991 	_, _, e1 := Syscall6(SYS_SELECT, uintptr(n), uintptr(unsafe.Pointer(r)), uintptr(unsafe.Pointer(w)), uintptr(unsafe.Pointer(e)), uintptr(unsafe.Pointer(timeout)), 0)
    992 	if e1 != 0 {
    993 		err = errnoErr(e1)
    994 	}
    995 	return
    996 }
    997 
    998 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    999 
   1000 func Setegid(egid int) (err error) {
   1001 	_, _, e1 := RawSyscall(SYS_SETEGID, uintptr(egid), 0, 0)
   1002 	if e1 != 0 {
   1003 		err = errnoErr(e1)
   1004 	}
   1005 	return
   1006 }
   1007 
   1008 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1009 
   1010 func Seteuid(euid int) (err error) {
   1011 	_, _, e1 := RawSyscall(SYS_SETEUID, uintptr(euid), 0, 0)
   1012 	if e1 != 0 {
   1013 		err = errnoErr(e1)
   1014 	}
   1015 	return
   1016 }
   1017 
   1018 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1019 
   1020 func Setgid(gid int) (err error) {
   1021 	_, _, e1 := RawSyscall(SYS_SETGID, uintptr(gid), 0, 0)
   1022 	if e1 != 0 {
   1023 		err = errnoErr(e1)
   1024 	}
   1025 	return
   1026 }
   1027 
   1028 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1029 
   1030 func Setlogin(name string) (err error) {
   1031 	var _p0 *byte
   1032 	_p0, err = BytePtrFromString(name)
   1033 	if err != nil {
   1034 		return
   1035 	}
   1036 	_, _, e1 := Syscall(SYS_SETLOGIN, uintptr(unsafe.Pointer(_p0)), 0, 0)
   1037 	use(unsafe.Pointer(_p0))
   1038 	if e1 != 0 {
   1039 		err = errnoErr(e1)
   1040 	}
   1041 	return
   1042 }
   1043 
   1044 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1045 
   1046 func Setpgid(pid int, pgid int) (err error) {
   1047 	_, _, e1 := RawSyscall(SYS_SETPGID, uintptr(pid), uintptr(pgid), 0)
   1048 	if e1 != 0 {
   1049 		err = errnoErr(e1)
   1050 	}
   1051 	return
   1052 }
   1053 
   1054 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1055 
   1056 func Setpriority(which int, who int, prio int) (err error) {
   1057 	_, _, e1 := Syscall(SYS_SETPRIORITY, uintptr(which), uintptr(who), uintptr(prio))
   1058 	if e1 != 0 {
   1059 		err = errnoErr(e1)
   1060 	}
   1061 	return
   1062 }
   1063 
   1064 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1065 
   1066 func Setregid(rgid int, egid int) (err error) {
   1067 	_, _, e1 := RawSyscall(SYS_SETREGID, uintptr(rgid), uintptr(egid), 0)
   1068 	if e1 != 0 {
   1069 		err = errnoErr(e1)
   1070 	}
   1071 	return
   1072 }
   1073 
   1074 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1075 
   1076 func Setreuid(ruid int, euid int) (err error) {
   1077 	_, _, e1 := RawSyscall(SYS_SETREUID, uintptr(ruid), uintptr(euid), 0)
   1078 	if e1 != 0 {
   1079 		err = errnoErr(e1)
   1080 	}
   1081 	return
   1082 }
   1083 
   1084 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1085 
   1086 func Setrlimit(which int, lim *Rlimit) (err error) {
   1087 	_, _, e1 := RawSyscall(SYS_SETRLIMIT, uintptr(which), uintptr(unsafe.Pointer(lim)), 0)
   1088 	if e1 != 0 {
   1089 		err = errnoErr(e1)
   1090 	}
   1091 	return
   1092 }
   1093 
   1094 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1095 
   1096 func Setsid() (pid int, err error) {
   1097 	r0, _, e1 := RawSyscall(SYS_SETSID, 0, 0, 0)
   1098 	pid = int(r0)
   1099 	if e1 != 0 {
   1100 		err = errnoErr(e1)
   1101 	}
   1102 	return
   1103 }
   1104 
   1105 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1106 
   1107 func Settimeofday(tp *Timeval) (err error) {
   1108 	_, _, e1 := RawSyscall(SYS_SETTIMEOFDAY, uintptr(unsafe.Pointer(tp)), 0, 0)
   1109 	if e1 != 0 {
   1110 		err = errnoErr(e1)
   1111 	}
   1112 	return
   1113 }
   1114 
   1115 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1116 
   1117 func Setuid(uid int) (err error) {
   1118 	_, _, e1 := RawSyscall(SYS_SETUID, uintptr(uid), 0, 0)
   1119 	if e1 != 0 {
   1120 		err = errnoErr(e1)
   1121 	}
   1122 	return
   1123 }
   1124 
   1125 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1126 
   1127 func Stat(path string, stat *Stat_t) (err error) {
   1128 	var _p0 *byte
   1129 	_p0, err = BytePtrFromString(path)
   1130 	if err != nil {
   1131 		return
   1132 	}
   1133 	_, _, e1 := Syscall(SYS_STAT, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
   1134 	use(unsafe.Pointer(_p0))
   1135 	if e1 != 0 {
   1136 		err = errnoErr(e1)
   1137 	}
   1138 	return
   1139 }
   1140 
   1141 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1142 
   1143 func Statfs(path string, stat *Statfs_t) (err error) {
   1144 	var _p0 *byte
   1145 	_p0, err = BytePtrFromString(path)
   1146 	if err != nil {
   1147 		return
   1148 	}
   1149 	_, _, e1 := Syscall(SYS_STATFS, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
   1150 	use(unsafe.Pointer(_p0))
   1151 	if e1 != 0 {
   1152 		err = errnoErr(e1)
   1153 	}
   1154 	return
   1155 }
   1156 
   1157 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1158 
   1159 func Symlink(path string, link string) (err error) {
   1160 	var _p0 *byte
   1161 	_p0, err = BytePtrFromString(path)
   1162 	if err != nil {
   1163 		return
   1164 	}
   1165 	var _p1 *byte
   1166 	_p1, err = BytePtrFromString(link)
   1167 	if err != nil {
   1168 		return
   1169 	}
   1170 	_, _, e1 := Syscall(SYS_SYMLINK, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
   1171 	use(unsafe.Pointer(_p0))
   1172 	use(unsafe.Pointer(_p1))
   1173 	if e1 != 0 {
   1174 		err = errnoErr(e1)
   1175 	}
   1176 	return
   1177 }
   1178 
   1179 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1180 
   1181 func Sync() (err error) {
   1182 	_, _, e1 := Syscall(SYS_SYNC, 0, 0, 0)
   1183 	if e1 != 0 {
   1184 		err = errnoErr(e1)
   1185 	}
   1186 	return
   1187 }
   1188 
   1189 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1190 
   1191 func Truncate(path string, length int64) (err error) {
   1192 	var _p0 *byte
   1193 	_p0, err = BytePtrFromString(path)
   1194 	if err != nil {
   1195 		return
   1196 	}
   1197 	_, _, e1 := Syscall(SYS_TRUNCATE, uintptr(unsafe.Pointer(_p0)), uintptr(length), uintptr(length>>32))
   1198 	use(unsafe.Pointer(_p0))
   1199 	if e1 != 0 {
   1200 		err = errnoErr(e1)
   1201 	}
   1202 	return
   1203 }
   1204 
   1205 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1206 
   1207 func Umask(newmask int) (oldmask int) {
   1208 	r0, _, _ := Syscall(SYS_UMASK, uintptr(newmask), 0, 0)
   1209 	oldmask = int(r0)
   1210 	return
   1211 }
   1212 
   1213 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1214 
   1215 func Undelete(path string) (err error) {
   1216 	var _p0 *byte
   1217 	_p0, err = BytePtrFromString(path)
   1218 	if err != nil {
   1219 		return
   1220 	}
   1221 	_, _, e1 := Syscall(SYS_UNDELETE, uintptr(unsafe.Pointer(_p0)), 0, 0)
   1222 	use(unsafe.Pointer(_p0))
   1223 	if e1 != 0 {
   1224 		err = errnoErr(e1)
   1225 	}
   1226 	return
   1227 }
   1228 
   1229 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1230 
   1231 func Unlink(path string) (err error) {
   1232 	var _p0 *byte
   1233 	_p0, err = BytePtrFromString(path)
   1234 	if err != nil {
   1235 		return
   1236 	}
   1237 	_, _, e1 := Syscall(SYS_UNLINK, uintptr(unsafe.Pointer(_p0)), 0, 0)
   1238 	use(unsafe.Pointer(_p0))
   1239 	if e1 != 0 {
   1240 		err = errnoErr(e1)
   1241 	}
   1242 	return
   1243 }
   1244 
   1245 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1246 
   1247 func Unmount(path string, flags int) (err error) {
   1248 	var _p0 *byte
   1249 	_p0, err = BytePtrFromString(path)
   1250 	if err != nil {
   1251 		return
   1252 	}
   1253 	_, _, e1 := Syscall(SYS_UNMOUNT, uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
   1254 	use(unsafe.Pointer(_p0))
   1255 	if e1 != 0 {
   1256 		err = errnoErr(e1)
   1257 	}
   1258 	return
   1259 }
   1260 
   1261 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1262 
   1263 func write(fd int, p []byte) (n int, err error) {
   1264 	var _p0 unsafe.Pointer
   1265 	if len(p) > 0 {
   1266 		_p0 = unsafe.Pointer(&p[0])
   1267 	} else {
   1268 		_p0 = unsafe.Pointer(&_zero)
   1269 	}
   1270 	r0, _, e1 := Syscall(SYS_WRITE, uintptr(fd), uintptr(_p0), uintptr(len(p)))
   1271 	n = int(r0)
   1272 	if e1 != 0 {
   1273 		err = errnoErr(e1)
   1274 	}
   1275 	return
   1276 }
   1277 
   1278 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1279 
   1280 func mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error) {
   1281 	r0, _, e1 := Syscall9(SYS_MMAP, uintptr(addr), uintptr(length), uintptr(prot), uintptr(flag), uintptr(fd), uintptr(pos), uintptr(pos>>32), 0, 0)
   1282 	ret = uintptr(r0)
   1283 	if e1 != 0 {
   1284 		err = errnoErr(e1)
   1285 	}
   1286 	return
   1287 }
   1288 
   1289 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1290 
   1291 func munmap(addr uintptr, length uintptr) (err error) {
   1292 	_, _, e1 := Syscall(SYS_MUNMAP, uintptr(addr), uintptr(length), 0)
   1293 	if e1 != 0 {
   1294 		err = errnoErr(e1)
   1295 	}
   1296 	return
   1297 }
   1298 
   1299 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1300 
   1301 func readlen(fd int, buf *byte, nbuf int) (n int, err error) {
   1302 	r0, _, e1 := Syscall(SYS_READ, uintptr(fd), uintptr(unsafe.Pointer(buf)), uintptr(nbuf))
   1303 	n = int(r0)
   1304 	if e1 != 0 {
   1305 		err = errnoErr(e1)
   1306 	}
   1307 	return
   1308 }
   1309 
   1310 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1311 
   1312 func writelen(fd int, buf *byte, nbuf int) (n int, err error) {
   1313 	r0, _, e1 := Syscall(SYS_WRITE, uintptr(fd), uintptr(unsafe.Pointer(buf)), uintptr(nbuf))
   1314 	n = int(r0)
   1315 	if e1 != 0 {
   1316 		err = errnoErr(e1)
   1317 	}
   1318 	return
   1319 }
   1320 
   1321 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   1322 
   1323 func accept4(fd int, rsa *RawSockaddrAny, addrlen *_Socklen, flags int) (nfd int, err error) {
   1324 	r0, _, e1 := Syscall6(SYS_ACCEPT4, uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)), uintptr(flags), 0, 0)
   1325 	nfd = int(r0)
   1326 	if e1 != 0 {
   1327 		err = errnoErr(e1)
   1328 	}
   1329 	return
   1330 }
   1331