github.com/go-xe2/third@v1.0.3/golang.org/x/sys/unix/zsyscall_aix_ppc64.go (about) 1 // go run mksyscall_aix_ppc64.go -aix -tags aix,ppc64 syscall_aix.go syscall_aix_ppc64.go 2 // Code generated by the command above; see README.md. DO NOT EDIT. 3 4 // +build aix,ppc64 5 6 package unix 7 8 import ( 9 "unsafe" 10 ) 11 12 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 13 14 func utimes(path string, times *[2]Timeval) (err error) { 15 var _p0 *byte 16 _p0, err = BytePtrFromString(path) 17 if err != nil { 18 return 19 } 20 _, e1 := callutimes(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(times))) 21 if e1 != 0 { 22 err = errnoErr(e1) 23 } 24 return 25 } 26 27 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 28 29 func utimensat(dirfd int, path string, times *[2]Timespec, flag int) (err error) { 30 var _p0 *byte 31 _p0, err = BytePtrFromString(path) 32 if err != nil { 33 return 34 } 35 _, e1 := callutimensat(dirfd, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(times)), flag) 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 getcwd(buf []byte) (err error) { 45 var _p0 *byte 46 if len(buf) > 0 { 47 _p0 = &buf[0] 48 } 49 _, e1 := callgetcwd(uintptr(unsafe.Pointer(_p0)), len(buf)) 50 if e1 != 0 { 51 err = errnoErr(e1) 52 } 53 return 54 } 55 56 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 57 58 func accept(s int, rsa *RawSockaddrAny, addrlen *_Socklen) (fd int, err error) { 59 r0, e1 := callaccept(s, uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen))) 60 fd = int(r0) 61 if e1 != 0 { 62 err = errnoErr(e1) 63 } 64 return 65 } 66 67 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 68 69 func getdirent(fd int, buf []byte) (n int, err error) { 70 var _p0 *byte 71 if len(buf) > 0 { 72 _p0 = &buf[0] 73 } 74 r0, e1 := callgetdirent(fd, uintptr(unsafe.Pointer(_p0)), len(buf)) 75 n = int(r0) 76 if e1 != 0 { 77 err = errnoErr(e1) 78 } 79 return 80 } 81 82 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 83 84 func wait4(pid Pid_t, status *_C_int, options int, rusage *Rusage) (wpid Pid_t, err error) { 85 r0, e1 := callwait4(int(pid), uintptr(unsafe.Pointer(status)), options, uintptr(unsafe.Pointer(rusage))) 86 wpid = Pid_t(r0) 87 if e1 != 0 { 88 err = errnoErr(e1) 89 } 90 return 91 } 92 93 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 94 95 func ioctl(fd int, req uint, arg uintptr) (err error) { 96 _, e1 := callioctl(fd, int(req), arg) 97 if e1 != 0 { 98 err = errnoErr(e1) 99 } 100 return 101 } 102 103 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 104 105 func FcntlInt(fd uintptr, cmd int, arg int) (r int, err error) { 106 r0, e1 := callfcntl(fd, cmd, uintptr(arg)) 107 r = int(r0) 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 FcntlFlock(fd uintptr, cmd int, lk *Flock_t) (err error) { 117 _, e1 := callfcntl(fd, cmd, uintptr(unsafe.Pointer(lk))) 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 fcntl(fd int, cmd int, arg int) (val int, err error) { 127 r0, e1 := callfcntl(uintptr(fd), cmd, uintptr(arg)) 128 val = int(r0) 129 if e1 != 0 { 130 err = errnoErr(e1) 131 } 132 return 133 } 134 135 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 136 137 func Acct(path string) (err error) { 138 var _p0 *byte 139 _p0, err = BytePtrFromString(path) 140 if err != nil { 141 return 142 } 143 _, e1 := callacct(uintptr(unsafe.Pointer(_p0))) 144 if e1 != 0 { 145 err = errnoErr(e1) 146 } 147 return 148 } 149 150 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 151 152 func Chdir(path string) (err error) { 153 var _p0 *byte 154 _p0, err = BytePtrFromString(path) 155 if err != nil { 156 return 157 } 158 _, e1 := callchdir(uintptr(unsafe.Pointer(_p0))) 159 if e1 != 0 { 160 err = errnoErr(e1) 161 } 162 return 163 } 164 165 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 166 167 func Chroot(path string) (err error) { 168 var _p0 *byte 169 _p0, err = BytePtrFromString(path) 170 if err != nil { 171 return 172 } 173 _, e1 := callchroot(uintptr(unsafe.Pointer(_p0))) 174 if e1 != 0 { 175 err = errnoErr(e1) 176 } 177 return 178 } 179 180 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 181 182 func Close(fd int) (err error) { 183 _, e1 := callclose(fd) 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 Dup(oldfd int) (fd int, err error) { 193 r0, e1 := calldup(oldfd) 194 fd = 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 Exit(code int) { 204 callexit(code) 205 return 206 } 207 208 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 209 210 func Faccessat(dirfd int, path string, mode uint32, flags int) (err error) { 211 var _p0 *byte 212 _p0, err = BytePtrFromString(path) 213 if err != nil { 214 return 215 } 216 _, e1 := callfaccessat(dirfd, uintptr(unsafe.Pointer(_p0)), mode, flags) 217 if e1 != 0 { 218 err = errnoErr(e1) 219 } 220 return 221 } 222 223 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 224 225 func Fchdir(fd int) (err error) { 226 _, e1 := callfchdir(fd) 227 if e1 != 0 { 228 err = errnoErr(e1) 229 } 230 return 231 } 232 233 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 234 235 func Fchmod(fd int, mode uint32) (err error) { 236 _, e1 := callfchmod(fd, mode) 237 if e1 != 0 { 238 err = errnoErr(e1) 239 } 240 return 241 } 242 243 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 244 245 func Fchmodat(dirfd int, path string, mode uint32, flags int) (err error) { 246 var _p0 *byte 247 _p0, err = BytePtrFromString(path) 248 if err != nil { 249 return 250 } 251 _, e1 := callfchmodat(dirfd, uintptr(unsafe.Pointer(_p0)), mode, flags) 252 if e1 != 0 { 253 err = errnoErr(e1) 254 } 255 return 256 } 257 258 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 259 260 func Fchownat(dirfd int, path string, uid int, gid int, flags int) (err error) { 261 var _p0 *byte 262 _p0, err = BytePtrFromString(path) 263 if err != nil { 264 return 265 } 266 _, e1 := callfchownat(dirfd, uintptr(unsafe.Pointer(_p0)), uid, gid, flags) 267 if e1 != 0 { 268 err = errnoErr(e1) 269 } 270 return 271 } 272 273 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 274 275 func Fdatasync(fd int) (err error) { 276 _, e1 := callfdatasync(fd) 277 if e1 != 0 { 278 err = errnoErr(e1) 279 } 280 return 281 } 282 283 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 284 285 func Fsync(fd int) (err error) { 286 _, e1 := callfsync(fd) 287 if e1 != 0 { 288 err = errnoErr(e1) 289 } 290 return 291 } 292 293 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 294 295 func Getpgid(pid int) (pgid int, err error) { 296 r0, e1 := callgetpgid(pid) 297 pgid = int(r0) 298 if e1 != 0 { 299 err = errnoErr(e1) 300 } 301 return 302 } 303 304 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 305 306 func Getpgrp() (pid int) { 307 r0, _ := callgetpgrp() 308 pid = int(r0) 309 return 310 } 311 312 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 313 314 func Getpid() (pid int) { 315 r0, _ := callgetpid() 316 pid = int(r0) 317 return 318 } 319 320 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 321 322 func Getppid() (ppid int) { 323 r0, _ := callgetppid() 324 ppid = int(r0) 325 return 326 } 327 328 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 329 330 func Getpriority(which int, who int) (prio int, err error) { 331 r0, e1 := callgetpriority(which, who) 332 prio = int(r0) 333 if e1 != 0 { 334 err = errnoErr(e1) 335 } 336 return 337 } 338 339 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 340 341 func Getrusage(who int, rusage *Rusage) (err error) { 342 _, e1 := callgetrusage(who, uintptr(unsafe.Pointer(rusage))) 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 Getsid(pid int) (sid int, err error) { 352 r0, e1 := callgetsid(pid) 353 sid = 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 Kill(pid int, sig Signal) (err error) { 363 _, e1 := callkill(pid, int(sig)) 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 Klogctl(typ int, buf []byte) (n int, err error) { 373 var _p0 *byte 374 if len(buf) > 0 { 375 _p0 = &buf[0] 376 } 377 r0, e1 := callsyslog(typ, uintptr(unsafe.Pointer(_p0)), len(buf)) 378 n = int(r0) 379 if e1 != 0 { 380 err = errnoErr(e1) 381 } 382 return 383 } 384 385 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 386 387 func Mkdir(dirfd int, path string, mode uint32) (err error) { 388 var _p0 *byte 389 _p0, err = BytePtrFromString(path) 390 if err != nil { 391 return 392 } 393 _, e1 := callmkdir(dirfd, uintptr(unsafe.Pointer(_p0)), mode) 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 Mkdirat(dirfd int, path string, mode uint32) (err error) { 403 var _p0 *byte 404 _p0, err = BytePtrFromString(path) 405 if err != nil { 406 return 407 } 408 _, e1 := callmkdirat(dirfd, uintptr(unsafe.Pointer(_p0)), mode) 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 Mkfifo(path string, mode uint32) (err error) { 418 var _p0 *byte 419 _p0, err = BytePtrFromString(path) 420 if err != nil { 421 return 422 } 423 _, e1 := callmkfifo(uintptr(unsafe.Pointer(_p0)), mode) 424 if e1 != 0 { 425 err = errnoErr(e1) 426 } 427 return 428 } 429 430 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 431 432 func Mknod(path string, mode uint32, dev int) (err error) { 433 var _p0 *byte 434 _p0, err = BytePtrFromString(path) 435 if err != nil { 436 return 437 } 438 _, e1 := callmknod(uintptr(unsafe.Pointer(_p0)), mode, dev) 439 if e1 != 0 { 440 err = errnoErr(e1) 441 } 442 return 443 } 444 445 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 446 447 func Mknodat(dirfd int, path string, mode uint32, dev int) (err error) { 448 var _p0 *byte 449 _p0, err = BytePtrFromString(path) 450 if err != nil { 451 return 452 } 453 _, e1 := callmknodat(dirfd, uintptr(unsafe.Pointer(_p0)), mode, dev) 454 if e1 != 0 { 455 err = errnoErr(e1) 456 } 457 return 458 } 459 460 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 461 462 func Nanosleep(time *Timespec, leftover *Timespec) (err error) { 463 _, e1 := callnanosleep(uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover))) 464 if e1 != 0 { 465 err = errnoErr(e1) 466 } 467 return 468 } 469 470 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 471 472 func Open(path string, mode int, perm uint32) (fd int, err error) { 473 var _p0 *byte 474 _p0, err = BytePtrFromString(path) 475 if err != nil { 476 return 477 } 478 r0, e1 := callopen64(uintptr(unsafe.Pointer(_p0)), mode, perm) 479 fd = int(r0) 480 if e1 != 0 { 481 err = errnoErr(e1) 482 } 483 return 484 } 485 486 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 487 488 func Openat(dirfd int, path string, flags int, mode uint32) (fd int, err error) { 489 var _p0 *byte 490 _p0, err = BytePtrFromString(path) 491 if err != nil { 492 return 493 } 494 r0, e1 := callopenat(dirfd, uintptr(unsafe.Pointer(_p0)), flags, mode) 495 fd = int(r0) 496 if e1 != 0 { 497 err = errnoErr(e1) 498 } 499 return 500 } 501 502 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 503 504 func read(fd int, p []byte) (n int, err error) { 505 var _p0 *byte 506 if len(p) > 0 { 507 _p0 = &p[0] 508 } 509 r0, e1 := callread(fd, uintptr(unsafe.Pointer(_p0)), len(p)) 510 n = int(r0) 511 if e1 != 0 { 512 err = errnoErr(e1) 513 } 514 return 515 } 516 517 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 518 519 func Readlink(path string, buf []byte) (n int, err error) { 520 var _p0 *byte 521 _p0, err = BytePtrFromString(path) 522 if err != nil { 523 return 524 } 525 var _p1 *byte 526 if len(buf) > 0 { 527 _p1 = &buf[0] 528 } 529 r0, e1 := callreadlink(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), len(buf)) 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 Renameat(olddirfd int, oldpath string, newdirfd int, newpath string) (err error) { 540 var _p0 *byte 541 _p0, err = BytePtrFromString(oldpath) 542 if err != nil { 543 return 544 } 545 var _p1 *byte 546 _p1, err = BytePtrFromString(newpath) 547 if err != nil { 548 return 549 } 550 _, e1 := callrenameat(olddirfd, uintptr(unsafe.Pointer(_p0)), newdirfd, uintptr(unsafe.Pointer(_p1))) 551 if e1 != 0 { 552 err = errnoErr(e1) 553 } 554 return 555 } 556 557 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 558 559 func Setdomainname(p []byte) (err error) { 560 var _p0 *byte 561 if len(p) > 0 { 562 _p0 = &p[0] 563 } 564 _, e1 := callsetdomainname(uintptr(unsafe.Pointer(_p0)), len(p)) 565 if e1 != 0 { 566 err = errnoErr(e1) 567 } 568 return 569 } 570 571 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 572 573 func Sethostname(p []byte) (err error) { 574 var _p0 *byte 575 if len(p) > 0 { 576 _p0 = &p[0] 577 } 578 _, e1 := callsethostname(uintptr(unsafe.Pointer(_p0)), len(p)) 579 if e1 != 0 { 580 err = errnoErr(e1) 581 } 582 return 583 } 584 585 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 586 587 func Setpgid(pid int, pgid int) (err error) { 588 _, e1 := callsetpgid(pid, pgid) 589 if e1 != 0 { 590 err = errnoErr(e1) 591 } 592 return 593 } 594 595 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 596 597 func Setsid() (pid int, err error) { 598 r0, e1 := callsetsid() 599 pid = int(r0) 600 if e1 != 0 { 601 err = errnoErr(e1) 602 } 603 return 604 } 605 606 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 607 608 func Settimeofday(tv *Timeval) (err error) { 609 _, e1 := callsettimeofday(uintptr(unsafe.Pointer(tv))) 610 if e1 != 0 { 611 err = errnoErr(e1) 612 } 613 return 614 } 615 616 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 617 618 func Setuid(uid int) (err error) { 619 _, e1 := callsetuid(uid) 620 if e1 != 0 { 621 err = errnoErr(e1) 622 } 623 return 624 } 625 626 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 627 628 func Setgid(uid int) (err error) { 629 _, e1 := callsetgid(uid) 630 if e1 != 0 { 631 err = errnoErr(e1) 632 } 633 return 634 } 635 636 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 637 638 func Setpriority(which int, who int, prio int) (err error) { 639 _, e1 := callsetpriority(which, who, prio) 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 Statx(dirfd int, path string, flags int, mask int, stat *Statx_t) (err error) { 649 var _p0 *byte 650 _p0, err = BytePtrFromString(path) 651 if err != nil { 652 return 653 } 654 _, e1 := callstatx(dirfd, uintptr(unsafe.Pointer(_p0)), flags, mask, uintptr(unsafe.Pointer(stat))) 655 if e1 != 0 { 656 err = errnoErr(e1) 657 } 658 return 659 } 660 661 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 662 663 func Sync() { 664 callsync() 665 return 666 } 667 668 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 669 670 func Times(tms *Tms) (ticks uintptr, err error) { 671 r0, e1 := calltimes(uintptr(unsafe.Pointer(tms))) 672 ticks = uintptr(r0) 673 if e1 != 0 { 674 err = errnoErr(e1) 675 } 676 return 677 } 678 679 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 680 681 func Umask(mask int) (oldmask int) { 682 r0, _ := callumask(mask) 683 oldmask = int(r0) 684 return 685 } 686 687 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 688 689 func Uname(buf *Utsname) (err error) { 690 _, e1 := calluname(uintptr(unsafe.Pointer(buf))) 691 if e1 != 0 { 692 err = errnoErr(e1) 693 } 694 return 695 } 696 697 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 698 699 func Unlink(path string) (err error) { 700 var _p0 *byte 701 _p0, err = BytePtrFromString(path) 702 if err != nil { 703 return 704 } 705 _, e1 := callunlink(uintptr(unsafe.Pointer(_p0))) 706 if e1 != 0 { 707 err = errnoErr(e1) 708 } 709 return 710 } 711 712 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 713 714 func Unlinkat(dirfd int, path string, flags int) (err error) { 715 var _p0 *byte 716 _p0, err = BytePtrFromString(path) 717 if err != nil { 718 return 719 } 720 _, e1 := callunlinkat(dirfd, uintptr(unsafe.Pointer(_p0)), flags) 721 if e1 != 0 { 722 err = errnoErr(e1) 723 } 724 return 725 } 726 727 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 728 729 func Ustat(dev int, ubuf *Ustat_t) (err error) { 730 _, e1 := callustat(dev, uintptr(unsafe.Pointer(ubuf))) 731 if e1 != 0 { 732 err = errnoErr(e1) 733 } 734 return 735 } 736 737 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 738 739 func write(fd int, p []byte) (n int, err error) { 740 var _p0 *byte 741 if len(p) > 0 { 742 _p0 = &p[0] 743 } 744 r0, e1 := callwrite(fd, uintptr(unsafe.Pointer(_p0)), len(p)) 745 n = int(r0) 746 if e1 != 0 { 747 err = errnoErr(e1) 748 } 749 return 750 } 751 752 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 753 754 func readlen(fd int, p *byte, np int) (n int, err error) { 755 r0, e1 := callread(fd, uintptr(unsafe.Pointer(p)), np) 756 n = int(r0) 757 if e1 != 0 { 758 err = errnoErr(e1) 759 } 760 return 761 } 762 763 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 764 765 func writelen(fd int, p *byte, np int) (n int, err error) { 766 r0, e1 := callwrite(fd, uintptr(unsafe.Pointer(p)), np) 767 n = int(r0) 768 if e1 != 0 { 769 err = errnoErr(e1) 770 } 771 return 772 } 773 774 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 775 776 func Dup2(oldfd int, newfd int) (err error) { 777 _, e1 := calldup2(oldfd, newfd) 778 if e1 != 0 { 779 err = errnoErr(e1) 780 } 781 return 782 } 783 784 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 785 786 func Fadvise(fd int, offset int64, length int64, advice int) (err error) { 787 _, e1 := callposix_fadvise64(fd, offset, length, advice) 788 if e1 != 0 { 789 err = errnoErr(e1) 790 } 791 return 792 } 793 794 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 795 796 func Fchown(fd int, uid int, gid int) (err error) { 797 _, e1 := callfchown(fd, uid, gid) 798 if e1 != 0 { 799 err = errnoErr(e1) 800 } 801 return 802 } 803 804 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 805 806 func Fstat(fd int, stat *Stat_t) (err error) { 807 _, e1 := callfstat(fd, uintptr(unsafe.Pointer(stat))) 808 if e1 != 0 { 809 err = errnoErr(e1) 810 } 811 return 812 } 813 814 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 815 816 func Fstatat(dirfd int, path string, stat *Stat_t, flags int) (err error) { 817 var _p0 *byte 818 _p0, err = BytePtrFromString(path) 819 if err != nil { 820 return 821 } 822 _, e1 := callfstatat(dirfd, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), flags) 823 if e1 != 0 { 824 err = errnoErr(e1) 825 } 826 return 827 } 828 829 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 830 831 func Fstatfs(fd int, buf *Statfs_t) (err error) { 832 _, e1 := callfstatfs(fd, uintptr(unsafe.Pointer(buf))) 833 if e1 != 0 { 834 err = errnoErr(e1) 835 } 836 return 837 } 838 839 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 840 841 func Ftruncate(fd int, length int64) (err error) { 842 _, e1 := callftruncate(fd, length) 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 Getegid() (egid int) { 852 r0, _ := callgetegid() 853 egid = int(r0) 854 return 855 } 856 857 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 858 859 func Geteuid() (euid int) { 860 r0, _ := callgeteuid() 861 euid = int(r0) 862 return 863 } 864 865 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 866 867 func Getgid() (gid int) { 868 r0, _ := callgetgid() 869 gid = int(r0) 870 return 871 } 872 873 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 874 875 func Getuid() (uid int) { 876 r0, _ := callgetuid() 877 uid = int(r0) 878 return 879 } 880 881 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 882 883 func Lchown(path string, uid int, gid int) (err error) { 884 var _p0 *byte 885 _p0, err = BytePtrFromString(path) 886 if err != nil { 887 return 888 } 889 _, e1 := calllchown(uintptr(unsafe.Pointer(_p0)), uid, gid) 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 Listen(s int, n int) (err error) { 899 _, e1 := calllisten(s, n) 900 if e1 != 0 { 901 err = errnoErr(e1) 902 } 903 return 904 } 905 906 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 907 908 func Lstat(path string, stat *Stat_t) (err error) { 909 var _p0 *byte 910 _p0, err = BytePtrFromString(path) 911 if err != nil { 912 return 913 } 914 _, e1 := calllstat(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat))) 915 if e1 != 0 { 916 err = errnoErr(e1) 917 } 918 return 919 } 920 921 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 922 923 func Pause() (err error) { 924 _, e1 := callpause() 925 if e1 != 0 { 926 err = errnoErr(e1) 927 } 928 return 929 } 930 931 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 932 933 func Pread(fd int, p []byte, offset int64) (n int, err error) { 934 var _p0 *byte 935 if len(p) > 0 { 936 _p0 = &p[0] 937 } 938 r0, e1 := callpread64(fd, uintptr(unsafe.Pointer(_p0)), len(p), offset) 939 n = int(r0) 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 Pwrite(fd int, p []byte, offset int64) (n int, err error) { 949 var _p0 *byte 950 if len(p) > 0 { 951 _p0 = &p[0] 952 } 953 r0, e1 := callpwrite64(fd, uintptr(unsafe.Pointer(_p0)), len(p), offset) 954 n = int(r0) 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 Pselect(nfd int, r *FdSet, w *FdSet, e *FdSet, timeout *Timespec, sigmask *Sigset_t) (n int, err error) { 964 r0, e1 := callpselect(nfd, uintptr(unsafe.Pointer(r)), uintptr(unsafe.Pointer(w)), uintptr(unsafe.Pointer(e)), uintptr(unsafe.Pointer(timeout)), uintptr(unsafe.Pointer(sigmask))) 965 n = int(r0) 966 if e1 != 0 { 967 err = errnoErr(e1) 968 } 969 return 970 } 971 972 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 973 974 func Setregid(rgid int, egid int) (err error) { 975 _, e1 := callsetregid(rgid, egid) 976 if e1 != 0 { 977 err = errnoErr(e1) 978 } 979 return 980 } 981 982 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 983 984 func Setreuid(ruid int, euid int) (err error) { 985 _, e1 := callsetreuid(ruid, euid) 986 if e1 != 0 { 987 err = errnoErr(e1) 988 } 989 return 990 } 991 992 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 993 994 func Shutdown(fd int, how int) (err error) { 995 _, e1 := callshutdown(fd, how) 996 if e1 != 0 { 997 err = errnoErr(e1) 998 } 999 return 1000 } 1001 1002 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1003 1004 func Splice(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int64, err error) { 1005 r0, e1 := callsplice(rfd, uintptr(unsafe.Pointer(roff)), wfd, uintptr(unsafe.Pointer(woff)), len, flags) 1006 n = int64(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 Stat(path string, stat *Stat_t) (err error) { 1016 var _p0 *byte 1017 _p0, err = BytePtrFromString(path) 1018 if err != nil { 1019 return 1020 } 1021 _, e1 := callstat(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat))) 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 Statfs(path string, buf *Statfs_t) (err error) { 1031 var _p0 *byte 1032 _p0, err = BytePtrFromString(path) 1033 if err != nil { 1034 return 1035 } 1036 _, e1 := callstatfs(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(buf))) 1037 if e1 != 0 { 1038 err = errnoErr(e1) 1039 } 1040 return 1041 } 1042 1043 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1044 1045 func Truncate(path string, length int64) (err error) { 1046 var _p0 *byte 1047 _p0, err = BytePtrFromString(path) 1048 if err != nil { 1049 return 1050 } 1051 _, e1 := calltruncate(uintptr(unsafe.Pointer(_p0)), length) 1052 if e1 != 0 { 1053 err = errnoErr(e1) 1054 } 1055 return 1056 } 1057 1058 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1059 1060 func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) { 1061 _, e1 := callbind(s, uintptr(addr), uintptr(addrlen)) 1062 if e1 != 0 { 1063 err = errnoErr(e1) 1064 } 1065 return 1066 } 1067 1068 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1069 1070 func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) { 1071 _, e1 := callconnect(s, uintptr(addr), uintptr(addrlen)) 1072 if e1 != 0 { 1073 err = errnoErr(e1) 1074 } 1075 return 1076 } 1077 1078 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1079 1080 func getgroups(n int, list *_Gid_t) (nn int, err error) { 1081 r0, e1 := callgetgroups(n, uintptr(unsafe.Pointer(list))) 1082 nn = int(r0) 1083 if e1 != 0 { 1084 err = errnoErr(e1) 1085 } 1086 return 1087 } 1088 1089 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1090 1091 func setgroups(n int, list *_Gid_t) (err error) { 1092 _, e1 := callsetgroups(n, uintptr(unsafe.Pointer(list))) 1093 if e1 != 0 { 1094 err = errnoErr(e1) 1095 } 1096 return 1097 } 1098 1099 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1100 1101 func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) { 1102 _, e1 := callgetsockopt(s, level, name, uintptr(val), uintptr(unsafe.Pointer(vallen))) 1103 if e1 != 0 { 1104 err = errnoErr(e1) 1105 } 1106 return 1107 } 1108 1109 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1110 1111 func setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) { 1112 _, e1 := callsetsockopt(s, level, name, uintptr(val), vallen) 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 socket(domain int, typ int, proto int) (fd int, err error) { 1122 r0, e1 := callsocket(domain, typ, proto) 1123 fd = int(r0) 1124 if e1 != 0 { 1125 err = errnoErr(e1) 1126 } 1127 return 1128 } 1129 1130 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1131 1132 func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) { 1133 _, e1 := callsocketpair(domain, typ, proto, uintptr(unsafe.Pointer(fd))) 1134 if e1 != 0 { 1135 err = errnoErr(e1) 1136 } 1137 return 1138 } 1139 1140 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1141 1142 func getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) { 1143 _, e1 := callgetpeername(fd, uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen))) 1144 if e1 != 0 { 1145 err = errnoErr(e1) 1146 } 1147 return 1148 } 1149 1150 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1151 1152 func getsockname(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) { 1153 _, e1 := callgetsockname(fd, uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen))) 1154 if e1 != 0 { 1155 err = errnoErr(e1) 1156 } 1157 return 1158 } 1159 1160 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1161 1162 func recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) { 1163 var _p0 *byte 1164 if len(p) > 0 { 1165 _p0 = &p[0] 1166 } 1167 r0, e1 := callrecvfrom(fd, uintptr(unsafe.Pointer(_p0)), len(p), flags, uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(fromlen))) 1168 n = int(r0) 1169 if e1 != 0 { 1170 err = errnoErr(e1) 1171 } 1172 return 1173 } 1174 1175 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1176 1177 func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) { 1178 var _p0 *byte 1179 if len(buf) > 0 { 1180 _p0 = &buf[0] 1181 } 1182 _, e1 := callsendto(s, uintptr(unsafe.Pointer(_p0)), len(buf), flags, uintptr(to), uintptr(addrlen)) 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 recvmsg(s int, msg *Msghdr, flags int) (n int, err error) { 1192 r0, e1 := callrecvmsg(s, uintptr(unsafe.Pointer(msg)), flags) 1193 n = int(r0) 1194 if e1 != 0 { 1195 err = errnoErr(e1) 1196 } 1197 return 1198 } 1199 1200 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1201 1202 func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) { 1203 r0, e1 := callsendmsg(s, uintptr(unsafe.Pointer(msg)), flags) 1204 n = int(r0) 1205 if e1 != 0 { 1206 err = errnoErr(e1) 1207 } 1208 return 1209 } 1210 1211 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1212 1213 func munmap(addr uintptr, length uintptr) (err error) { 1214 _, e1 := callmunmap(addr, length) 1215 if e1 != 0 { 1216 err = errnoErr(e1) 1217 } 1218 return 1219 } 1220 1221 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1222 1223 func Madvise(b []byte, advice int) (err error) { 1224 var _p0 *byte 1225 if len(b) > 0 { 1226 _p0 = &b[0] 1227 } 1228 _, e1 := callmadvise(uintptr(unsafe.Pointer(_p0)), len(b), advice) 1229 if e1 != 0 { 1230 err = errnoErr(e1) 1231 } 1232 return 1233 } 1234 1235 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1236 1237 func Mprotect(b []byte, prot int) (err error) { 1238 var _p0 *byte 1239 if len(b) > 0 { 1240 _p0 = &b[0] 1241 } 1242 _, e1 := callmprotect(uintptr(unsafe.Pointer(_p0)), len(b), prot) 1243 if e1 != 0 { 1244 err = errnoErr(e1) 1245 } 1246 return 1247 } 1248 1249 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1250 1251 func Mlock(b []byte) (err error) { 1252 var _p0 *byte 1253 if len(b) > 0 { 1254 _p0 = &b[0] 1255 } 1256 _, e1 := callmlock(uintptr(unsafe.Pointer(_p0)), len(b)) 1257 if e1 != 0 { 1258 err = errnoErr(e1) 1259 } 1260 return 1261 } 1262 1263 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1264 1265 func Mlockall(flags int) (err error) { 1266 _, e1 := callmlockall(flags) 1267 if e1 != 0 { 1268 err = errnoErr(e1) 1269 } 1270 return 1271 } 1272 1273 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1274 1275 func Msync(b []byte, flags int) (err error) { 1276 var _p0 *byte 1277 if len(b) > 0 { 1278 _p0 = &b[0] 1279 } 1280 _, e1 := callmsync(uintptr(unsafe.Pointer(_p0)), len(b), flags) 1281 if e1 != 0 { 1282 err = errnoErr(e1) 1283 } 1284 return 1285 } 1286 1287 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1288 1289 func Munlock(b []byte) (err error) { 1290 var _p0 *byte 1291 if len(b) > 0 { 1292 _p0 = &b[0] 1293 } 1294 _, e1 := callmunlock(uintptr(unsafe.Pointer(_p0)), len(b)) 1295 if e1 != 0 { 1296 err = errnoErr(e1) 1297 } 1298 return 1299 } 1300 1301 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1302 1303 func Munlockall() (err error) { 1304 _, e1 := callmunlockall() 1305 if e1 != 0 { 1306 err = errnoErr(e1) 1307 } 1308 return 1309 } 1310 1311 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1312 1313 func pipe(p *[2]_C_int) (err error) { 1314 _, e1 := callpipe(uintptr(unsafe.Pointer(p))) 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 poll(fds *PollFd, nfds int, timeout int) (n int, err error) { 1324 r0, e1 := callpoll(uintptr(unsafe.Pointer(fds)), nfds, timeout) 1325 n = int(r0) 1326 if e1 != 0 { 1327 err = errnoErr(e1) 1328 } 1329 return 1330 } 1331 1332 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1333 1334 func gettimeofday(tv *Timeval, tzp *Timezone) (err error) { 1335 _, e1 := callgettimeofday(uintptr(unsafe.Pointer(tv)), uintptr(unsafe.Pointer(tzp))) 1336 if e1 != 0 { 1337 err = errnoErr(e1) 1338 } 1339 return 1340 } 1341 1342 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1343 1344 func Time(t *Time_t) (tt Time_t, err error) { 1345 r0, e1 := calltime(uintptr(unsafe.Pointer(t))) 1346 tt = Time_t(r0) 1347 if e1 != 0 { 1348 err = errnoErr(e1) 1349 } 1350 return 1351 } 1352 1353 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1354 1355 func Utime(path string, buf *Utimbuf) (err error) { 1356 var _p0 *byte 1357 _p0, err = BytePtrFromString(path) 1358 if err != nil { 1359 return 1360 } 1361 _, e1 := callutime(uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(buf))) 1362 if e1 != 0 { 1363 err = errnoErr(e1) 1364 } 1365 return 1366 } 1367 1368 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1369 1370 func Getrlimit(resource int, rlim *Rlimit) (err error) { 1371 _, e1 := callgetrlimit(resource, uintptr(unsafe.Pointer(rlim))) 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 Setrlimit(resource int, rlim *Rlimit) (err error) { 1381 _, e1 := callsetrlimit(resource, uintptr(unsafe.Pointer(rlim))) 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 Seek(fd int, offset int64, whence int) (off int64, err error) { 1391 r0, e1 := calllseek(fd, offset, whence) 1392 off = int64(r0) 1393 if e1 != 0 { 1394 err = errnoErr(e1) 1395 } 1396 return 1397 } 1398 1399 // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT 1400 1401 func mmap(addr uintptr, length uintptr, prot int, flags int, fd int, offset int64) (xaddr uintptr, err error) { 1402 r0, e1 := callmmap64(addr, length, prot, flags, fd, offset) 1403 xaddr = uintptr(r0) 1404 if e1 != 0 { 1405 err = errnoErr(e1) 1406 } 1407 return 1408 }