diff options
author | Eric Andersen <andersen@codepoet.org> | 2001-10-16 03:10:39 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2001-10-16 03:10:39 +0000 |
commit | 46d6bbc8e2d2016ecbe851a10bb1676bd7e96274 (patch) | |
tree | b76ccd5c7986509f6153f98e7f40168454619d41 /libc/sysdeps/linux/v850/_mmap.c | |
parent | 38b024251f16664891f1b714d9d786168cef0cca (diff) |
Revert global old mmap usage, and do it per arch
Diffstat (limited to 'libc/sysdeps/linux/v850/_mmap.c')
-rw-r--r-- | libc/sysdeps/linux/v850/_mmap.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/libc/sysdeps/linux/v850/_mmap.c b/libc/sysdeps/linux/v850/_mmap.c new file mode 100644 index 000000000..a0c58253a --- /dev/null +++ b/libc/sysdeps/linux/v850/_mmap.c @@ -0,0 +1,20 @@ +/* Use old style mmap for v850 */ +#include <unistd.h> +#include <sys/mman.h> +#include <sys/syscall.h> + + +__ptr_t mmap(__ptr_t addr, size_t len, int prot, + int flags, int fd, __off_t offset) +{ + unsigned long buffer[6]; + + buffer[0] = (unsigned long) addr; + buffer[1] = (unsigned long) len; + buffer[2] = (unsigned long) prot; + buffer[3] = (unsigned long) flags; + buffer[4] = (unsigned long) fd; + buffer[5] = (unsigned long) offset; + return (__ptr_t) _mmap(buffer); +} + |