Move away from the __ARCH_WANT_SYSCALL_NO_AT system calls.
Modern architectures only get the *at(2) system calls. For example,
aarch64 doesn't have open(2), and expects userspace to use openat(2)
instead.
Change-Id: I87b4ed79790cb8a80844f5544ac1a13fda26c7b5
diff --git a/libc/arch-mips/syscalls.mk b/libc/arch-mips/syscalls.mk
index fc96222..621dbac 100644
--- a/libc/arch-mips/syscalls.mk
+++ b/libc/arch-mips/syscalls.mk
@@ -37,14 +37,11 @@
syscall_src += arch-mips/syscalls/_flush_cache.S
syscall_src += arch-mips/syscalls/_waitpid.S
syscall_src += arch-mips/syscalls/accept.S
-syscall_src += arch-mips/syscalls/access.S
syscall_src += arch-mips/syscalls/acct.S
syscall_src += arch-mips/syscalls/bind.S
syscall_src += arch-mips/syscalls/capget.S
syscall_src += arch-mips/syscalls/capset.S
syscall_src += arch-mips/syscalls/chdir.S
-syscall_src += arch-mips/syscalls/chmod.S
-syscall_src += arch-mips/syscalls/chown.S
syscall_src += arch-mips/syscalls/chroot.S
syscall_src += arch-mips/syscalls/clock_getres.S
syscall_src += arch-mips/syscalls/clock_gettime.S
@@ -107,21 +104,18 @@
syscall_src += arch-mips/syscalls/ioprio_set.S
syscall_src += arch-mips/syscalls/kill.S
syscall_src += arch-mips/syscalls/klogctl.S
-syscall_src += arch-mips/syscalls/lchown.S
syscall_src += arch-mips/syscalls/lgetxattr.S
-syscall_src += arch-mips/syscalls/link.S
+syscall_src += arch-mips/syscalls/linkat.S
syscall_src += arch-mips/syscalls/listen.S
syscall_src += arch-mips/syscalls/listxattr.S
syscall_src += arch-mips/syscalls/llistxattr.S
syscall_src += arch-mips/syscalls/lremovexattr.S
syscall_src += arch-mips/syscalls/lseek.S
syscall_src += arch-mips/syscalls/lsetxattr.S
-syscall_src += arch-mips/syscalls/lstat.S
syscall_src += arch-mips/syscalls/madvise.S
syscall_src += arch-mips/syscalls/mincore.S
-syscall_src += arch-mips/syscalls/mkdir.S
syscall_src += arch-mips/syscalls/mkdirat.S
-syscall_src += arch-mips/syscalls/mknod.S
+syscall_src += arch-mips/syscalls/mknodat.S
syscall_src += arch-mips/syscalls/mlock.S
syscall_src += arch-mips/syscalls/mlockall.S
syscall_src += arch-mips/syscalls/mount.S
@@ -142,14 +136,12 @@
syscall_src += arch-mips/syscalls/pwrite64.S
syscall_src += arch-mips/syscalls/read.S
syscall_src += arch-mips/syscalls/readahead.S
-syscall_src += arch-mips/syscalls/readlink.S
+syscall_src += arch-mips/syscalls/readlinkat.S
syscall_src += arch-mips/syscalls/readv.S
syscall_src += arch-mips/syscalls/recvfrom.S
syscall_src += arch-mips/syscalls/recvmsg.S
syscall_src += arch-mips/syscalls/removexattr.S
-syscall_src += arch-mips/syscalls/rename.S
syscall_src += arch-mips/syscalls/renameat.S
-syscall_src += arch-mips/syscalls/rmdir.S
syscall_src += arch-mips/syscalls/sched_get_priority_max.S
syscall_src += arch-mips/syscalls/sched_get_priority_min.S
syscall_src += arch-mips/syscalls/sched_getparam.S
@@ -184,10 +176,9 @@
syscall_src += arch-mips/syscalls/signalfd4.S
syscall_src += arch-mips/syscalls/socket.S
syscall_src += arch-mips/syscalls/socketpair.S
-syscall_src += arch-mips/syscalls/stat.S
syscall_src += arch-mips/syscalls/swapoff.S
syscall_src += arch-mips/syscalls/swapon.S
-syscall_src += arch-mips/syscalls/symlink.S
+syscall_src += arch-mips/syscalls/symlinkat.S
syscall_src += arch-mips/syscalls/sync.S
syscall_src += arch-mips/syscalls/syscall.S
syscall_src += arch-mips/syscalls/sysinfo.S
@@ -202,11 +193,9 @@
syscall_src += arch-mips/syscalls/umask.S
syscall_src += arch-mips/syscalls/umount2.S
syscall_src += arch-mips/syscalls/uname.S
-syscall_src += arch-mips/syscalls/unlink.S
syscall_src += arch-mips/syscalls/unlinkat.S
syscall_src += arch-mips/syscalls/unshare.S
syscall_src += arch-mips/syscalls/utimensat.S
-syscall_src += arch-mips/syscalls/utimes.S
syscall_src += arch-mips/syscalls/wait4.S
syscall_src += arch-mips/syscalls/write.S
syscall_src += arch-mips/syscalls/writev.S
diff --git a/libc/arch-mips/syscalls/access.S b/libc/arch-mips/syscalls/access.S
deleted file mode 100644
index 941b791..0000000
--- a/libc/arch-mips/syscalls/access.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl access
- .align 4
- .ent access
-
-access:
- .set noreorder
- .cpload $t9
- li $v0, __NR_access
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end access
diff --git a/libc/arch-mips/syscalls/chmod.S b/libc/arch-mips/syscalls/chmod.S
deleted file mode 100644
index dd5a1f2..0000000
--- a/libc/arch-mips/syscalls/chmod.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl chmod
- .align 4
- .ent chmod
-
-chmod:
- .set noreorder
- .cpload $t9
- li $v0, __NR_chmod
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end chmod
diff --git a/libc/arch-mips/syscalls/chown.S b/libc/arch-mips/syscalls/chown.S
deleted file mode 100644
index afe807d..0000000
--- a/libc/arch-mips/syscalls/chown.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl chown
- .align 4
- .ent chown
-
-chown:
- .set noreorder
- .cpload $t9
- li $v0, __NR_chown
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end chown
diff --git a/libc/arch-mips/syscalls/lchown.S b/libc/arch-mips/syscalls/lchown.S
deleted file mode 100644
index f23aa6a..0000000
--- a/libc/arch-mips/syscalls/lchown.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl lchown
- .align 4
- .ent lchown
-
-lchown:
- .set noreorder
- .cpload $t9
- li $v0, __NR_lchown
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end lchown
diff --git a/libc/arch-mips/syscalls/link.S b/libc/arch-mips/syscalls/link.S
deleted file mode 100644
index e197927..0000000
--- a/libc/arch-mips/syscalls/link.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl link
- .align 4
- .ent link
-
-link:
- .set noreorder
- .cpload $t9
- li $v0, __NR_link
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end link
diff --git a/libc/arch-mips/syscalls/mknod.S b/libc/arch-mips/syscalls/linkat.S
similarity index 75%
rename from libc/arch-mips/syscalls/mknod.S
rename to libc/arch-mips/syscalls/linkat.S
index 579acaf..dae07dd 100644
--- a/libc/arch-mips/syscalls/mknod.S
+++ b/libc/arch-mips/syscalls/linkat.S
@@ -2,14 +2,14 @@
#include <asm/unistd.h>
.text
- .globl mknod
+ .globl linkat
.align 4
- .ent mknod
+ .ent linkat
-mknod:
+linkat:
.set noreorder
.cpload $t9
- li $v0, __NR_mknod
+ li $v0, __NR_linkat
syscall
bnez $a3, 1f
move $a0, $v0
@@ -20,4 +20,4 @@
j $t9
nop
.set reorder
- .end mknod
+ .end linkat
diff --git a/libc/arch-mips/syscalls/lstat.S b/libc/arch-mips/syscalls/lstat.S
deleted file mode 100644
index 78e7a98..0000000
--- a/libc/arch-mips/syscalls/lstat.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl lstat
- .align 4
- .ent lstat
-
-lstat:
- .set noreorder
- .cpload $t9
- li $v0, __NR_lstat64
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end lstat
diff --git a/libc/arch-mips/syscalls/mkdir.S b/libc/arch-mips/syscalls/mkdir.S
deleted file mode 100644
index ec7412a..0000000
--- a/libc/arch-mips/syscalls/mkdir.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl mkdir
- .align 4
- .ent mkdir
-
-mkdir:
- .set noreorder
- .cpload $t9
- li $v0, __NR_mkdir
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end mkdir
diff --git a/libc/arch-mips/syscalls/mknod.S b/libc/arch-mips/syscalls/mknodat.S
similarity index 74%
copy from libc/arch-mips/syscalls/mknod.S
copy to libc/arch-mips/syscalls/mknodat.S
index 579acaf..fc05bb3 100644
--- a/libc/arch-mips/syscalls/mknod.S
+++ b/libc/arch-mips/syscalls/mknodat.S
@@ -2,14 +2,14 @@
#include <asm/unistd.h>
.text
- .globl mknod
+ .globl mknodat
.align 4
- .ent mknod
+ .ent mknodat
-mknod:
+mknodat:
.set noreorder
.cpload $t9
- li $v0, __NR_mknod
+ li $v0, __NR_mknodat
syscall
bnez $a3, 1f
move $a0, $v0
@@ -20,4 +20,4 @@
j $t9
nop
.set reorder
- .end mknod
+ .end mknodat
diff --git a/libc/arch-mips/syscalls/readlink.S b/libc/arch-mips/syscalls/readlink.S
deleted file mode 100644
index adaf7fa..0000000
--- a/libc/arch-mips/syscalls/readlink.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl readlink
- .align 4
- .ent readlink
-
-readlink:
- .set noreorder
- .cpload $t9
- li $v0, __NR_readlink
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end readlink
diff --git a/libc/arch-mips/syscalls/mknod.S b/libc/arch-mips/syscalls/readlinkat.S
similarity index 71%
copy from libc/arch-mips/syscalls/mknod.S
copy to libc/arch-mips/syscalls/readlinkat.S
index 579acaf..3e5d72f 100644
--- a/libc/arch-mips/syscalls/mknod.S
+++ b/libc/arch-mips/syscalls/readlinkat.S
@@ -2,14 +2,14 @@
#include <asm/unistd.h>
.text
- .globl mknod
+ .globl readlinkat
.align 4
- .ent mknod
+ .ent readlinkat
-mknod:
+readlinkat:
.set noreorder
.cpload $t9
- li $v0, __NR_mknod
+ li $v0, __NR_readlinkat
syscall
bnez $a3, 1f
move $a0, $v0
@@ -20,4 +20,4 @@
j $t9
nop
.set reorder
- .end mknod
+ .end readlinkat
diff --git a/libc/arch-mips/syscalls/rename.S b/libc/arch-mips/syscalls/rename.S
deleted file mode 100644
index 113b910..0000000
--- a/libc/arch-mips/syscalls/rename.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl rename
- .align 4
- .ent rename
-
-rename:
- .set noreorder
- .cpload $t9
- li $v0, __NR_rename
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end rename
diff --git a/libc/arch-mips/syscalls/rmdir.S b/libc/arch-mips/syscalls/rmdir.S
deleted file mode 100644
index 97b6744..0000000
--- a/libc/arch-mips/syscalls/rmdir.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl rmdir
- .align 4
- .ent rmdir
-
-rmdir:
- .set noreorder
- .cpload $t9
- li $v0, __NR_rmdir
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end rmdir
diff --git a/libc/arch-mips/syscalls/stat.S b/libc/arch-mips/syscalls/stat.S
deleted file mode 100644
index ca1b26f..0000000
--- a/libc/arch-mips/syscalls/stat.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl stat
- .align 4
- .ent stat
-
-stat:
- .set noreorder
- .cpload $t9
- li $v0, __NR_stat64
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end stat
diff --git a/libc/arch-mips/syscalls/symlink.S b/libc/arch-mips/syscalls/symlink.S
deleted file mode 100644
index 7a49858..0000000
--- a/libc/arch-mips/syscalls/symlink.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl symlink
- .align 4
- .ent symlink
-
-symlink:
- .set noreorder
- .cpload $t9
- li $v0, __NR_symlink
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end symlink
diff --git a/libc/arch-mips/syscalls/mknod.S b/libc/arch-mips/syscalls/symlinkat.S
similarity index 72%
copy from libc/arch-mips/syscalls/mknod.S
copy to libc/arch-mips/syscalls/symlinkat.S
index 579acaf..9c43241 100644
--- a/libc/arch-mips/syscalls/mknod.S
+++ b/libc/arch-mips/syscalls/symlinkat.S
@@ -2,14 +2,14 @@
#include <asm/unistd.h>
.text
- .globl mknod
+ .globl symlinkat
.align 4
- .ent mknod
+ .ent symlinkat
-mknod:
+symlinkat:
.set noreorder
.cpload $t9
- li $v0, __NR_mknod
+ li $v0, __NR_symlinkat
syscall
bnez $a3, 1f
move $a0, $v0
@@ -20,4 +20,4 @@
j $t9
nop
.set reorder
- .end mknod
+ .end symlinkat
diff --git a/libc/arch-mips/syscalls/unlink.S b/libc/arch-mips/syscalls/unlink.S
deleted file mode 100644
index 2900707..0000000
--- a/libc/arch-mips/syscalls/unlink.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl unlink
- .align 4
- .ent unlink
-
-unlink:
- .set noreorder
- .cpload $t9
- li $v0, __NR_unlink
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end unlink
diff --git a/libc/arch-mips/syscalls/utimes.S b/libc/arch-mips/syscalls/utimes.S
deleted file mode 100644
index dc683e5..0000000
--- a/libc/arch-mips/syscalls/utimes.S
+++ /dev/null
@@ -1,23 +0,0 @@
-/* Generated by gensyscalls.py. Do not edit. */
-
-#include <asm/unistd.h>
- .text
- .globl utimes
- .align 4
- .ent utimes
-
-utimes:
- .set noreorder
- .cpload $t9
- li $v0, __NR_utimes
- syscall
- bnez $a3, 1f
- move $a0, $v0
- j $ra
- nop
-1:
- la $t9,__set_errno
- j $t9
- nop
- .set reorder
- .end utimes