From 25593dcaf4cbdb744eff54fc426b29ae0b96817d Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Sat, 21 Apr 2012 08:38:55 -0700 Subject: Merge sysdeps/unix/sysv/linux/arm/eabi into sysdeps/unix/sysv/linux/arm. --- ChangeLog.arm | 161 ++++++++++++ ChangeLog.mips | 6 + sysdeps/unix/sysv/linux/arm/Makefile | 41 +++ sysdeps/unix/sysv/linux/arm/____longjmp_chk.S | 90 +++++++ sysdeps/unix/sysv/linux/arm/configure | 6 + sysdeps/unix/sysv/linux/arm/configure.in | 6 + sysdeps/unix/sysv/linux/arm/eabi/Makefile | 42 ---- sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S | 90 ------- sysdeps/unix/sysv/linux/arm/eabi/configure | 6 - sysdeps/unix/sysv/linux/arm/eabi/configure.in | 6 - sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c | 76 ------ sysdeps/unix/sysv/linux/arm/eabi/getcontext.S | 113 --------- .../unix/sysv/linux/arm/eabi/internal_accept4.S | 6 - .../unix/sysv/linux/arm/eabi/internal_recvmmsg.S | 6 - .../unix/sysv/linux/arm/eabi/internal_sendmmsg.S | 6 - sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S | 48 ---- sysdeps/unix/sysv/linux/arm/eabi/makecontext.c | 73 ------ sysdeps/unix/sysv/linux/arm/eabi/mmap64.S | 68 ----- sysdeps/unix/sysv/linux/arm/eabi/msgctl.c | 1 - sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile | 17 -- sysdeps/unix/sysv/linux/arm/eabi/nptl/configure | 4 - sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in | 8 - .../arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c | 1 - .../linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c | 1 - .../unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h | 251 ------------------- .../sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c | 158 ------------ .../unix/sysv/linux/arm/eabi/nptl/unwind-resume.c | 101 -------- sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h | 278 --------------------- sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c | 1 - sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c | 1 - sysdeps/unix/sysv/linux/arm/eabi/pread.c | 60 ----- sysdeps/unix/sysv/linux/arm/eabi/pread64.c | 62 ----- sysdeps/unix/sysv/linux/arm/eabi/pwrite.c | 60 ----- sysdeps/unix/sysv/linux/arm/eabi/pwrite64.c | 63 ----- sysdeps/unix/sysv/linux/arm/eabi/readahead.c | 50 ---- sysdeps/unix/sysv/linux/arm/eabi/semctl.c | 1 - sysdeps/unix/sysv/linux/arm/eabi/setcontext.S | 101 -------- sysdeps/unix/sysv/linux/arm/eabi/shmctl.c | 1 - sysdeps/unix/sysv/linux/arm/eabi/sigrestorer.S | 121 --------- sysdeps/unix/sysv/linux/arm/eabi/swapcontext.S | 63 ----- sysdeps/unix/sysv/linux/arm/eabi/syscall.S | 47 ---- sysdeps/unix/sysv/linux/arm/eabi/syscalls.list | 32 --- sysdeps/unix/sysv/linux/arm/eabi/sysdep.h | 199 --------------- sysdeps/unix/sysv/linux/arm/eabi/truncate64.c | 74 ------ sysdeps/unix/sysv/linux/arm/eabi/umount.c | 30 --- sysdeps/unix/sysv/linux/arm/ftruncate64.c | 76 ++++++ sysdeps/unix/sysv/linux/arm/getcontext.S | 113 +++++++++ sysdeps/unix/sysv/linux/arm/internal_accept4.S | 6 + sysdeps/unix/sysv/linux/arm/internal_recvmmsg.S | 6 + sysdeps/unix/sysv/linux/arm/internal_sendmmsg.S | 6 + sysdeps/unix/sysv/linux/arm/libc-do-syscall.S | 48 ++++ sysdeps/unix/sysv/linux/arm/makecontext.c | 73 ++++++ sysdeps/unix/sysv/linux/arm/mmap64.S | 68 +++++ sysdeps/unix/sysv/linux/arm/msgctl.c | 1 + sysdeps/unix/sysv/linux/arm/nptl/Makefile | 17 ++ sysdeps/unix/sysv/linux/arm/nptl/configure | 4 + sysdeps/unix/sysv/linux/arm/nptl/configure.in | 8 + .../linux/arm/nptl/nptl-aeabi_unwind_cpp_pr1.c | 1 + .../sysv/linux/arm/nptl/rt-aeabi_unwind_cpp_pr1.c | 1 + sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h | 251 +++++++++++++++++++ .../unix/sysv/linux/arm/nptl/unwind-forcedunwind.c | 158 ++++++++++++ sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c | 101 ++++++++ sysdeps/unix/sysv/linux/arm/nptl/unwind.h | 278 +++++++++++++++++++++ sysdeps/unix/sysv/linux/arm/oldgetrlimit.c | 1 + sysdeps/unix/sysv/linux/arm/oldsetrlimit.c | 1 + sysdeps/unix/sysv/linux/arm/pread.c | 60 +++++ sysdeps/unix/sysv/linux/arm/pread64.c | 62 +++++ sysdeps/unix/sysv/linux/arm/pwrite.c | 60 +++++ sysdeps/unix/sysv/linux/arm/pwrite64.c | 63 +++++ sysdeps/unix/sysv/linux/arm/readahead.c | 50 ++++ sysdeps/unix/sysv/linux/arm/semctl.c | 1 + sysdeps/unix/sysv/linux/arm/setcontext.S | 101 ++++++++ sysdeps/unix/sysv/linux/arm/shmctl.c | 1 + sysdeps/unix/sysv/linux/arm/sigrestorer.S | 121 +++++++++ sysdeps/unix/sysv/linux/arm/socket.S | 126 ---------- sysdeps/unix/sysv/linux/arm/swapcontext.S | 63 +++++ sysdeps/unix/sysv/linux/arm/syscall.S | 47 ++++ sysdeps/unix/sysv/linux/arm/syscalls.list | 35 ++- sysdeps/unix/sysv/linux/arm/sysdep.h | 208 ++++++++++----- sysdeps/unix/sysv/linux/arm/truncate64.c | 74 ++++++ sysdeps/unix/sysv/linux/arm/umount.c | 30 +++ sysdeps/unix/sysv/linux/mips/mips32/readahead.c | 2 +- 82 files changed, 2439 insertions(+), 2519 deletions(-) create mode 100644 sysdeps/unix/sysv/linux/arm/____longjmp_chk.S create mode 100644 sysdeps/unix/sysv/linux/arm/configure create mode 100644 sysdeps/unix/sysv/linux/arm/configure.in delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/Makefile delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/configure delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/configure.in delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/getcontext.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/internal_recvmmsg.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/internal_sendmmsg.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/makecontext.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/mmap64.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/msgctl.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/configure delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-resume.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/pread.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/pread64.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/pwrite.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/pwrite64.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/readahead.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/semctl.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/setcontext.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/shmctl.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/sigrestorer.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/swapcontext.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/syscall.S delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/syscalls.list delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/sysdep.h delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/truncate64.c delete mode 100644 sysdeps/unix/sysv/linux/arm/eabi/umount.c create mode 100644 sysdeps/unix/sysv/linux/arm/ftruncate64.c create mode 100644 sysdeps/unix/sysv/linux/arm/getcontext.S create mode 100644 sysdeps/unix/sysv/linux/arm/internal_accept4.S create mode 100644 sysdeps/unix/sysv/linux/arm/internal_recvmmsg.S create mode 100644 sysdeps/unix/sysv/linux/arm/internal_sendmmsg.S create mode 100644 sysdeps/unix/sysv/linux/arm/libc-do-syscall.S create mode 100644 sysdeps/unix/sysv/linux/arm/makecontext.c create mode 100644 sysdeps/unix/sysv/linux/arm/mmap64.S create mode 100644 sysdeps/unix/sysv/linux/arm/msgctl.c create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/Makefile create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/configure create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/configure.in create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/nptl-aeabi_unwind_cpp_pr1.c create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/rt-aeabi_unwind_cpp_pr1.c create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c create mode 100644 sysdeps/unix/sysv/linux/arm/nptl/unwind.h create mode 100644 sysdeps/unix/sysv/linux/arm/oldgetrlimit.c create mode 100644 sysdeps/unix/sysv/linux/arm/oldsetrlimit.c create mode 100644 sysdeps/unix/sysv/linux/arm/pread.c create mode 100644 sysdeps/unix/sysv/linux/arm/pread64.c create mode 100644 sysdeps/unix/sysv/linux/arm/pwrite.c create mode 100644 sysdeps/unix/sysv/linux/arm/pwrite64.c create mode 100644 sysdeps/unix/sysv/linux/arm/readahead.c create mode 100644 sysdeps/unix/sysv/linux/arm/semctl.c create mode 100644 sysdeps/unix/sysv/linux/arm/setcontext.S create mode 100644 sysdeps/unix/sysv/linux/arm/shmctl.c create mode 100644 sysdeps/unix/sysv/linux/arm/sigrestorer.S delete mode 100644 sysdeps/unix/sysv/linux/arm/socket.S create mode 100644 sysdeps/unix/sysv/linux/arm/swapcontext.S create mode 100644 sysdeps/unix/sysv/linux/arm/syscall.S create mode 100644 sysdeps/unix/sysv/linux/arm/truncate64.c create mode 100644 sysdeps/unix/sysv/linux/arm/umount.c diff --git a/ChangeLog.arm b/ChangeLog.arm index f16e6916df..43a595dc71 100644 --- a/ChangeLog.arm +++ b/ChangeLog.arm @@ -1,3 +1,164 @@ +2012-04-21 Joseph Myers + + [BZ #13556] + * sysdeps/unix/sysv/linux/arm/socket.S: Remove. + * sysdeps/unix/sysv/linux/arm/syscalls.list (syscall): Remove. + (oldgetrlimit): Likewise. + (oldsetrlimit): Likewise. + (syscall): Likewise. + (msgget): Add syscall from eabi/syscalls.list. + (msgrcv): Likewise. + (msgsnd): Likewise. + (shmat): Likewise. + (shmdt): Likewise. + (shmget): Likewise. + (semop): Likewise. + (semtimedop): Likewise. + (semget): Likewise. + (accept): Likewise. + (bind): Likewise. + (connect): Likewise. + (getpeername): Likewise. + (getsockname): Likewise. + (getsockopt): Likewise. + (listen): Likewise. + (recv): Likewise. + (recvfrom): Likewise. + (recvmsg): Likewise. + (send): Likewise. + (sendmsg): Likewise. + (sendto): Likewise. + (setsockopt): Likewise. + (shutdown): Likewise. + (socket): Likewise. + (socketpair): Likewise. + * sysdeps/unix/sysv/linux/arm/eabi/syscalls.list: Remove. + * sysdeps/unix/sysv/linux/arm/Makefile [subdir = csu] + (CFLAGS-libc-start.c): Add setting from eabi/Makefile. + [subdir = rt] (librt-sysdep_routines): Likewise. + [subdir = rt] (librt-shared-only-routines): Likewise. + [subdir = nptl] (libpthread-sysdep_routines): Likewise. + [subdir = nptl] (libpthread-shared-only-routines): Likewise. + [subdir = resolv] (libanl-sysdep_routines): Likewise. + [subdir = resolv] (libanl-shared-only-routines): Likewise. + [subdir = csu] (sysdep_routines): Likewise. + [subdir = nscd] (nscd-modules): Likewise. + [subdir = nss] (libnss_db-sysdep_routines): Likewise. + [subdir = nss] (libnss_db-shared-only-routines): Likewise. + [subdir = posix] (LDFLAGS-tst-rfc3484): Likewise. + [subdir = posix] (LDFLAGS-tst-rfc3484-2): Likewise. + [subdir = posix] (LDFLAGS-tst-rfc3484-3): Likewise. + * sysdeps/unix/sysv/linux/arm/eabi/Makefile: Remove. + * sysdeps/unix/sysv/linux/arm/sysdep.h (__NR_SYSCALL_BASE): Add + test from eabi/sysdep.h. + (__NR_stime): Add #undef from eabi/sysdep.h. + (__NR_alarm): Likewise. + (DO_CALL): Use definition from eabi/sysdep.h. + (DOARGS_0): Likewise. + (DOARGS_1): Likewise. + (DOARGS_2): Likewise. + (DOARGS_3): Likewise. + (DOARGS_4): Likewise. + (DOARGS_5): Likewise. + (DOARGS_6): Likewise. + (DOARGS_7): Likewise. + (UNDOARGS_0): Likewise. + (UNDOARGS_1): Likewise. + (UNDOARGS_2): Likewise. + (UNDOARGS_3): Likewise. + (UNDOARGS_4): Likewise. + (UNDOARGS_5): Likewise. + (UNDOARGS_6): Likewise. + (UNDOARGS_7): Likewise. + (INTERNAL_SYSCALL_RAW): Likewise. + [__thumb__] (LOAD_ARGS_7): Do not define. + [__thumb__] (ASM_ARGS_7): Likewise. + (INTERNAL_SYSCALL_NCS): Use definition from eabi/sysdep.h. + (INTERNAL_SYSCALL_NCS_0): Remove. + (INTERNAL_SYSCALL_NCS_1): Likewise. + (INTERNAL_SYSCALL_NCS_2): Likewise. + (INTERNAL_SYSCALL_NCS_3): Likewise. + (INTERNAL_SYSCALL_NCS_4): Likewise. + (INTERNAL_SYSCALL_NCS_5): Likewise. + * sysdeps/unix/sysv/linux/arm/eabi/sysdep.h: Remove. + * sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S: Move to ... + * sysdeps/unix/sysv/linux/arm/____longjmp_chk.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/configure.in: Move to ... + * sysdeps/unix/sysv/linux/arm/configure.in: ... here. Update + comment. + * sysdeps/unix/sysv/linux/arm/eabi/configure: Move to ... + * sysdeps/unix/sysv/linux/arm/configure: ... here. Regenerate. + * sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c: Move to ... + * sysdeps/unix/sysv/linux/arm/ftruncate64.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/getcontext.S: Move to ... + * sysdeps/unix/sysv/linux/arm/getcontext.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S: Move to ... + * sysdeps/unix/sysv/linux/arm/internal_accept4.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/internal_recvmmsg.S: Move to ... + * sysdeps/unix/sysv/linux/arm/internal_recvmmsg.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/internal_sendmmsg.S: Move to ... + * sysdeps/unix/sysv/linux/arm/internal_sendmmsg.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S: Move to ... + * sysdeps/unix/sysv/linux/arm/libc-do-syscall.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/makecontext.c: Move to ... + * sysdeps/unix/sysv/linux/arm/makecontext.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/mmap64.S: Move to ... + * sysdeps/unix/sysv/linux/arm/mmap64.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/msgctl.c: Move to ... + * sysdeps/unix/sysv/linux/arm/msgctl.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c: Move to ... + * sysdeps/unix/sysv/linux/arm/oldgetrlimit.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c: Move to ... + * sysdeps/unix/sysv/linux/arm/oldsetrlimit.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/pread.c: Move to ... + * sysdeps/unix/sysv/linux/arm/pread.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/pread64.c: Move to ... + * sysdeps/unix/sysv/linux/arm/pread64.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/pwrite.c: Move to ... + * sysdeps/unix/sysv/linux/arm/pwrite.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/pwrite64.c: Move to ... + * sysdeps/unix/sysv/linux/arm/pwrite64.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/readahead.c: Move to ... + * sysdeps/unix/sysv/linux/arm/readahead.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/semctl.c: Move to ... + * sysdeps/unix/sysv/linux/arm/semctl.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/setcontext.S: Move to ... + * sysdeps/unix/sysv/linux/arm/setcontext.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/shmctl.c: Move to ... + * sysdeps/unix/sysv/linux/arm/shmctl.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/sigrestorer.S: Move to ... + * sysdeps/unix/sysv/linux/arm/sigrestorer.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/swapcontext.S: Move to ... + * sysdeps/unix/sysv/linux/arm/swapcontext.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/syscall.S: Move to ... + * sysdeps/unix/sysv/linux/arm/syscall.S: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/truncate64.c: Move to ... + * sysdeps/unix/sysv/linux/arm/truncate64.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/umount.c: Move to ... + * sysdeps/unix/sysv/linux/arm/umount.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/Makefile: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/configure.in: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/configure: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/configure: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c: + Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/nptl-aeabi_unwind_cpp_pr1.c: + ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c: + Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/rt-aeabi_unwind_cpp_pr1.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c: + Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/unwind-forcedunwind.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-resume.c: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/unwind-resume.c: ... here. + * sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h: Move to ... + * sysdeps/unix/sysv/linux/arm/nptl/unwind.h: ... here. + 2012-04-16 Andreas Jaeger * sysdeps/unix/sysv/linux/arm/ldsodefs.h: Undefine diff --git a/ChangeLog.mips b/ChangeLog.mips index 01f51c0c40..6e0523de80 100644 --- a/ChangeLog.mips +++ b/ChangeLog.mips @@ -1,3 +1,9 @@ +2012-04-21 Joseph Myers + + * sysdeps/unix/sysv/linux/mips/mips32/readahead.c: Include + sysdeps/unix/sysv/linux/arm/readahead.c not + sysdeps/unix/sysv/linux/arm/eabi/readahead.c. + 2012-03-28 Joseph Myers * sysdeps/unix/sysv/linux/mips/bits/mman.h (MAP_STACK): Define. diff --git a/sysdeps/unix/sysv/linux/arm/Makefile b/sysdeps/unix/sysv/linux/arm/Makefile index a9817368a1..fb1e3a5b99 100644 --- a/sysdeps/unix/sysv/linux/arm/Makefile +++ b/sysdeps/unix/sysv/linux/arm/Makefile @@ -1,4 +1,9 @@ ifeq ($(subdir),csu) +# In order for unwinding to fail when it falls out of main, we need a +# cantunwind marker. There's one in start.S. To make sure we reach it, add +# unwind tables for __libc_start_main. +CFLAGS-libc-start.c += -fexceptions + sysdep_routines += aeabi_read_tp libc-aeabi_read_tp static-only-routines += aeabi_read_tp shared-only-routines += libc-aeabi_read_tp @@ -24,3 +29,39 @@ endif ifeq ($(subdir),stdlib) gen-as-const-headers += ucontext_i.sym endif + +# Add a syscall function to each library that needs one. + +ifeq ($(subdir),rt) +librt-sysdep_routines += libc-do-syscall +librt-shared-only-routines += libc-do-syscall +endif + +ifeq ($(subdir),nptl) +libpthread-sysdep_routines += libc-do-syscall +libpthread-shared-only-routines += libc-do-syscall +endif + +ifeq ($(subdir),resolv) +libanl-sysdep_routines += libc-do-syscall +libanl-shared-only-routines += libc-do-syscall +endif + +ifeq ($(subdir),csu) +sysdep_routines += libc-do-syscall +endif + +ifeq ($(subdir),nscd) +nscd-modules += libc-do-syscall +endif + +ifeq ($(subdir),nss) +libnss_db-sysdep_routines += libc-do-syscall +libnss_db-shared-only-routines += libc-do-syscall +endif + +ifeq ($(subdir),posix) +LDFLAGS-tst-rfc3484 += $(common-objpfx)csu/libc-do-syscall.o +LDFLAGS-tst-rfc3484-2 += $(common-objpfx)csu/libc-do-syscall.o +LDFLAGS-tst-rfc3484-3 += $(common-objpfx)csu/libc-do-syscall.o +endif diff --git a/sysdeps/unix/sysv/linux/arm/____longjmp_chk.S b/sysdeps/unix/sysv/linux/arm/____longjmp_chk.S new file mode 100644 index 0000000000..8ec41521ca --- /dev/null +++ b/sysdeps/unix/sysv/linux/arm/____longjmp_chk.S @@ -0,0 +1,90 @@ +/* Copyright (C) 2009 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library. If not, see + . */ + +#include + + .section .rodata.str1.1,"aMS",%progbits,1 + .type longjmp_msg,%object +longjmp_msg: + .string "longjmp causes uninitialized stack frame" + .size longjmp_msg, .-longjmp_msg + .text + +#define __longjmp ____longjmp_chk + +#ifdef PIC +# define CALL_FAIL \ + ldr sl, .L_GOT; \ + cfi_undefined (sl); \ +.L_GOT_OFF: \ + add sl, pc, sl; \ + ldr r0, .Lstr; \ + add r0, sl, r0; \ + B PLTJMP(HIDDEN_JUMPTARGET(__fortify_fail)); \ +.L_GOT: \ + .word _GLOBAL_OFFSET_TABLE_-(.L_GOT_OFF+8); \ +.Lstr: \ + .word longjmp_msg(GOTOFF); +#else +# define CALL_FAIL \ + ldr r0, .Lstr; \ + B HIDDEN_JUMPTARGET(__fortify_fail); \ +.Lstr: \ + .word longjmp_msg; +#endif + +#define CHECK_SP(reg) \ + cfi_remember_state; \ + cmp sp, reg; \ + bls .Lok; \ + str r7, [sp, #-4]!; \ + cfi_adjust_cfa_offset (4); \ + cfi_rel_offset (r7, 0); \ + mov r5, r0; \ + cfi_undefined (r5); \ + mov r7, #SYS_ify(sigaltstack); \ + mov r0, #0; \ + sub sp, sp, #12; /* == sizeof (stack_t) */ \ + cfi_adjust_cfa_offset (12); \ + cfi_remember_state; \ + mov r1, sp; \ + swi #0; \ + cmp r0, #0; \ + bne .Lok2; \ + ldr r1, [sp, #4]; \ + tst r1, #1; \ + beq .Lfail; \ + ldr r2, [sp, #0]; \ + ldr r3, [sp, #8]; \ + add r2, r2, r3; \ + sub r2, r2, reg; \ + cmp r2, r3; \ + bhi .Lok2; \ +.Lfail: \ + add sp, sp, #12; \ + cfi_adjust_cfa_offset (-12); \ + ldr r7, [sp], #4; \ + cfi_adjust_cfa_offset (-4); \ + cfi_restore (r7); \ + CALL_FAIL \ + cfi_restore_state; \ +.Lok2: \ + mov r0, r5; \ + cfi_restore_state; \ +.Lok: + +#include <__longjmp.S> diff --git a/sysdeps/unix/sysv/linux/arm/configure b/sysdeps/unix/sysv/linux/arm/configure new file mode 100644 index 0000000000..5b5f4c993a --- /dev/null +++ b/sysdeps/unix/sysv/linux/arm/configure @@ -0,0 +1,6 @@ +# This file is generated from configure.in by Autoconf. DO NOT EDIT! + # Local configure fragment for sysdeps/unix/sysv/linux/arm. + +arch_minimum_kernel=2.6.16 +libc_cv_gcc_unwind_find_fde=no +CFLAGS=${CFLAGS% -fno-unwind-tables} diff --git a/sysdeps/unix/sysv/linux/arm/configure.in b/sysdeps/unix/sysv/linux/arm/configure.in new file mode 100644 index 0000000000..b57c4e37b8 --- /dev/null +++ b/sysdeps/unix/sysv/linux/arm/configure.in @@ -0,0 +1,6 @@ +GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. +# Local configure fragment for sysdeps/unix/sysv/linux/arm. + +arch_minimum_kernel=2.6.16 +libc_cv_gcc_unwind_find_fde=no +CFLAGS=${CFLAGS% -fno-unwind-tables} diff --git a/sysdeps/unix/sysv/linux/arm/eabi/Makefile b/sysdeps/unix/sysv/linux/arm/eabi/Makefile deleted file mode 100644 index b7baae9e91..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/Makefile +++ /dev/null @@ -1,42 +0,0 @@ -ifeq ($(subdir),csu) -# In order for unwinding to fail when it falls out of main, we need a -# cantunwind marker. There's one in start.S. To make sure we reach it, add -# unwind tables for __libc_start_main. -CFLAGS-libc-start.c += -fexceptions -endif - -# Add a syscall function to each library that needs one. - -ifeq ($(subdir),rt) -librt-sysdep_routines += libc-do-syscall -librt-shared-only-routines += libc-do-syscall -endif - -ifeq ($(subdir),nptl) -libpthread-sysdep_routines += libc-do-syscall -libpthread-shared-only-routines += libc-do-syscall -endif - -ifeq ($(subdir),resolv) -libanl-sysdep_routines += libc-do-syscall -libanl-shared-only-routines += libc-do-syscall -endif - -ifeq ($(subdir),csu) -sysdep_routines += libc-do-syscall -endif - -ifeq ($(subdir),nscd) -nscd-modules += libc-do-syscall -endif - -ifeq ($(subdir),nss) -libnss_db-sysdep_routines += libc-do-syscall -libnss_db-shared-only-routines += libc-do-syscall -endif - -ifeq ($(subdir),posix) -LDFLAGS-tst-rfc3484 += $(common-objpfx)csu/libc-do-syscall.o -LDFLAGS-tst-rfc3484-2 += $(common-objpfx)csu/libc-do-syscall.o -LDFLAGS-tst-rfc3484-3 += $(common-objpfx)csu/libc-do-syscall.o -endif diff --git a/sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S b/sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S deleted file mode 100644 index 8ec41521ca..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S +++ /dev/null @@ -1,90 +0,0 @@ -/* Copyright (C) 2009 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include - - .section .rodata.str1.1,"aMS",%progbits,1 - .type longjmp_msg,%object -longjmp_msg: - .string "longjmp causes uninitialized stack frame" - .size longjmp_msg, .-longjmp_msg - .text - -#define __longjmp ____longjmp_chk - -#ifdef PIC -# define CALL_FAIL \ - ldr sl, .L_GOT; \ - cfi_undefined (sl); \ -.L_GOT_OFF: \ - add sl, pc, sl; \ - ldr r0, .Lstr; \ - add r0, sl, r0; \ - B PLTJMP(HIDDEN_JUMPTARGET(__fortify_fail)); \ -.L_GOT: \ - .word _GLOBAL_OFFSET_TABLE_-(.L_GOT_OFF+8); \ -.Lstr: \ - .word longjmp_msg(GOTOFF); -#else -# define CALL_FAIL \ - ldr r0, .Lstr; \ - B HIDDEN_JUMPTARGET(__fortify_fail); \ -.Lstr: \ - .word longjmp_msg; -#endif - -#define CHECK_SP(reg) \ - cfi_remember_state; \ - cmp sp, reg; \ - bls .Lok; \ - str r7, [sp, #-4]!; \ - cfi_adjust_cfa_offset (4); \ - cfi_rel_offset (r7, 0); \ - mov r5, r0; \ - cfi_undefined (r5); \ - mov r7, #SYS_ify(sigaltstack); \ - mov r0, #0; \ - sub sp, sp, #12; /* == sizeof (stack_t) */ \ - cfi_adjust_cfa_offset (12); \ - cfi_remember_state; \ - mov r1, sp; \ - swi #0; \ - cmp r0, #0; \ - bne .Lok2; \ - ldr r1, [sp, #4]; \ - tst r1, #1; \ - beq .Lfail; \ - ldr r2, [sp, #0]; \ - ldr r3, [sp, #8]; \ - add r2, r2, r3; \ - sub r2, r2, reg; \ - cmp r2, r3; \ - bhi .Lok2; \ -.Lfail: \ - add sp, sp, #12; \ - cfi_adjust_cfa_offset (-12); \ - ldr r7, [sp], #4; \ - cfi_adjust_cfa_offset (-4); \ - cfi_restore (r7); \ - CALL_FAIL \ - cfi_restore_state; \ -.Lok2: \ - mov r0, r5; \ - cfi_restore_state; \ -.Lok: - -#include <__longjmp.S> diff --git a/sysdeps/unix/sysv/linux/arm/eabi/configure b/sysdeps/unix/sysv/linux/arm/eabi/configure deleted file mode 100644 index c7e20cfdc5..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/configure +++ /dev/null @@ -1,6 +0,0 @@ -# This file is generated from configure.in by Autoconf. DO NOT EDIT! - # Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi. - -arch_minimum_kernel=2.6.16 -libc_cv_gcc_unwind_find_fde=no -CFLAGS=${CFLAGS% -fno-unwind-tables} diff --git a/sysdeps/unix/sysv/linux/arm/eabi/configure.in b/sysdeps/unix/sysv/linux/arm/eabi/configure.in deleted file mode 100644 index cc0e9b5bd3..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/configure.in +++ /dev/null @@ -1,6 +0,0 @@ -GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. -# Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi. - -arch_minimum_kernel=2.6.16 -libc_cv_gcc_unwind_find_fde=no -CFLAGS=${CFLAGS% -fno-unwind-tables} diff --git a/sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c b/sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c deleted file mode 100644 index ad5eb186c2..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/ftruncate64.c +++ /dev/null @@ -1,76 +0,0 @@ -/* Copyright (C) 1997,1998,1999,2000,2001,2003, 2005 - Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include -#include -#include -#include - -#include -#include - -#include "kernel-features.h" - -#ifdef __NR_ftruncate64 -#ifndef __ASSUME_TRUNCATE64_SYSCALL -/* The variable is shared between all wrappers around *truncate64 calls. */ -extern int __have_no_truncate64; -#endif - - -/* Truncate the file FD refers to to LENGTH bytes. */ -int -__ftruncate64 (int fd, off64_t length) -{ -#ifndef __ASSUME_TRUNCATE64_SYSCALL - if (! __have_no_truncate64) -#endif - { - unsigned int low = length & 0xffffffff; - unsigned int high = length >> 32; -#ifndef __ASSUME_TRUNCATE64_SYSCALL - int saved_errno = errno; -#endif - int result = INLINE_SYSCALL (ftruncate64, 4, fd, 0, - __LONG_LONG_PAIR (high, low)); -#ifndef __ASSUME_TRUNCATE64_SYSCALL - if (result != -1 || errno != ENOSYS) -#endif - return result; - -#ifndef __ASSUME_TRUNCATE64_SYSCALL - __set_errno (saved_errno); - __have_no_truncate64 = 1; -#endif - } - -#ifndef __ASSUME_TRUNCATE64_SYSCALL - if ((off_t) length != length) - { - __set_errno (EINVAL); - return -1; - } - return __ftruncate (fd, (off_t) length); -#endif -} -weak_alias (__ftruncate64, ftruncate64) - -#else -/* Use the generic implementation. */ -# include -#endif diff --git a/sysdeps/unix/sysv/linux/arm/eabi/getcontext.S b/sysdeps/unix/sysv/linux/arm/eabi/getcontext.S deleted file mode 100644 index 435eb12c8f..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/getcontext.S +++ /dev/null @@ -1,113 +0,0 @@ -/* Copyright (C) 2012 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, see - . */ - -#include -#include - -#include "ucontext_i.h" - - .syntax unified - .text - -/* int getcontext (ucontext_t *ucp) */ - -ENTRY(__getcontext) - /* No need to save r0-r3, d0-d7, or d16-d31. */ - add r1, r0, #MCONTEXT_ARM_R4 - stmia r1, {r4-r11} - - /* Save R13 separately as Thumb can't STM it. */ - str r13, [r0, #MCONTEXT_ARM_SP] - str r14, [r0, #MCONTEXT_ARM_LR] - /* Return to LR */ - str r14, [r0, #MCONTEXT_ARM_PC] - /* Return zero */ - mov r2, #0 - str r2, [r0, #MCONTEXT_ARM_R0] - - /* Save ucontext_t * across the next call. */ - mov r4, r0 - - /* __sigprocmask(SIG_BLOCK, NULL, &(ucontext->uc_sigmask)) */ - mov r0, #SIG_BLOCK - mov r1, #0 - add r2, r4, #UCONTEXT_SIGMASK - bl PLTJMP(__sigprocmask) - - /* Store FP regs. Much of the FP code is copied from arm/eabi/setjmp.S. */ - -#ifdef PIC - ldr r2, 1f - ldr r1, Lrtld_global_ro -0: add r2, pc, r2 - ldr r2, [r2, r1] - ldr r2, [r2, #RTLD_GLOBAL_RO_DL_HWCAP_OFFSET] -#else - ldr r2, Lhwcap - ldr r2, [r2, #0] -#endif - - add r0, r4, #UCONTEXT_REGSPACE - - tst r2, #HWCAP_ARM_VFP - beq Lno_vfp - - /* Store the VFP registers. - Don't use VFP instructions directly because this code - is used in non-VFP multilibs. */ - /* Following instruction is vstmia r0!, {d8-d15}. */ - stc p11, cr8, [r0], #64 - /* Store the floating-point status register. */ - /* Following instruction is vmrs r1, fpscr. */ - mrc p10, 7, r1, cr1, cr0, 0 - str r1, [r0], #4 -Lno_vfp: - - tst r2, #HWCAP_ARM_IWMMXT - beq Lno_iwmmxt - - /* Save the call-preserved iWMMXt registers. */ - /* Following instructions are wstrd wr10, [r0], #8 (etc.) */ - stcl p1, cr10, [r0], #8 - stcl p1, cr11, [r0], #8 - stcl p1, cr12, [r0], #8 - stcl p1, cr13, [r0], #8 - stcl p1, cr14, [r0], #8 - stcl p1, cr15, [r0], #8 -Lno_iwmmxt: - - /* Restore the clobbered R4 and LR. */ - ldr r14, [r4, #MCONTEXT_ARM_LR] - ldr r4, [r4, #MCONTEXT_ARM_R4] - - mov r0, #0 - - DO_RET(r14) - -END(__getcontext) - -#ifdef PIC -1: .long _GLOBAL_OFFSET_TABLE_ - 0b - 8 -Lrtld_global_ro: - .long C_SYMBOL_NAME(_rtld_global_ro)(GOT) -#else -Lhwcap: - .long C_SYMBOL_NAME(_dl_hwcap) -#endif - - -weak_alias(__getcontext, getcontext) diff --git a/sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S b/sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S deleted file mode 100644 index eeb5f50a26..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S +++ /dev/null @@ -1,6 +0,0 @@ -/* Tag_ABI_align8_preserved: This code preserves 8-byte - alignment in any callee. */ - .eabi_attribute 25, 1 -/* Tag_ABI_align8_needed: This code may require 8-byte alignment from - the caller. */ - .eabi_attribute 24, 1 diff --git a/sysdeps/unix/sysv/linux/arm/eabi/internal_recvmmsg.S b/sysdeps/unix/sysv/linux/arm/eabi/internal_recvmmsg.S deleted file mode 100644 index eeb5f50a26..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/internal_recvmmsg.S +++ /dev/null @@ -1,6 +0,0 @@ -/* Tag_ABI_align8_preserved: This code preserves 8-byte - alignment in any callee. */ - .eabi_attribute 25, 1 -/* Tag_ABI_align8_needed: This code may require 8-byte alignment from - the caller. */ - .eabi_attribute 24, 1 diff --git a/sysdeps/unix/sysv/linux/arm/eabi/internal_sendmmsg.S b/sysdeps/unix/sysv/linux/arm/eabi/internal_sendmmsg.S deleted file mode 100644 index eeb5f50a26..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/internal_sendmmsg.S +++ /dev/null @@ -1,6 +0,0 @@ -/* Tag_ABI_align8_preserved: This code preserves 8-byte - alignment in any callee. */ - .eabi_attribute 25, 1 -/* Tag_ABI_align8_needed: This code may require 8-byte alignment from - the caller. */ - .eabi_attribute 24, 1 diff --git a/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S b/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S deleted file mode 100644 index 0ec81734f8..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S +++ /dev/null @@ -1,48 +0,0 @@ -/* Copyright (C) 2010-2012 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include - -/* Out-of-line syscall stub. We expect the system call number in ip - and return the raw result in r0. No registers are clobbered. - We could avoid using the stack for this, but the goal is accurate - unwind information - and while there is a reserved prefix in the - ARM unwind tables for register to register moves, the actual opcodes - are not defined. */ - -#if defined(__thumb__) - .thumb - .syntax unified - .hidden __libc_do_syscall - -#undef CALL_MCOUNT -#define CALL_MCOUNT - -ENTRY (__libc_do_syscall) - .fnstart - push {r7, lr} - .save {r7, lr} - cfi_adjust_cfa_offset (8) - cfi_rel_offset (r7, 0) - cfi_rel_offset (lr, 4) - mov r7, ip - swi 0x0 - pop {r7, pc} - .fnend -END (__libc_do_syscall) - -#endif /* __thumb__ */ diff --git a/sysdeps/unix/sysv/linux/arm/eabi/makecontext.c b/sysdeps/unix/sysv/linux/arm/eabi/makecontext.c deleted file mode 100644 index d6ae6f0d76..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/makecontext.c +++ /dev/null @@ -1,73 +0,0 @@ -/* Copyright (C) 2012 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, see - . */ - -#include -#include - -/* Number of arguments that go in registers. */ -#define NREG_ARGS 4 - -/* Take a context previously prepared via getcontext() and set to - call func() with the given int only args. */ -void -__makecontext (ucontext_t *ucp, void (*func) (void), int argc, ...) -{ - extern void __startcontext (void); - unsigned long *funcstack; - va_list vl; - unsigned long *regptr; - unsigned int reg; - int misaligned; - - /* Start at the top of stack. */ - funcstack = (unsigned long *) (ucp->uc_stack.ss_sp + ucp->uc_stack.ss_size); - - /* Ensure the stack stays eight byte aligned. */ - misaligned = ((unsigned long) funcstack & 4) != 0; - - if ((argc > NREG_ARGS) && (argc & 1) != 0) - misaligned = !misaligned; - - if (misaligned) - funcstack -= 1; - - va_start (vl, argc); - - /* Reserve space for the on-stack arguments. */ - if (argc > NREG_ARGS) - funcstack -= (argc - NREG_ARGS); - - ucp->uc_mcontext.arm_sp = (unsigned long) funcstack; - ucp->uc_mcontext.arm_pc = (unsigned long) func; - - /* Exit to startcontext() with the next context in R4 */ - ucp->uc_mcontext.arm_r4 = (unsigned long) ucp->uc_link; - ucp->uc_mcontext.arm_lr = (unsigned long) __startcontext; - - /* The first four arguments go into registers. */ - regptr = &(ucp->uc_mcontext.arm_r0); - - for (reg = 0; (reg < argc) && (reg < NREG_ARGS); reg++) - *regptr++ = va_arg (vl, unsigned long); - - /* And the remainder on the stack. */ - for (; reg < argc; reg++) - *funcstack++ = va_arg (vl, unsigned long); - - va_end (vl); -} -weak_alias (__makecontext, makecontext) diff --git a/sysdeps/unix/sysv/linux/arm/eabi/mmap64.S b/sysdeps/unix/sysv/linux/arm/eabi/mmap64.S deleted file mode 100644 index be4dd52de4..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/mmap64.S +++ /dev/null @@ -1,68 +0,0 @@ -/* Copyright (C) 2000, 2003, 2005, 2009 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include - -#define EINVAL 22 - -#ifdef __ARMEB__ -# define LOW_OFFSET 8 + 4 -/* The initial + 4 is for the stack postdecrement. */ -# define HIGH_OFFSET 4 + 8 + 0 -#else -# define LOW_OFFSET 8 + 0 -# define HIGH_OFFSET 4 + 8 + 4 -#endif - - /* The mmap2 system call takes six arguments, all in registers. */ - .text -ENTRY (__mmap64) - ldr ip, [sp, $LOW_OFFSET] - str r5, [sp, #-4]! - cfi_adjust_cfa_offset (4) - cfi_rel_offset (r5, 0) - ldr r5, [sp, $HIGH_OFFSET] - str r4, [sp, #-4]! - cfi_adjust_cfa_offset (4) - cfi_rel_offset (r4, 0) - cfi_remember_state - movs r4, ip, lsl $20 @ check that offset is page-aligned - mov ip, ip, lsr $12 - moveqs r4, r5, lsr $12 @ check for overflow - bne .Linval - ldr r4, [sp, $8] @ load fd - orr r5, ip, r5, lsl $20 @ compose page offset - DO_CALL (mmap2, 0) - cmn r0, $4096 - ldmfd sp!, {r4, r5} - cfi_adjust_cfa_offset (-8) - cfi_restore (r4) - cfi_restore (r5) - RETINSTR(cc, lr) - b PLTJMP(syscall_error) - - cfi_restore_state -.Linval: - mov r0, $-EINVAL - ldmfd sp!, {r4, r5} - cfi_adjust_cfa_offset (-8) - cfi_restore (r4) - cfi_restore (r5) - b PLTJMP(syscall_error) -PSEUDO_END (__mmap64) - -weak_alias (__mmap64, mmap64) diff --git a/sysdeps/unix/sysv/linux/arm/eabi/msgctl.c b/sysdeps/unix/sysv/linux/arm/eabi/msgctl.c deleted file mode 100644 index 38aedadf49..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/msgctl.c +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile b/sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile deleted file mode 100644 index ef8076cf3f..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/Makefile +++ /dev/null @@ -1,17 +0,0 @@ -ifeq ($(subdir),rt) -librt-sysdep_routines += rt-aeabi_unwind_cpp_pr1 -librt-shared-only-routines += rt-aeabi_unwind_cpp_pr1 -endif - -ifeq ($(subdir),nptl) -libpthread-sysdep_routines += nptl-aeabi_unwind_cpp_pr1 -libpthread-shared-only-routines += nptl-aeabi_unwind_cpp_pr1 - -# This test relies on compiling part of the binary with EH information, -# part without, and unwinding through. The .ARM.exidx tables have -# start addresses for EH regions, but no end addresses. Every -# region an exception needs to propogate through must have unwind -# information, or a previous function's unwind table may be used -# by mistake. -tests := $(filter-out tst-cleanupx4,$(tests)) -endif diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure b/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure deleted file mode 100644 index 518269913a..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure +++ /dev/null @@ -1,4 +0,0 @@ -# This file is generated from configure.in by Autoconf. DO NOT EDIT! - -libc_cv_gcc_exceptions=yes -exceptions=-fexceptions diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in b/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in deleted file mode 100644 index 22f6f4b8f2..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/configure.in +++ /dev/null @@ -1,8 +0,0 @@ -dnl configure fragment for NPTL and ARM/Linux EABI. -GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. - -dnl The normal configure check for gcc -fexecptions fails because it can't -dnl find __aeabi_unwind_cpp_pr0. Work around this here; our GCC definitely -dnl has -fexceptions. -libc_cv_gcc_exceptions=yes -exceptions=-fexceptions diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c b/sysdeps/unix/sysv/linux/arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c deleted file mode 100644 index 7b83522437..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/nptl-aeabi_unwind_cpp_pr1.c +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c b/sysdeps/unix/sysv/linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c deleted file mode 100644 index 7b83522437..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/rt-aeabi_unwind_cpp_pr1.c +++ /dev/null @@ -1 +0,0 @@ -#include diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h b/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h deleted file mode 100644 index c26bec3dca..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h +++ /dev/null @@ -1,251 +0,0 @@ -/* Copyright (C) 2003, 2004, 2005, 2009 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include -#include -#ifndef __ASSEMBLER__ -# include -#endif - -#if !defined NOT_IN_libc || defined IS_IN_libpthread || defined IS_IN_librt - -/* NOTE: We do mark syscalls with unwind annotations, for the benefit of - cancellation; but they're really only accurate at the point of the - syscall. The ARM unwind directives are not rich enough without adding - a custom personality function. */ - -# undef PSEUDO -# define PSEUDO(name, syscall_name, args) \ - .section ".text"; \ - PSEUDO_PROLOGUE; \ - .type __##syscall_name##_nocancel,%function; \ - .globl __##syscall_name##_nocancel; \ - __##syscall_name##_nocancel: \ - .cfi_sections .debug_frame; \ - cfi_startproc; \ - DO_CALL (syscall_name, args); \ - cmn r0, $4096; \ - PSEUDO_RET; \ - cfi_endproc; \ - .size __##syscall_name##_nocancel,.-__##syscall_name##_nocancel; \ - ENTRY (name); \ - SINGLE_THREAD_P; \ - DOARGS_##args; \ - bne .Lpseudo_cancel; \ - cfi_remember_state; \ - ldr r7, =SYS_ify (syscall_name); \ - swi 0x0; \ - UNDOARGS_##args; \ - cmn r0, $4096; \ - PSEUDO_RET; \ - cfi_restore_state; \ - .Lpseudo_cancel: \ - .fnstart; /* matched by the .fnend in UNDOARGS below. */ \ - DOCARGS_##args; /* save syscall args etc. around CENABLE. */ \ - CENABLE; \ - mov ip, r0; /* put mask in safe place. */ \ - UNDOCARGS_##args; /* restore syscall args. */ \ - ldr r7, =SYS_ify (syscall_name); \ - swi 0x0; /* do the call. */ \ - mov r7, r0; /* save syscall return value. */ \ - mov r0, ip; /* get mask back. */ \ - CDISABLE; \ - mov r0, r7; /* retrieve return value. */ \ - RESTORE_LR_##args; \ - UNDOARGS_##args; \ - cmn r0, $4096 - -/* DOARGS pushes eight bytes on the stack for five arguments, twelve bytes for - six arguments, and four bytes for fewer. In order to preserve doubleword - alignment, sometimes we must save an extra register. */ - -# define RESTART_UNWIND \ - .fnend; \ - .fnstart; \ - .save {r7}; \ - .save {lr} - -# define DOCARGS_0 \ - .save {r7}; \ - str lr, [sp, #-4]!; \ - cfi_adjust_cfa_offset (4); \ - cfi_rel_offset (lr, 0); \ - .save {lr} -# define UNDOCARGS_0 -# define RESTORE_LR_0 \ - ldr lr, [sp], #4; \ - cfi_adjust_cfa_offset (-4); \ - cfi_restore (lr) - -# define DOCARGS_1 \ - .save {r7}; \ - stmfd sp!, {r0, r1, lr}; \ - cfi_adjust_cfa_offset (12); \ - cfi_rel_offset (lr, 8); \ - .save {lr}; \ - .pad #8 -# define UNDOCARGS_1 \ - ldr r0, [sp], #8; \ - cfi_adjust_cfa_offset (-8); \ - RESTART_UNWIND -# define RESTORE_LR_1 \ - RESTORE_LR_0 - -# define DOCARGS_2 \ - .save {r7}; \ - stmfd sp!, {r0, r1, lr}; \ - cfi_adjust_cfa_offset (12); \ - cfi_rel_offset (lr, 8); \ - .save {lr}; \ - .pad #8 -# define UNDOCARGS_2 \ - ldmfd sp!, {r0, r1}; \ - cfi_adjust_cfa_offset (-8); \ - RESTART_UNWIND -# define RESTORE_LR_2 \ - RESTORE_LR_0 - -# define DOCARGS_3 \ - .save {r7}; \ - stmfd sp!, {r0, r1, r2, r3, lr}; \ - cfi_adjust_cfa_offset (20); \ - cfi_rel_offset (lr, 16); \ - .save {lr}; \ - .pad #16 -# define UNDOCARGS_3 \ - ldmfd sp!, {r0, r1, r2, r3}; \ - cfi_adjust_cfa_offset (-16); \ - RESTART_UNWIND -# define RESTORE_LR_3 \ - RESTORE_LR_0 - -# define DOCARGS_4 \ - .save {r7}; \ - stmfd sp!, {r0, r1, r2, r3, lr}; \ - cfi_adjust_cfa_offset (20); \ - cfi_rel_offset (lr, 16); \ - .save {lr}; \ - .pad #16 -# define UNDOCARGS_4 \ - ldmfd sp!, {r0, r1, r2, r3}; \ - cfi_adjust_cfa_offset (-16); \ - RESTART_UNWIND -# define RESTORE_LR_4 \ - RESTORE_LR_0 - -/* r4 is only stmfd'ed for correct stack alignment. */ -# define DOCARGS_5 \ - .save {r4, r7}; \ - stmfd sp!, {r0, r1, r2, r3, r4, lr}; \ - cfi_adjust_cfa_offset (24); \ - cfi_rel_offset (lr, 20); \ - .save {lr}; \ - .pad #20 -# define UNDOCARGS_5 \ - ldmfd sp!, {r0, r1, r2, r3}; \ - cfi_adjust_cfa_offset (-16); \ - .fnend; \ - .fnstart; \ - .save {r4, r7}; \ - .save {lr}; \ - .pad #4 -# define RESTORE_LR_5 \ - ldmfd sp!, {r4, lr}; \ - cfi_adjust_cfa_offset (-8); \ - /* r4 will be marked as restored later. */ \ - cfi_restore (lr) - -# define DOCARGS_6 \ - .save {r4, r5, r7}; \ - stmfd sp!, {r0, r1, r2, r3, lr}; \ - cfi_adjust_cfa_offset (20); \ - cfi_rel_offset (lr, 16); \ - .save {lr}; \ - .pad #16 -# define UNDOCARGS_6 \ - ldmfd sp!, {r0, r1, r2, r3}; \ - cfi_adjust_cfa_offset (-16); \ - .fnend; \ - .fnstart; \ - .save {r4, r5, r7}; \ - .save {lr}; -# define RESTORE_LR_6 \ - RESTORE_LR_0 - -# ifdef IS_IN_libpthread -# define CENABLE bl PLTJMP(__pthread_enable_asynccancel) -# define CDISABLE bl PLTJMP(__pthread_disable_asynccancel) -# define __local_multiple_threads __pthread_multiple_threads -# elif !defined NOT_IN_libc -# define CENABLE bl PLTJMP(__libc_enable_asynccancel) -# define CDISABLE bl PLTJMP(__libc_disable_asynccancel) -# define __local_multiple_threads __libc_multiple_threads -# elif defined IS_IN_librt -# define CENABLE bl PLTJMP(__librt_enable_asynccancel) -# define CDISABLE bl PLTJMP(__librt_disable_asynccancel) -# else -# error Unsupported library -# endif - -# if defined IS_IN_libpthread || !defined NOT_IN_libc -# ifndef __ASSEMBLER__ -extern int __local_multiple_threads attribute_hidden; -# define SINGLE_THREAD_P __builtin_expect (__local_multiple_threads == 0, 1) -# else -# define SINGLE_THREAD_P \ - ldr ip, 1b; \ -2: \ - ldr ip, [pc, ip]; \ - teq ip, #0; -# define PSEUDO_PROLOGUE \ - 1: .word __local_multiple_threads - 2f - 8; -# endif -# else -/* There is no __local_multiple_threads for librt, so use the TCB. */ -# ifndef __ASSEMBLER__ -# define SINGLE_THREAD_P \ - __builtin_expect (THREAD_GETMEM (THREAD_SELF, \ - header.multiple_threads) == 0, 1) -# else -# define PSEUDO_PROLOGUE -# define SINGLE_THREAD_P \ - stmfd sp!, {r0, lr}; \ - cfi_adjust_cfa_offset (8); \ - cfi_rel_offset (lr, 4); \ - bl __aeabi_read_tp; \ - ldr ip, [r0, #MULTIPLE_THREADS_OFFSET]; \ - ldmfd sp!, {r0, lr}; \ - cfi_adjust_cfa_offset (-8); \ - cfi_restore (lr); \ - teq ip, #0 -# define SINGLE_THREAD_P_PIC(x) SINGLE_THREAD_P -# endif -# endif - -#elif !defined __ASSEMBLER__ - -/* For rtld, et cetera. */ -# define SINGLE_THREAD_P 1 -# define NO_CANCELLATION 1 - -#endif - -#ifndef __ASSEMBLER__ -# define RTLD_SINGLE_THREAD_P \ - __builtin_expect (THREAD_GETMEM (THREAD_SELF, \ - header.multiple_threads) == 0, 1) -#endif diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c b/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c deleted file mode 100644 index 29e2c2b00b..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-forcedunwind.c +++ /dev/null @@ -1,158 +0,0 @@ -/* Copyright (C) 2003, 2005, 2007, 2009, 2010 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Jakub Jelinek . - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public License as - published by the Free Software Foundation; either version 2.1 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include -#include -#include -#include - -static void *libgcc_s_handle; -static void (*libgcc_s_resume) (struct _Unwind_Exception *exc); -static _Unwind_Reason_Code (*libgcc_s_personality) - (_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *); -static _Unwind_Reason_Code (*libgcc_s_forcedunwind) - (struct _Unwind_Exception *, _Unwind_Stop_Fn, void *); -static _Unwind_Word (*libgcc_s_getcfa) (struct _Unwind_Context *); - -void -__attribute_noinline__ -pthread_cancel_init (void) -{ - void *resume, *personality, *forcedunwind, *getcfa; - void *handle; - - if (__builtin_expect (libgcc_s_handle != NULL, 1)) - { - /* Force gcc to reload all values. */ - asm volatile ("" ::: "memory"); - return; - } - - handle = __libc_dlopen ("libgcc_s.so.1"); - - if (handle == NULL - || (resume = __libc_dlsym (handle, "_Unwind_Resume")) == NULL - || (personality = __libc_dlsym (handle, "__gcc_personality_v0")) == NULL - || (forcedunwind = __libc_dlsym (handle, "_Unwind_ForcedUnwind")) - == NULL - || (getcfa = __libc_dlsym (handle, "_Unwind_GetCFA")) == NULL -#ifdef ARCH_CANCEL_INIT - || ARCH_CANCEL_INIT (handle) -#endif - ) - __libc_fatal ("libgcc_s.so.1 must be installed for pthread_cancel to work\n"); - - libgcc_s_resume = resume; - libgcc_s_personality = personality; - libgcc_s_forcedunwind = forcedunwind; - libgcc_s_getcfa = getcfa; - /* Make sure libgcc_s_getcfa is written last. Otherwise, - pthread_cancel_init might return early even when the pointer the - caller is interested in is not initialized yet. */ - atomic_write_barrier (); - libgcc_s_handle = handle; -} - -void -__libc_freeres_fn_section -__unwind_freeres (void) -{ - void *handle = libgcc_s_handle; - if (handle != NULL) - { - libgcc_s_handle = NULL; - __libc_dlclose (handle); - } -} - -/* It's vitally important that _Unwind_Resume not have a stack frame; the - ARM unwinder relies on register state at entrance. So we write this in - assembly. */ - -asm ( -" .globl _Unwind_Resume\n" -" .type _Unwind_Resume, %function\n" -"_Unwind_Resume:\n" -" .cfi_sections .debug_frame\n" -" " CFI_STARTPROC "\n" -" stmfd sp!, {r4, r5, r6, lr}\n" -" " CFI_ADJUST_CFA_OFFSET (16)" \n" -" " CFI_REL_OFFSET (r4, 0) "\n" -" " CFI_REL_OFFSET (r5, 4) "\n" -" " CFI_REL_OFFSET (r6, 8) "\n" -" " CFI_REL_OFFSET (lr, 12) "\n" -" " CFI_REMEMBER_STATE "\n" -" ldr r4, 1f\n" -" ldr r5, 2f\n" -"3: add r4, pc, r4\n" -" ldr r3, [r4, r5]\n" -" mov r6, r0\n" -" cmp r3, #0\n" -" beq 4f\n" -"5: mov r0, r6\n" -" ldmfd sp!, {r4, r5, r6, lr}\n" -" " CFI_ADJUST_CFA_OFFSET (-16) "\n" -" " CFI_RESTORE (r4) "\n" -" " CFI_RESTORE (r5) "\n" -" " CFI_RESTORE (r6) "\n" -" " CFI_RESTORE (lr) "\n" -" bx r3\n" -" " CFI_RESTORE_STATE "\n" -"4: bl pthread_cancel_init\n" -" ldr r3, [r4, r5]\n" -" b 5b\n" -" " CFI_ENDPROC "\n" -" .align 2\n" -#ifdef __thumb2__ -"1: .word _GLOBAL_OFFSET_TABLE_ - 3b - 4\n" -#else -"1: .word _GLOBAL_OFFSET_TABLE_ - 3b - 8\n" -#endif -"2: .word libgcc_s_resume(GOTOFF)\n" -" .size _Unwind_Resume, .-_Unwind_Resume\n" -); - -_Unwind_Reason_Code -__gcc_personality_v0 (_Unwind_State state, - struct _Unwind_Exception *ue_header, - struct _Unwind_Context *context) -{ - if (__builtin_expect (libgcc_s_personality == NULL, 0)) - pthread_cancel_init (); - - return libgcc_s_personality (state, ue_header, context); -} - -_Unwind_Reason_Code -_Unwind_ForcedUnwind (struct _Unwind_Exception *exc, _Unwind_Stop_Fn stop, - void *stop_argument) -{ - if (__builtin_expect (libgcc_s_forcedunwind == NULL, 0)) - pthread_cancel_init (); - - return libgcc_s_forcedunwind (exc, stop, stop_argument); -} - -_Unwind_Word -_Unwind_GetCFA (struct _Unwind_Context *context) -{ - if (__builtin_expect (libgcc_s_getcfa == NULL, 0)) - pthread_cancel_init (); - - return libgcc_s_getcfa (context); -} diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-resume.c b/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-resume.c deleted file mode 100644 index 285b99b5ed..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind-resume.c +++ /dev/null @@ -1,101 +0,0 @@ -/* Copyright (C) 2003, 2005, 2010 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Jakub Jelinek . - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public License as - published by the Free Software Foundation; either version 2.1 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library. If not, see - . */ - -#include -#include -#include - -static void (*libgcc_s_resume) (struct _Unwind_Exception *exc); -static _Unwind_Reason_Code (*libgcc_s_personality) - (_Unwind_State, struct _Unwind_Exception *, struct _Unwind_Context *); - -static void init (void) __attribute_used__; - -static void -init (void) -{ - void *resume, *personality; - void *handle; - - handle = __libc_dlopen ("libgcc_s.so.1"); - - if (handle == NULL - || (resume = __libc_dlsym (handle, "_Unwind_Resume")) == NULL - || (personality = __libc_dlsym (handle, "__gcc_personality_v0")) == NULL) - __libc_fatal ("libgcc_s.so.1 must be installed for pthread_cancel to work\n"); - - libgcc_s_resume = resume; - libgcc_s_personality = personality; -} - -/* It's vitally important that _Unwind_Resume not have a stack frame; the - ARM unwinder relies on register state at entrance. So we write this in - assembly. */ - -asm ( -" .globl _Unwind_Resume\n" -" .type _Unwind_Resume, %function\n" -"_Unwind_Resume:\n" -" .cfi_sections .debug_frame\n" -" " CFI_STARTPROC "\n" -" stmfd sp!, {r4, r5, r6, lr}\n" -" " CFI_ADJUST_CFA_OFFSET (16)" \n" -" " CFI_REL_OFFSET (r4, 0) "\n" -" " CFI_REL_OFFSET (r5, 4) "\n" -" " CFI_REL_OFFSET (r6, 8) "\n" -" " CFI_REL_OFFSET (lr, 12) "\n" -" " CFI_REMEMBER_STATE "\n" -" ldr r4, 1f\n" -" ldr r5, 2f\n" -"3: add r4, pc, r4\n" -" ldr r3, [r4, r5]\n" -" mov r6, r0\n" -" cmp r3, #0\n" -" beq 4f\n" -"5: mov r0, r6\n" -" ldmfd sp!, {r4, r5, r6, lr}\n" -" " CFI_ADJUST_CFA_OFFSET (-16) "\n" -" " CFI_RESTORE (r4) "\n" -" " CFI_RESTORE (r5) "\n" -" " CFI_RESTORE (r6) "\n" -" " CFI_RESTORE (lr) "\n" -" bx r3\n" -" " CFI_RESTORE_STATE "\n" -"4: bl init\n" -" ldr r3, [r4, r5]\n" -" b 5b\n" -" " CFI_ENDPROC "\n" -" .align 2\n" -#ifdef __thumb2__ -"1: .word _GLOBAL_OFFSET_TABLE_ - 3b - 4\n" -#else -"1: .word _GLOBAL_OFFSET_TABLE_ - 3b - 8\n" -#endif -"2: .word libgcc_s_resume(GOTOFF)\n" -" .size _Unwind_Resume, .-_Unwind_Resume\n" -); - -_Unwind_Reason_Code -__gcc_personality_v0 (_Unwind_State state, - struct _Unwind_Exception *ue_header, - struct _Unwind_Context *context) -{ - if (__builtin_expect (libgcc_s_personality == NULL, 0)) - init (); - return libgcc_s_personality (state, ue_header, context); -} diff --git a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h b/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h deleted file mode 100644 index 9b6bed8e3c..0000000000 --- a/sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h +++ /dev/null @@ -1,278 +0,0 @@ -/* Header file for the ARM EABI unwinder - Copyright (C) 2003, 2004, 2005, 2009 Free Software Foundation, Inc. - Contributed by Paul Brook - - This file is free software; you can redistribute it and/or modify it - under the terms of the GNU General Public License as published by the - Free Software Foundation; either version 2, or (at your option) any - later version. - - In addition to the permissions in the GNU General Public License, the - Free Software Foundation gives you unlimited permission to link the - compiled version of this file into combinations with other programs, - and to distribute those combinations without any restriction coming - from the use of this file. (The General Public License restrictions - do apply in other respects; for example, they cover modification of - the file, and distribution when not linked into a combine - executable.) - - This file is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see - . */ - -/* Language-independent unwinder header public defines. This contains both - ABI defined objects, and GNU support routines. */ - -#ifndef UNWIND_ARM_H -#define UNWIND_ARM_H - -#define __ARM_EABI_UNWINDER__ 1 - -#ifdef __cplusplus -extern "C" { -#endif - typedef unsigned _Unwind_Word __attribute__((__mode__(__word__))); - typedef signed _Unwind_Sword __attribute__((__mode__(__word__))); - typedef unsigned _Unwind_Ptr __attribute__((__mode__(__pointer__))); - typedef unsigned _Unwind_Internal_Ptr __attribute__((__mode__(__pointer__))); - typedef _Unwind_Word _uw; - typedef unsigned _uw64 __attribute__((mode(__DI__))); - typedef unsigned _uw16 __attribute__((mode(__HI__))); - typedef unsigned _uw8 __attribute__((mode(__QI__))); - - typedef enum - { - _URC_OK = 0, /* operation completed successfully */ - _URC_FOREIGN_EXCEPTION_CAUGHT = 1, - _URC_END_OF_STACK = 5, - _URC_HANDLER_FOUND = 6, - _URC_INSTALL_CONTEXT = 7, - _URC_CONTINUE_UNWIND = 8, - _URC_FAILURE = 9 /* unspecified failure of some kind */ - } - _Unwind_Reason_Code; - - typedef enum - { - _US_VIRTUAL_UNWIND_FRAME = 0, - _US_UNWIND_FRAME_STARTING = 1, - _US_UNWIND_FRAME_RESUME = 2, - _US_ACTION_MASK = 3, - _US_FORCE_UNWIND = 8, - _US_END_OF_STACK = 16 - } - _Unwind_State; -