summaryrefslogtreecommitdiff
path: root/libc/sysdeps
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2003-02-26 02:13:56 +0000
committerEric Andersen <andersen@codepoet.org>2003-02-26 02:13:56 +0000
commit8b1cd1869a7a15a31153e579a1dde0b257d2f358 (patch)
tree7bea1aa4c9c438a23873934fa021c2c7f6336907 /libc/sysdeps
parent00a25ecaa0ba75454263efc7a977cf7a7b227c58 (diff)
Prefer mmap2 for mips when available. Fix the mmap test.
-Erik
Diffstat (limited to 'libc/sysdeps')
-rw-r--r--libc/sysdeps/linux/mips/_mmap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libc/sysdeps/linux/mips/_mmap.c b/libc/sysdeps/linux/mips/_mmap.c
index 43fb0be74..23e62c642 100644
--- a/libc/sysdeps/linux/mips/_mmap.c
+++ b/libc/sysdeps/linux/mips/_mmap.c
@@ -4,5 +4,10 @@
#include <sys/mman.h>
#include <sys/syscall.h>
+#ifdef __NR_mmap2
+# undef __NR_mmap
+# define __NR_mmap __NR_mmap2
+#endif
+
_syscall6 (__ptr_t, mmap, __ptr_t, addr, size_t, len, int, prot,
int, flags, int, fd, __off_t, offset);