aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/mips/sysdep.h
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-02-03 11:52:43 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-02-14 21:09:12 -0300
commitcf1e05f5990aba073864cd0bc681cd017e663351 (patch)
tree01f40ffae3c92767f861c19d7ce623d3b5649841 /sysdeps/unix/sysv/linux/mips/sysdep.h
parentebb4aed873de6ee6ce3c0d2f55660808a04c9e68 (diff)
downloadglibc-cf1e05f5990aba073864cd0bc681cd017e663351.tar
glibc-cf1e05f5990aba073864cd0bc681cd017e663351.tar.gz
glibc-cf1e05f5990aba073864cd0bc681cd017e663351.tar.bz2
glibc-cf1e05f5990aba073864cd0bc681cd017e663351.zip
mips: Use Linux kABI for syscall return
It changes the mips INTERNAL_SYSCALL* and internal_syscall* macros to return a negative value instead of the 'a3' register value on then 'err' macro argument. The macro INTERNAL_SYSCALL_DECL is no longer required, and the INTERNAL_SYSCALL_ERROR_P macro follows the other Linux kABIs. The redefinition of INTERNAL_VSYSCALL_CALL is also no longer required. Checked on mips64-linux-gnu, mips64n32-linux-gnu, and mips-linux-gnu.
Diffstat (limited to 'sysdeps/unix/sysv/linux/mips/sysdep.h')
-rw-r--r--sysdeps/unix/sysv/linux/mips/sysdep.h16
1 files changed, 0 insertions, 16 deletions
diff --git a/sysdeps/unix/sysv/linux/mips/sysdep.h b/sysdeps/unix/sysv/linux/mips/sysdep.h
index a4cf1540fe..877768a249 100644
--- a/sysdeps/unix/sysv/linux/mips/sysdep.h
+++ b/sysdeps/unix/sysv/linux/mips/sysdep.h
@@ -28,19 +28,3 @@
#endif
#define HAVE_GETTIMEOFDAY_VSYSCALL "__vdso_gettimeofday"
#define HAVE_CLOCK_GETRES_VSYSCALL "__vdso_clock_getres"
-
-#ifndef __ASSEMBLER__
-
-/* Standard MIPS syscalls have an error flag, and return a positive errno
- when the error flag is set. Emulate this behaviour for vsyscalls so that
- the INTERNAL_SYSCALL_{ERROR_P,ERRNO} macros work correctly. */
-#define INTERNAL_VSYSCALL_CALL(funcptr, err, nr, args...) \
- ({ \
- long int _ret = funcptr (args); \
- err = ((unsigned long int) (_ret) >= (unsigned long int) -4095L); \
- if (err) \
- _ret = -_ret; \
- _ret; \
- })
-
-#endif /* __ASSEMBLER__ */