glibc/sysdeps/unix/sysv/linux/powerpc
Ulrich Weigand 5162e7dd96 PowerPC64: Fix incorrect CFI in *context routines
The context established by "makecontext" has a link register pointing
back to an error path within the makecontext routine.  This is currently
covered by the CFI FDE for makecontext itself, which is simply wrong
for the stack frame *inside* the context.  When trying to unwind (e.g.
doing a backtrace) in a routine inside a context created by makecontext,
this can lead to uninitialized stack slots being accessed, causing the
unwinder to crash in the worst case.

Similarly, during parts of the "setcontext" routine, when the stack
pointer has already been switched to point to the new context, the
address range is still covered by the CFI FDE for setcontext.  When
trying to unwind in that situation (e.g. backtrace from an async
signal handler for profiling), it is again possible that the unwinder
crashes.

Theses are all problems in existing code, but the changes in stack
frame layout appear to make the "worst case" much more likely in
the ELFv2 ABI context.  This causes regressions e.g. in the libgo
testsuite on ELFv2.

This patch fixes this by ending the makecontext/setcontext FDEs
before those problematic parts of the assembler, similar to what
is already done on other platforms.   This fixes the libgo
regression on ELFv2.
2013-12-04 07:41:37 -06:00
..
bits Use __glibc_reserved instead __unused. 2013-11-26 12:32:28 +01:00
powerpc32 Add powerpc-nofpu/e500 support functions for atomic compound assignment and FLT_ROUNDS. 2013-11-28 18:01:41 +00:00
powerpc64 PowerPC64: Fix incorrect CFI in *context routines 2013-12-04 07:41:37 -06:00
sys Use __glibc_reserved instead __unused. 2013-11-26 12:32:28 +01:00
chown.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
configure rename configure.in to configure.ac 2013-10-30 17:32:08 +10:00
configure.ac rename configure.in to configure.ac 2013-10-30 17:32:08 +10:00
dl-brk.S Update. 2002-04-06 01:45:15 +00:00
dl-cache.h Update. 2003-06-25 08:19:44 +00:00
dl-static.c PowerPC: use _dl_static_init to set GLRO(gl_pagesize) 2013-07-23 07:39:57 -05:00
dl-sysdep.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
fchownat.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
get_clockfreq.c PowerPC: Rename __kernel_vdso_get_tbfreq to __kernel_get_tbfreq. 2013-01-18 07:44:38 -06:00
get_timebase_freq.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
getdents64.c Update. 2000-08-12 05:14:52 +00:00
getmsg.c
getrlimit64.c
gettimeofday.c PowerPC: Fix vDSO missing ODP entries 2013-11-08 05:04:25 -06:00
init-first.c PowerPC: fix backtrace to handle signal trampolines 2013-08-20 15:05:49 -05:00
ioctl.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
ipc_priv.h Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
kernel_termios.h Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
lchown.S Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
ldconfig.h Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
ldd-rewrite.sed Update. 2002-09-05 10:28:51 +00:00
ldsodefs.h PowerPC: use _dl_static_init to set GLRO(gl_pagesize) 2013-07-23 07:39:57 -05:00
libc-start.c Fix typos. 2013-08-29 09:11:45 +02:00
Makefile PowerPC: use _dl_static_init to set GLRO(gl_pagesize) 2013-07-23 07:39:57 -05:00
nldbl-abi.h 2006-01-27 Dwayne Grant McConnell <decimal@us.ibm.com> 2006-01-28 00:15:15 +00:00
oldgetrlimit64.c Update. 2000-08-16 01:40:12 +00:00
profil-counter.h
putmsg.c
readdir64_r.c Update. 2000-08-12 05:14:52 +00:00
readdir64.c Update. 2000-08-12 05:14:52 +00:00
readelflib.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
rt-sysdep.c Update. 2004-04-19 06:19:34 +00:00
sched_getcpu.c PowerPC: Change sched_getcpu to use vDSO getcpu instead of syscall. 2013-01-09 20:30:11 -06:00
setrlimit.c
sigcontextinfo.h Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
syscall.S Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
syscalls.list Update. 2003-09-03 02:58:30 +00:00
sysdep.c Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
test-gettimebasefreq.c Add #include <stdint.h> for uint[32|64]_t usage (except installed headers). 2013-05-16 11:32:54 -05:00
time.c PowerPC: Fix vDSO missing ODP entries 2013-11-08 05:04:25 -06:00
Versions PowerPC: use _dl_static_init to set GLRO(gl_pagesize) 2013-07-23 07:39:57 -05:00