about summary refs log tree commit diff
path: root/sysdeps/unix/sysv
Commit message (Collapse)AuthorAgeFilesLines
...
* Add e500 port.Joseph Myers2013-10-182-1/+4
|
* Move powerpc ports pieces to libc.Joseph Myers2013-10-0424-0/+4153
|
* e500 port: adjust sysdeps/unix/sysv/linux/configure.in case.Joseph Myers2013-10-042-2/+2
|
* e500 port: getcontext / setcontext / swapcontext.Joseph Myers2013-10-043-0/+17
|
* PowerPC SIGSTKSZAlan Modra2013-10-041-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | http://sourceware.org/ml/libc-alpha/2013-08/msg00093.html This copies the sparc version of sigstack.h, which gives powerpc #define MINSIGSTKSZ 4096 #define SIGSTKSZ 16384 Before the VSX changes, struct rt_sigframe size was 1920 plus 128 for __SIGNAL_FRAMESIZE giving ppc64 exactly the default MINSIGSTKSZ of 2048. After VSX, ucontext increased by 256 bytes. Oops, we're over MINSIGSTKSZ, so powerpc has been using the wrong value for quite a while. Add another ucontext for TM and rt_sigframe is now at 3872, giving actual MINSIGSTKSZ of 4000. The glibc testcase that I was looking at was tst-cancel21, which allocates 2*SIGSTKSZ (not because the test is trying to be conservative, but because the test actually has nested signal stack frames). We blew the allocation by 48 bytes when using current mainline gcc to compile glibc (le ppc64). The required stack depth in _dl_lookup_symbol_x from the top of the next signal frame was 10944 bytes. I guess you'd want to add 288 to that, implying an actual SIGSTKSZ of 11232. * sysdeps/unix/sysv/linux/powerpc/bits/sigstack.h: New file.
* PowerPC makecontextAlan Modra2013-10-042-4/+10
| | | | | | | | | | | http://sourceware.org/ml/libc-alpha/2013-08/msg00092.html Use conditional form of branch and link to avoid destroying the cpu link stack used to predict blr return addresses. * sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S: Use conditional form of branch and link when obtaining pc. * sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S: Likewise.
* PowerPC LE _dl_hwcap accessAlan Modra2013-10-043-16/+16
| | | | | | | | | | | http://sourceware.org/ml/libc-alpha/2013-08/msg00091.html More LE support, correcting word accesses to _dl_hwcap. * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S: Use HIWORD/LOWORD. * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S: Ditto. * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S: Ditto.
* tst-fanotify: fix styleMike Frysinger2013-09-281-8/+9
| | | | | Reported-by: Andreas Jaeger <aj@suse.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* Add O_TMPFILE to <fcntl.h>Andreas Schwab2013-09-112-0/+5
|
* Coordinate IPv6 definitions for Linux and glibcCarlos O'Donell2013-09-061-0/+12
| | | | | | | | | | This change synchronizes the glibc headers with the Linux kernel headers and arranges to coordinate the definition of structures already defined the Linux kernel UAPI headers. It is now safe to include glibc's netinet/in.h or Linux's linux/in6.h in any order in a userspace application and you will get the same ABI. The ABI is guaranteed by UAPI and glibc.
* tst-fanotify: skip when we get back EPERMMike Frysinger2013-09-051-5/+8
| | | | | | | | Since fanotify_init requires CAP_SYS_ADMIN in order to work (which usually means running as root), we need to handle that error case too. Reported-by: Andreas Jaeger <aj@suse.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* tst-fanotify: new simple testMike Frysinger2013-09-022-1/+57
| | | | | | Basic test for the fanotify functions. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* Fix typos.Ondřej Bílka2013-08-303-3/+3
|
* Remove aix specific files.Ondřej Bílka2013-08-299-869/+0
|
* Support ELFOSABI_GNU on all GNU systems.Thomas Schwinge2013-08-291-23/+0
|
* Use ELFOSABI_GNU instead of ELFOSABI_LINUX.Thomas Schwinge2013-08-291-4/+4
|
* Fix typos.Ondřej Bílka2013-08-296-6/+6
|
* Clean up __libc_sa_len helper.Roland McGrath2013-08-273-66/+13
|
* Fix typos.Ondřej Bílka2013-08-211-1/+1
|
* PowerPC: fix backtrace to handle signal trampolinesAdhemerval Zanella2013-08-202-0/+23
| | | | | | This patch fixes backtrace for PPC32 and PPC64 to correctly handle signal trampolines. The 'debug/tst-backtrace6.c' also check for SA_SIGINFO handling, where is triggers another vDSO symbols for PPC32.
* Include <string.h> in sysdeps/unix/sysv/linux/mmap64.c.Joseph Myers2013-08-201-0/+1
|
* Use __getpagesize and __ffs in MMAP2_PAGE_SHIFT == -1 case of mmap64.Joseph Myers2013-08-201-3/+2
|
* * sysdeps/unix/sysv/linux/s390/sys/procfs.h (struct elf_prstatus):Andreas Krebbel2013-08-201-1/+2
| | | | Align 32 bit compat elf_greg to 8 bytes.
* CVE-2013-4237, BZ #14699: Buffer overflow in readdir_rFlorian Weimer2013-08-162-2/+0
| | | | | | | | | | | | | | | | | | | | * sysdeps/posix/dirstream.h (struct __dirstream): Add errcode member. * sysdeps/posix/opendir.c (__alloc_dir): Initialize errcode member. * sysdeps/posix/rewinddir.c (rewinddir): Reset errcode member. * sysdeps/posix/readdir_r.c (__READDIR_R): Enforce NAME_MAX limit. Return delayed error code. Remove GETDENTS_64BIT_ALIGNED conditional. * sysdeps/unix/sysv/linux/wordsize-64/readdir_r.c: Do not define GETDENTS_64BIT_ALIGNED. * sysdeps/unix/sysv/linux/i386/readdir64_r.c: Likewise. * manual/filesys.texi (Reading/Closing Directory): Document ENAMETOOLONG return value of readdir_r. Recommend readdir more strongly. * manual/conf.texi (Limits for Files): Add portability note to NAME_MAX, PATH_MAX. (Pathconf): Add portability note for _PC_NAME_MAX, _PC_PATH_MAX.
* PowerPC: use _dl_static_init to set GLRO(gl_pagesize)Adhemerval Zanella2013-07-234-0/+129
| | | | | | This patch fixes dlfcn/tststatic5 for PowerPC where pagesize variable was not properly initialized in certain cases. This patch is based on other architecture code.
* CVE-2013-2207, BZ #15755: Disable pt_chown.Carlos O'Donell2013-07-211-2/+3
| | | | | | | | | | | | | | | | | | | | | | | The helper binary pt_chown tricked into granting access to another user's pseudo-terminal. Pre-conditions for the attack: * Attacker with local user account * Kernel with FUSE support * "user_allow_other" in /etc/fuse.conf * Victim with allocated slave in /dev/pts Using the setuid installed pt_chown and a weak check on whether a file descriptor is a tty, an attacker could fake a pty check using FUSE and trick pt_chown to grant ownership of a pty descriptor that the current user does not own. It cannot access /dev/pts/ptmx however. In most modern distributions pt_chown is not needed because devpts is enabled by default. The fix for this CVE is to disable building and using pt_chown by default. We still provide a configure option to enable hte use of pt_chown but distributions do so at their own risk.
* BZ #15711: Avoid circular dependency for syscall.hCarlos O'Donell2013-07-161-2/+9
| | | | | | | | | | | | | | | | | | The generated header is compiled with `-ffreestanding' to avoid any circular dependencies against the installed implementation headers. Such a dependency would require the implementation header to be installed before the generated header could be built (See bug 15711). In current practice the generated header dependencies do not include any of the implementation headers removed by the use of `-ffreestanding'. --- 2013-07-15 Carlos O'Donell <carlos@redhat.com> [BZ #15711] * sysdeps/unix/sysv/linux/Makefile ($(objpfx)bits/syscall%h): Avoid system header dependency with -ffreestanding. ($(objpfx)bits/syscall%d): Likewise.
* Sync sys/ptrace with Linux 3.10Andreas Jaeger2013-07-044-5/+80
|
* Add GLRO(dl_hwcap2) for new AT_HWCAP2 auxv_t a_type.Ryan S. Arnold2013-06-282-2/+10
|
* Consistently use page_shift in sysdeps/unix/sysv/linux/mmap64.c.Joseph Myers2013-06-281-1/+1
|
* PowerPC: Enable POWER8 platform sans hwcap bits.Ryan S. Arnold2013-06-242-0/+4
|
* Include <string.h> in sysdeps/unix/sysv/linux/libc_fatal.c.Joseph Myers2013-06-221-0/+1
|
* New API to set default thread attributesSiddhesh Poyarekar2013-06-1510-0/+40
| | | | | | | This patch introduces two new convenience functions to set the default thread attributes used for creating threads. This allows a programmer to set the default thread attributes just once in a process and then run pthread_create without additional attributes.
* Improve precision of clock() function on LinuxSiddhesh Poyarekar2013-06-131-20/+16
| | | | | | | Resolves #12515. Use CLOCK_PROCESS_CPUTIME_ID instead of times to get better precision in the value returned by clock.
* Fix symbol definitions for __clock_* functionsSiddhesh Poyarekar2013-06-112-5/+5
| | | | | | __clock_gettime and other __clock_* functions could result in an extra PLT reference within libc.so if it actually gets used. None of the code currently uses them, which is why this probably went unnoticed.
* Use (void) in no-arguments function definitions.Joseph Myers2013-06-084-7/+7
|
* Fix leading whitespaces.Ondrej Bilka2013-06-062-2/+2
|
* Remove trailing whitespace.Joseph Myers2013-06-0529-70/+70
|
* Update bits/siginfo.h with Linux hwpoison SIGBUS changesEdjunior Barbosa Machado2013-05-223-3/+21
| | | | | | Adds new SIGBUS error codes for hardware poison signals, syncing with the current kernel headers (v3.9). It also adds si_trapno field for alpha.
* Add #include <stdint.h> for uint[32|64]_t usage (except installed headers).Ryan S. Arnold2013-05-1610-0/+10
|
* Update s390/bits/siginfo.hEdjunior Machado2013-05-151-3/+7
| | | | | | | | | | 2013-05-15 Edjunior Machado <emachado@linux.vnet.ibm.com> * sysdeps/unix/sysv/linux/s390/bits/siginfo.h (siginfo_t): Remove si_trapno and add si_addr_lsb to _sifields.sigfault. (si_trapno): Remove macro. (si_addr_lsb): Define new macro. (BUS_MCEERR_AR, BUS_MCEERR_AO): Define new values.
* Add getgid.c for SHChristian Grönke2013-05-101-0/+1
| | | | | [BZ #12387] * sysdeps/unix/sysv/linux/sh/getgid.c: New file.
* Fix integer overflow in sysdeps/unix/sysv/linux/bits/sched.hAndreas Jaeger2013-05-101-3/+3
| | | | | | [BZ #15448] * sysdeps/unix/sysv/linux/bits/sched.h (__CPU_SET_S) (__CPU_CLR_S, __CPU_ISSET_S): Avoid integer overflow.
* Fix glob64 broken by cleanup.Roland McGrath2013-05-061-0/+2
|
* Move dummy glob64.c alongside glob.c that defines glob64.Roland McGrath2013-05-061-1/+0
|
* Split _dl_writev out from _dl_debug_vdprintf.Roland McGrath2013-05-061-0/+38
|
* Consolidate definitions of _FORTIFY_SOURCE wrappers for open{,64}{,at}.Roland McGrath2013-05-036-85/+4
|
* PowerPC: Add time vDSO supportAdhemerval Zanella2013-05-034-3/+70
| | | | | | | | PowerPC kernel now provides a vDSO implementation for time syscall (commit fcb41a2030abe0eb716ef0798035ef9562097f42). This patch changes time syscall wrapper to use the vDSO when available. It also changes the default non vDSO time on PowerPC to use sysdeps/posix/time.c (since gettimeofday is a vDSO call).
* Sync with Linux 3.9Andreas Jaeger2013-05-031-1/+3
| | | | | | | | * sysdeps/gnu/netinet/tcp.h (TCP_TIMESTAMP): New value, from Linux 3.9. * sysdeps/unix/sysv/linux/bits/socket.h (PF_VSOCK, AF_VSOCK): Add. (PF_MAX): Adjust for VSOCK change.
* S/390: Change struct statfs[64] member types to unsigned valuesHeiko Carstens2013-04-231-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kay Sievers reported that coreutils' stat tool has a problem with s390's statfs[64] definition: > The definition of struct statfs::f_type needs a fix. s390 is the only > architecture in the kernel that uses an int and expects magic > constants lager than INT_MAX to fit into. > > A fix is needed to make Fedora boot on s390, it currently fails to do > so. Userspace does not want to add code to paper-over this issue. [...] > Even coreutils cannot handle it: > #define RAMFS_MAGIC 0x858458f6 > # stat -f -c%t / > ffffffff858458f6 > > #define BTRFS_SUPER_MAGIC 0x9123683E > # stat -f -c%t /mnt > ffffffff9123683e The bug is caused by an implicit sign extension within the stat tool: out_uint_x (pformat, prefix_len, statfsbuf->f_type); where the format finally will be "%lx". A similar problem can be found in the 'tail' tool. s390 is the only architecture which has an int type f_type member in struct statfs[64]. Other architectures have either unsigned ints or long values, so that the problem doesn't occur there. Therefore change the type of the f_type member to unsigned int, so that we get zero extension instead sign extension when assignment to a long value happens. Reported-by: Kay Sievers <kay@vrfy.org> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>