From 53362a4b0f8cb9bab0c23553b199e4a11ec7d4d7 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Thu, 1 Mar 2012 15:04:16 -0800 Subject: Remove sparc binutils GOTDATA checks in lieu of new minimum version requirement. * sysdeps/sparc/crti.S: Remove HAVE_BINUTILS_GOTDATA checks. * sysdeps/sparc/sparc32/dl-machine.h: Likewise. * sysdeps/sparc/sparc32/elf/start.S: Likewise. * sysdeps/sparc/sparc32/fpu/w_sqrt.S: Likewise. * sysdeps/sparc/sparc32/fpu/w_sqrtf.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/w_sqrt.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/w_sqrtf.S: Likewise. * sysdeps/sparc/sparc64/dl-machine.h: Likewise. * sysdeps/sparc/sparc64/elf/start.S: Likewise. * sysdeps/sparc/sparc64/fpu/w_sqrt.S: Likewise. * sysdeps/sparc/sparc64/fpu/w_sqrtf.S: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc32/____longjmp_chk.S: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc64/____longjmp_chk.S: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Likewise. * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise. * config.h.in (HAVE_BINUTILS_GOTDATA): Delete. * sysdeps/sparc/elf/configure.in: Remove binutils GOTDATA checks. * sysdeps/sparc/elf/configure: Regenerated. --- .../sysv/linux/sparc/sparc32/____longjmp_chk.S | 6 ----- sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h | 26 ++-------------------- .../sysv/linux/sparc/sparc64/____longjmp_chk.S | 6 ----- sysdeps/unix/sysv/linux/sparc/sparc64/brk.S | 12 ---------- sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h | 26 ++-------------------- 5 files changed, 4 insertions(+), 72 deletions(-) (limited to 'sysdeps/unix/sysv/linux/sparc') diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/____longjmp_chk.S b/sysdeps/unix/sysv/linux/sparc/sparc32/____longjmp_chk.S index 7246e89..0b3361b 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/____longjmp_chk.S +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/____longjmp_chk.S @@ -67,15 +67,9 @@ ENTRY (____longjmp_chk) or %o0, %lo(longjmp_msg), %o0 #else SETUP_PIC_REG(l7) -#ifdef HAVE_BINUTILS_GOTDATA sethi %gdop_hix22(longjmp_msg), %o0 xor %o0, %gdop_lox10(longjmp_msg), %o0 ld [%l7 + %o0], %o0, %gdop(longjmp_msg) -#else - sethi %hi(longjmp_msg), %o0 - or %o0, %lo(longjmp_msg), %o0 - ld [%l7 + %o0], %o0 -#endif #endif call HIDDEN_JUMPTARGET(__fortify_fail) nop diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h b/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h index 3d6042e..3424598 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h @@ -88,8 +88,7 @@ ENTRY(name); \ mov %g1, %o7; #else # if RTLD_PRIVATE_ERRNO -# ifdef HAVE_BINUTILS_GOTDATA -# define SYSCALL_ERROR_HANDLER \ +# define SYSCALL_ERROR_HANDLER \ 0: SETUP_PIC_REG_LEAF(o2,g1) \ sethi %gdop_hix22(rtld_errno), %g1; \ xor %g1, %gdop_lox10(rtld_errno), %g1;\ @@ -97,16 +96,6 @@ ENTRY(name); \ st %o0, [%g1]; \ jmp %o7 + 8; \ mov -1, %o0; -# else -# define SYSCALL_ERROR_HANDLER \ -0: SETUP_PIC_REG_LEAF(o2,g1) \ - sethi %hi(rtld_errno), %g1; \ - or %g1, %lo(rtld_errno), %g1; \ - ld [%o2 + %g1], %g1; \ - st %o0, [%g1]; \ - jmp %o7 + 8; \ - mov -1, %o0; -# endif # elif defined _LIBC_REENTRANT # ifndef NOT_IN_libc @@ -123,8 +112,7 @@ ENTRY(name); \ jmp %o7 + 8; \ mov -1, %o0; # else -# ifdef HAVE_BINUTILS_GOTDATA -# define SYSCALL_ERROR_HANDLER \ +# define SYSCALL_ERROR_HANDLER \ 0: SETUP_PIC_REG_LEAF(o2,g1) \ sethi %gdop_hix22(errno), %g1;\ xor %g1, %gdop_lox10(errno), %g1;\ @@ -132,16 +120,6 @@ ENTRY(name); \ st %o0, [%g1]; \ jmp %o7 + 8; \ mov -1, %o0; -# else -# define SYSCALL_ERROR_HANDLER \ -0: SETUP_PIC_REG_LEAF(o2,g1) \ - sethi %hi(errno), %g1; \ - or %g1, %lo(errno), %g1; \ - ld [%o2 + %g1], %g1; \ - st %o0, [%g1]; \ - jmp %o7 + 8; \ - mov -1, %o0; -# endif # endif /* _LIBC_REENTRANT */ #endif /* PIC */ diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/____longjmp_chk.S b/sysdeps/unix/sysv/linux/sparc/sparc64/____longjmp_chk.S index 69cf5ac..9b4e1e7 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/____longjmp_chk.S +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/____longjmp_chk.S @@ -67,15 +67,9 @@ ENTRY (____longjmp_chk) or %o0, %lo(longjmp_msg), %o0 #else SETUP_PIC_REG(l7) -#ifdef HAVE_BINUTILS_GOTDATA sethi %gdop_hix22(longjmp_msg), %o0 xor %o0, %gdop_lox10(longjmp_msg), %o0 ldx [%l7 + %o0], %o0, %gdop(longjmp_msg) -#else - sethi %hi(longjmp_msg), %o0 - or %o0, %lo(longjmp_msg), %o0 - ldx [%l7 + %o0], %o0 -#endif #endif call HIDDEN_JUMPTARGET(__fortify_fail) nop diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S b/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S index a89d877..14b2967 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S @@ -64,15 +64,9 @@ ENTRY (__brk) sethi %hi(__curbrk), %g1 or %g1, %lo(__curbrk), %g1 #else -#ifdef HAVE_BINUTILS_GOTDATA sethi %gdop_hix22(__curbrk), %g1 xor %g1, %gdop_lox10(__curbrk), %g1 ldx [%l7 + %g1], %g1, %gdop(__curbrk) -#else - sethi %hi(__curbrk), %g1 - or %g1, %lo(__curbrk), %g1 - ldx [%l7 + %g1], %g1 -#endif #endif stx %o0, [%g1] mov %g0, %i0 @@ -89,15 +83,9 @@ ENTRY (__brk) sethi %hi(errno), %g1 or %g1, %lo(errno), %g1 #else -#ifdef HAVE_BINUTILS_GOTDATA sethi %gdop_hix22(errno), %g1 xor %g1, %gdop_lox10(errno), %g1 ldx [%l7 + %g1], %g1, %gdop(errno) -#else - sethi %hi(errno), %g1 - or %g1, %lo(errno), %g1 - ldx [%l7 + %g1], %g1 -#endif #endif st %o0, [%g1] #else diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h b/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h index 33e1a41..1bf7597 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h @@ -95,8 +95,7 @@ ENTRY(name); \ mov %g1, %o7; #else # if RTLD_PRIVATE_ERRNO -# ifdef HAVE_BINUTILS_GOTDATA -# define SYSCALL_ERROR_HANDLER \ +# define SYSCALL_ERROR_HANDLER \ 0: SETUP_PIC_REG_LEAF(o2,g1) \ sethi %gdop_hix22(rtld_errno), %g1; \ xor %g1, %gdop_lox10(rtld_errno), %g1;\ @@ -104,16 +103,6 @@ ENTRY(name); \ st %o0, [%g1]; \ jmp %o7 + 8; \ mov -1, %o0; -# else -# define SYSCALL_ERROR_HANDLER \ -0: SETUP_PIC_REG_LEAF(o2,g1) \ - sethi %hi(rtld_errno), %g1; \ - or %g1, %lo(rtld_errno), %g1; \ - ldx [%o2 + %g1], %g1; \ - st %o0, [%g1]; \ - jmp %o7 + 8; \ - mov -1, %o0; -# endif # elif defined _LIBC_REENTRANT # ifndef NOT_IN_libc @@ -130,8 +119,7 @@ ENTRY(name); \ jmp %o7 + 8; \ mov -1, %o0; # else -# ifdef HAVE_BINUTILS_GOTDATA -# define SYSCALL_ERROR_HANDLER \ +# define SYSCALL_ERROR_HANDLER \ 0: SETUP_PIC_REG_LEAF(o2,g1) \ sethi %gdop_hix22(errno), %g1;\ xor %g1, %gdop_lox10(errno), %g1;\ @@ -139,16 +127,6 @@ ENTRY(name); \ st %o0, [%g1]; \ jmp %o7 + 8; \ mov -1, %o0; -# else -# define SYSCALL_ERROR_HANDLER \ -0: SETUP_PIC_REG_LEAF(o2,g1) \ - sethi %hi(errno), %g1; \ - or %g1, %lo(errno), %g1; \ - ldx [%o2 + %g1], %g1; \ - st %o0, [%g1]; \ - jmp %o7 + 8; \ - mov -1, %o0; -# endif # endif /* _LIBC_REENTRANT */ #endif /* PIC */ -- cgit v1.1 From 3c96908397840a436666fc2d361747cc26f466c9 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Thu, 1 Mar 2012 23:30:55 -0800 Subject: Kill sparc32 specific __getpagesize, unneeded. * sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c: Delete. --- .../unix/sysv/linux/sparc/sparc32/getpagesize.c | 45 ---------------------- 1 file changed, 45 deletions(-) delete mode 100644 sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c (limited to 'sysdeps/unix/sysv/linux/sparc') diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c b/sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c deleted file mode 100644 index c30d8e0..0000000 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c +++ /dev/null @@ -1,45 +0,0 @@ -/* Copyright (C) 1997, 2002, 2003, 2004 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 - -/* Return the system page size. This value will either be 4k or 8k depending - on whether or not we are running on Sparc v9 machine. */ - -/* If we are not a static program, this value is collected from the system - via the AT_PAGESZ auxiliary argument. If we are a static program, we - use the getpagesize system call. */ - -int -__getpagesize () -{ - int ret = GLRO(dl_pagesize); - if (ret == 0) - { - INTERNAL_SYSCALL_DECL (err); - ret = INTERNAL_SYSCALL (getpagesize, err, 0); -#ifndef SHARED - GLRO(dl_pagesize) = ret; -#endif - } - return ret; -} -libc_hidden_def (__getpagesize) -weak_alias (__getpagesize, getpagesize) -- cgit v1.1