glibc/sysdeps/unix/sysv/linux/mips/mips64/n64
Joseph Myers 5163b4b76f Fix MIPS mmap negative offset handling for consistency (bug 19550).
The handling of negative offsets in MIPS mmap is inconsistent with
other architectures, as shown by failure of the test
posix/tst-mmap-offset for o32 and n32.  The MIPS mmap syscall uses a
signed argument and does a signed arithmetic shift on it, whereas the
glibc semantics expected by that test are for the offset to be
considered as a large positive offset.  This patch makes MIPS
consistent with other architectures as far as possible by using the
mmap2 syscall on o32 (#including the generic implementation), and
making mmap not an alias for mmap64 for n32, with a custom
implementation for n32 that zero-extends the offset argument to 64-bit
before calling the mmap syscall.

Tested for MIPS64 (o32, n32, n64).

	[BZ #19550]
	* sysdeps/unix/sysv/linux/mips/mips32/mmap.c: New file.
	* sysdeps/unix/sysv/linux/mips/mips64/mmap64.c: Move to ....
	* sysdeps/unix/sysv/linux/mips/mips64/n64/mmap64.c: ... here.
	* sysdeps/unix/sysv/linux/mips/mips64/n32/mmap.c: New file.
	* sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list (mmap64):
	New syscall entry.
	* sysdeps/unix/sysv/linux/mips/mips64/n64/syscalls.list (mmap):
	New syscall entry.
	* sysdeps/unix/sysv/linux/mips/mips64/syscalls.list (mmap): Remove
	syscall entry.
2016-02-01 18:20:21 +00:00
..
c++-types.data MIPS: Consolidate nptl/ subdirectories under linux/... 2014-06-27 11:41:04 -07:00
fallocate64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
fallocate.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
fstatfs64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
fts64.c Add LFS support for fts functions (bug 11460) 2015-11-06 11:24:16 +01:00
fts.c Add LFS support for fts functions (bug 11460) 2015-11-06 11:24:16 +01:00
ftw64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
ftw.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
glob64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
ioctl.S Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
ld.abilist Simplify the abilist format 2015-11-06 13:58:53 +01:00
libc.abilist Simplify the abilist format 2015-11-06 13:58:53 +01:00
libresolv.abilist Simplify the abilist format 2015-11-06 13:58:53 +01:00
mmap64.c Fix MIPS mmap negative offset handling for consistency (bug 19550). 2016-02-01 18:20:21 +00:00
posix_fadvise64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
posix_fadvise.c Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
posix_fallocate64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
posix_fallocate.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
preadv64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
pwritev64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
sendfile64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
statfs64.c Move mips from ports to libc. 2014-02-10 23:30:21 +00:00
syscalls.list Fix MIPS mmap negative offset handling for consistency (bug 19550). 2016-02-01 18:20:21 +00:00
sysdep.h Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00