Commit Graph

3911 Commits

Author SHA1 Message Date
Joseph Myers 35141d00d4 Add new MADV_* values for ARM. 2009-11-17 20:45:50 +00:00
Joseph Myers 87d2bea064 Define ERFKILL for MIPS. 2009-11-17 20:22:36 +00:00
Carlos O'Donell b8b2e2b9d1 Move socket.h to bits/socket.h
Place socket.h in the correct location.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>

	[BZ #6676]

	* sysdeps/unix/sysv/linux/hppa/socket.h: Move from here...
	* sysdeps/unix/sysv/linux/hppa/bits/socket.h: ... to here.
2009-11-15 15:53:20 -05:00
Carlos O'Donell c832a3a9b7 Update bits/fcntl.h for hppa.
Define values for F_GETOWN_EX and F_SETOWN_EX.
Define fallocate64@@GLIBC_2.11 and provide declarations
in fcntl.h with appropriate aliases.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>

	* sysdeps/unix/sysv/linux/hppa/Versions (libc): Add
	fallocate64@@GLIBC_2.11.
	* sysdeps/unix/sysv/linux/hppa/bits/fcntl.h
	[__USE_GNU]: Define F_GETOWN_EX, and F_SETOWN_EX.
	[!__USE_FILE_OFFSET64]: Define fallocate.
	[__USE_FILE_OFFSET64 && __REDIRECT]: Define __REDIRECT.
	[__USE_FILE_OFFSET64 && !__REDIRECT]: Define fallocate as
	fallocate64.
	[__USE_LARGEFILE64]: define fallocate64.
2009-11-15 15:46:46 -05:00
Carlos O'Donell 057c783bca Implement ELF_MACHINE_LOAD_ADDRESS using PC relative loads.
The current ELF_MACHINE_LOAD_ADDRESS used by the generic
function pointer code was not safe for use before relocation.
The macro has been rewritten to use only PC relative loads.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>

	* sysdeps/hppa/dl-fptr.h: Update copyright year.
	Reduce ELF_MACHINE_BOOT_FPTR_TABLE_LEN to 64.
	Implement ELF_MACHINE_LOAD_ADDRESS using PC relative loads.
2009-11-15 15:11:48 -05:00
Carlos O'Donell a2ed3d2a8e Remove constants which are now defined in generic file.
Several constants are now defined in a generic file and no longer
need to be defined in the hppa specific file.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>

	* sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:
	Remove FUTEX_WAITERS, FUTEX_OWNER_DIED, and FUTEX_TID_MASK.
2009-11-15 14:36:46 -05:00
Carlos O'Donell 926d329540 Fix socket constants.
[BZ #10527] Provide corrected socket constants that match the
kernel values.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>
	    Aurelian Jarno  <aurelien@aurel32.net>

	[BZ #10527]

	* sysdeps/unix/sysv/linux/hppa/socket.h: New file.
2009-11-15 14:33:51 -05:00
Carlos O'Donell d086703d6c Enable the use of -fPIE on hppa
[BZ #6676] Use PIC relocations in start.S to support the use of -fPIE
on hppa.

2009-11-15  Carlos O'Donell  <carlos@codesourcery.com>

	[BZ #6676]

	* sysdeps/hppa/elf/start.S: Use R_PARISC_DLTIND* relocations
	to support -fPIE.
2009-11-15 14:30:29 -05:00
Carlos O'Donell 8ef75725ce Use LIBGCC_S_SO to override generic version.
[BZ #10920] Use the new generic override to specify the hppa
specific libgcc_s.so.4 version number. Remove the files which
hppa no longer has to duplicate in order to accomplish
overriding libgcc_s.so version number.

2009-11-08  Carlos O'Donell  <carlos@codesourcery.com>

	[BZ #10920]

	* sysdeps/hppa/libgcc_s.h: New file.
	* sysdeps/unix/sysv/linux/hppa/nptl/unwind-forcedunwind.c: Remove.
	* sysdeps/unix/sysv/linux/hppa/nptl/unwind-resume.c: Remove.
2009-11-15 14:19:25 -05:00
Andreas Schwab a8e59aa896 Add libgcc_s.h for m68k 2009-11-15 00:28:00 +01:00
Andreas Schwab 722367f5d9 Define F_[GS]ETOWN_EX, F_OWNER_[TPG]ID, f_owner_ex for m68k 2009-11-15 00:27:02 +01:00
Joseph Myers 37a907cc86 Fix F_SETOWN_EX and F_GETOWN_EX definitions for MIPS. 2009-11-14 22:40:19 +00:00
Joseph Myers 06bda6deb5 Fix F_SETOWN_EX and F_GETOWN_EX definitions for ARM. 2009-11-14 22:39:23 +00:00
Matt Turner 52c693bd74 Fix alpha __fxstatat for empty file names.
[BZ #10609]
	* sysdeps/unix/sysv/linux/alpha/fxstatat.c (__fxstatat): Fix handling
	of empty parameters for file names.
2009-11-10 21:12:55 +00:00
Joseph Myers 1789cafb57 Fix M68K fallocate for -D_FILE_OFFSET_BITS=64.
* sysdeps/unix/sysv/linux/m68k/bits/fcntl.h (fallocate): Fix types
	of last two arguments when -D_FILE_OFFSET_BITS=64.
2009-11-07 13:30:54 +00:00
Joseph Myers 86ad0d12e1 Fix MIPS fallocate for -D_FILE_OFFSET_BITS=64.
* sysdeps/unix/sysv/linux/mips/bits/fcntl.h (fallocate): Fix types
	of last two arguments when -D_FILE_OFFSET_BITS=64.
2009-11-06 23:45:30 +00:00
Joseph Myers b055d3f1f7 Fix ARM fallocate for -D_FILE_OFFSET_BITS=64.
* sysdeps/unix/sysv/linux/arm/bits/fcntl.h (fallocate): Fix types
	of last two arguments when -D_FILE_OFFSET_BITS=64.
2009-11-06 23:44:33 +00:00
Philip Blundell b2b2415fe0 Fix ARMv4T interworking.
* sysdeps/unix/sysv/linux/arm/clone.S: Support V4T interworking.
        * sysdeps/unix/sysv/linux/arm/sysdep.h (__local_syscall_error): Likewise.
        * sysdeps/arm/memcpy.S: Likewise.
        * sysdeps/arm/memmove.S: Likewise.
2009-11-06 08:07:18 +00:00
Joseph Myers cb182378d7 Fix m68k fchownat for empty file names.
[BZ #10609]
	* sysdeps/unix/sysv/linux/m68k/fchownat.c (fchownat): Fix handling
	of empty parameters for file names.
2009-10-30 20:52:15 +00:00
Joseph Myers a896552ef1 Define F_OWNER_* and f_owner_ex for MIPS.
* sysdeps/unix/sysv/linux/mips/bits/fcntl.h: Define F_OWNER_* and
	f_owner_ex.
2009-10-29 16:51:55 +00:00
Joseph Myers 0366e55931 Define F_OWNER_* and f_owner_ex for ARM.
* sysdeps/unix/sysv/linux/arm/bits/fcntl.h: Define F_OWNER_* and
	f_owner_ex.
2009-10-29 16:51:04 +00:00
Daniel Gutson 274895575e Add ARM EABI build attributes.
Ensure that all objects in ARM EABI glibc have the proper EABI build
attributes to indicate that 8-byte stack alignment is required and
preserved.  (GNU ld does not currently give errors for mixing code
requiring 8-byte alignment - such as anything built with GCC - and
code not marked as preserving it, because of the prevalence of
assembly code without proper markers to indicate that alignment is
preserved.  The ARM RealView linker does give such errors.)

The bulk of the markers are accomplished by the change to sysdep.h,
but a few .S files do not include sysdep.h.  In the case of
internal_accept4.S, no code is generated because EABI does not have
socketcall, but for completeness a dummy file with the right
attributes is used to override the default version in libc.

	* sysdeps/arm/sysdep.h: (Tag_ABI_align8_preserved,
	Tag_ABI_align8_needed): Attributes added.
	* sysdeps/arm/elf/start.S: Likewise.
	* sysdeps/arm/eabi/abi-note.S: New file.
	* sysdeps/unix/sysv/linux/arm/eabi/internal_accept4.S: New
	file.
2009-10-22 19:39:47 +00:00
Andrew Stubbs fbc4c20a80 Fix register conflicts and avoid deprecated instructions in ARM EABI setjmp/longjmp.
* setjmp and longjmp were using the obsolete fstmiax and fldmiax
  instructions.

* Because of a confusion with two different sets of names for the same
  registers (r0...r3 and a1...a4), if VFP was present then the
  subsequent check for iWMMXt support would use a register that had
  been clobbered by saving/restoring the VFP registers.  (The bit
  being checked was clobbered by a reserved bit of FPSCR that it
  always 0 on present hardware, and no present hardware has both VFP
  and iWMMXt, so this did not cause visible problems.)

2009-10-22  Andrew Stubbs  <ams@codesourcery.com>
            Julian Brown  <julian@codesourcery.com>

	* sysdeps/arm/eabi/setjmp.S (__sigsetjmp): Replace deprecated
	instruction fstmiax with vstmia.
	Correct register conflict and comment.
	* sysdeps/arm/eabi/__longjmp.S (__longjmp): Use vldmia not fldmiax.
	Don't clobber r1/a2 register before testing IWMMXT hwcap.
2009-10-22 19:35:53 +00:00
Julian Brown b5c2620bee Fix locating GOT for Thumb-2 PIE binaries.
* sysdeps/arm/elf/start.S (_start): Avoid dependency on PC pipeline
	offset.
2009-10-22 19:22:35 +00:00
Joseph Myers afd09ae82a Define F_SETOWN_EX and F_GETOWN_EX for MIPS.
* sysdeps/unix/sysv/linux/mips/bits/fcntl.h: Define F_SETOWN_EX
	and F_GETOWN_EX.
2009-10-03 17:39:53 +00:00
Joseph Myers 4ba089f88e Define F_SETOWN_EX and F_GETOWN_EX for ARM.
* sysdeps/unix/sysv/linux/arm/bits/fcntl.h: Define F_SETOWN_EX and
	F_GETOWN_EX.
2009-10-03 17:39:05 +00:00
Daniel Jacobowitz f1297d79b2 Prevent GCC reusing "hi" and "lo" across system calls.
* sysdeps/unix/sysv/linux/mips/mips32/sysdep.h
	(__SYSCALL_CLOBBERS): Add "hi" and "lo".
	* sysdeps/unix/sysv/linux/mips/mips64/n32/sysdep.h
	(__SYSCALL_CLOBBERS): Likewise.
	* sysdeps/unix/sysv/linux/mips/mips64/n64/sysdep.h
	(__SYSCALL_CLOBBERS): Likewise.
2009-09-25 18:19:03 -04:00
Carlos O'Donell be0f2008ac Implement new NPTL POSIX Threads ABI for HPPA.
This version of the NPTL POSIX thread ABI for hppa does
not break backwards compatibility with the the old
Linuxthreads ABI, and is therefore suitable for release
by distributions.

	sysdeps/unix/sysv/linux/hppa/
	* internaltypes.h: New file.

	sysdeps/unix/sysv/linux/hppa/nptl/
	* pthreadP.h: New file.
	* pthread.h: New file.
	* pthread_cond_broadcast.c: New file.
	* pthread_cond_destroy.c: New file.
	* pthread_cond_init.c: New file.
	* pthread_cond_signal.c: New file.
	* pthread_cond_timedwait.c: New file.
	* pthread_cond_wait.c: New file.
	* bits/pthreadtypes.h: Make pthread_mutex_t,
	pthread_rwlock_t, and pthread_cond_t backwards
	compatible.
2009-09-08 14:32:53 -04:00
Andreas Schwab f0e6944906 Add ____longjmp_chk for m68k-linux 2009-09-06 21:24:50 +02:00
Joseph Myers 53df8bcec0 Add alternate signal stack support to ARM ____longjmp_chk.
* sysdeps/arm/____longjmp_chk.S: Remove.  Replaced by....
	* sysdeps/unix/sysv/linux/arm/____longjmp_chk.S,
	sysdeps/unix/sysv/linux/arm/eabi/____longjmp_chk.S: This.  New
	files.
	* sysdeps/arm/__longjmp.S, sysdeps/arm/eabi/__longjmp.S: Use r4
	for saved sp.
2009-08-06 16:53:09 +00:00
Joseph Myers c67273d5b2 Signal stack support for MIPS ____longjmp_chk.
* sysdeps/mips/____longjmp_chk.c: Remove.  Replaced by....
	* sysdeps/unix/sysv/linux/mips/____longjmp_chk.c: This.  New file.
	* sysdeps/mips/__longjmp.c (__longjmp): Use explicit register
	variable for env.  Use expansion of CHECK_SP macro for check.
	* sysdeps/mips/mips64/__longjmp.c (__Longjmp): Likewise.
2009-08-05 21:02:50 +00:00
Joseph Myers 9d84a81fe9 Make accept4 for MIPS o32 avoid socketcall.
sysdeps/unix/sysv/linux/internal_accept4.S expects socket.S to be
present if __NR_socketcall is defined (which it is on MIPS o32, even
though there are separate syscalls as well) and __NR_accept4 isn't.
MIPS does not have socket.S, since it uses separate syscalls, but
though the accept4 syscall should be added soon present kernel headers
do not have it.  This patch creates a dummy internal_accept4.S for
MIPS o32, and an accept4.c wrapper that undefines __NR_socketcall so
that the main accept4.c falls back to the ENOSYS implementation if
__NR_accept4 isn't defined; it doesn't seem worthwhile to have a
special socketcall-based assembly implementation just for o32 on a few
kernels in the range between accept4 being available via socketcall
and the accept4 syscall being available.
2009-08-03 16:48:38 +00:00
Aurelien Jarno 197aec2596 Define __ASSUME_EVENTFD2 and __ASSUME_SIGNALFD4 for MIPS.
* sysdeps/unix/sysv/linux/mips/kernel-features.h: Define
	__ASSUME_EVENTFD2 and __ASSUME_SIGNALFD4.
2009-07-29 15:27:35 +00:00
Aurelien Jarno 0a6ab2a600 Define __ASSUME_EVENTFD2 and __ASSUME_SIGNALFD4 for ARM.
* sysdeps/unix/sysv/linux/arm/kernel-features.h: Define
	__ASSUME_EVENTFD2 and __ASSUME_SIGNALFD4.
2009-07-29 15:26:39 +00:00
Aurelien Jarno 6b4e363a79 asm/elf.h don't exist anymore since linux kernel 2.6.25
* sysdeps/unix/sysv/linux/alpha/sys/procfs.h (ELF_NGREG,
	ELF_NFPREG, elf_greg_t, elf_gregset_t, elf_fpreg_t,
	elf_fpregset_t): Define. Don't include asm/elf.h.
2009-07-19 16:01:07 +02:00
Aurelien Jarno 97d1e7c8e1 Update include paths following the move of alpha to ports
* sysdeps/unix/sysv/linux/alpha/getdents64.c: Adjust include path.
	* sysdeps/unix/sysv/linux/alpha/nptl/fork.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/sem_post.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/timer_create.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/timer_delete.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/timer_getoverr.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/timer_gettime.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/nptl/timer_settime.c: Likewise.
	* sysdeps/unix/sysv/linux/alpha/sysconf.c: Likewise.
2009-07-19 16:00:06 +02:00
Aurelien Jarno 8cb716ea2c * sysdeps/unix/sysv/linux/alpha/nptl/lowlevellock.h: Define
FUTEX_WAIT_BITSET, FUTEX_WAKE_BITSET, FUTEX_CLOCK_REALTIME and
	FUTEX_BITSET_MATCH_ANY.
2009-07-19 15:59:58 +02:00
Aurelien Jarno c1592c256a Adapt alpha version of getsysstats.c to the changes in the main Linux version
* sysdeps/unix/sysv/linux/alpha/getsysstats.c (GET_NPROCS_PARSER):
        Change parameters and use next_line.
2009-07-19 15:59:49 +02:00
Joseph Myers cda50f828e Update MIPS dl-lookup.c for changes to generic version.
* sysdeps/mips/do-lookup.h: Remove.
	* sysdeps/mips/dl-lookup.c: Update from generic version, with
	non-PIC handling integrated.
2009-07-17 20:39:04 +00:00
Paul Brook f40617927c Avoid invalid unwind directives when building crti.o and crtn.o for ARM EABI.
* sysdeps/arm/eabi/Makefile (CFLAGS-initfini.s): Add
	-fno-asynchronous-unwind-tables -fno-unwind-tables.
	(CFLAGS-pt-initfini.s): Ditto.
2009-06-30 20:10:14 +00:00
Nathan Froyd 5a6ba634c6 Add missing CLIBABI variables __aeabi_stdin, __aeabi_stdout, __aeabi_stderr.
* sysdeps/arm/eabi/aeabi_lcsts.c (__aeabi_stdin, __aeabi_stdout,
	__aeabi_stderr): New variables.
	(setup_aeabi_stdio): New function.  Add it to .preinit_array.
2009-06-25 13:27:59 +00:00
Maxim Kuvyrkov b6dec1881f ARM EABI backtrace using unwind information.
2009-06-24  Maxim Kuvyrkov  <maxim@codesourcery.com>
            Mark Mitchell  <mark@codesourcery.com>
            Joseph Myers  <joseph@codesourcery.com>
            Kazu Hirata  <kazu@codesourcery.com>

	* sysdeps/arm/eabi/backtrace.c: New.
	* sysdeps/arm/eabi/Makefile (CFLAGS-backtrace.c): Add
	-funwind-tables.
	* sysdeps/arm/preconfigure: Add -fno-unwind-tables to CFLAGS.
	* sysdeps/unix/sysv/linux/arm/eabi/configure.in: Remove
	-fno-unwind-tables from CFLAGS.
	* sysdeps/unix/sysv/linux/arm/eabi/configure: Regenerate.
	* sysdeps/unix/sysv/linux/arm/eabi/nptl/unwind.h (_Unwind_Trace_Fn):
	Define.
	(_Unwind_Backtrace): Declare.
2009-06-24 15:55:04 +00:00
Joseph Myers 8200e168ef Define PF_IEEE802154 and AF_IEEE802154 for MIPS.
* sysdeps/unix/sysv/linux/mips/bits/socket.h: Define PF_IEEE802154
	and AF_IEEE802154.
2009-06-18 22:04:19 +00:00
Joseph Myers bf89c0e245 Use unsigned comparison in ARM ____longjmp_chk.
* sysdeps/arm/____longjmp_chk.S (CHECK_SP): Use unsigned
	comparison.
2009-05-18 19:48:54 +00:00
Joseph Myers 6a9f82ac93 ____longjmp_chk for MIPS.
* sysdeps/mips/____longjmp_chk.c: New file.
	* sysdeps/mips/__longjmp.c: If CHECK_SP is defined, use it.  Don't
	undefine __longjmp.
	* sysdeps/mips64/__longjmp.c: Likewise.
2009-05-16 22:24:56 +00:00
Joseph Myers ef889ffe8d ____longjmp_chk for ARM.
* sysdeps/arm/____longjmp_chk.S: New file.
	* sysdeps/arm/__longjmp.S: If CHECK_SP is defined, use it.
	* sysdeps/arm/eabi/__longjmp.S: Likewise.
2009-05-16 22:20:23 +00:00
Joseph Myers d9056ac655 fallocate fixes for MIPS n32 and n64.
* sysdeps/unix/sysv/linux/mips/mips64/n32/fallocate.c,
	sysdeps/unix/sysv/linux/mips/mips64/n32/fallocate64.c,
	sysdeps/unix/sysv/linux/mips/mips64/n64/fallocate.c,
	sysdeps/unix/sysv/linux/mips/mips64/n64/fallocate64.c: New.
2009-05-16 17:42:10 +00:00
Joseph Myers 9f8832d47f Assume preadv and pwritev syscalls on ARM for 2.6.30.
* sysdeps/unix/sysv/linux/arm/kernel-features.h (__ASSUME_PREADV,
	__ASSUME_PWRITEV): Don't undefine.
2009-05-16 15:19:32 +00:00
Joseph Myers 3066cb224d * sysdeps/unix/sysv/linux/m68k/Versions (libc): Add
fallocate64@@GLIBC_2.11.
2009-05-16 15:14:44 +00:00
Joseph Myers c504ff3be9 Add fallocate64 export for MIPS.
* sysdeps/unix/sysv/linux/mips/Versions (libc): Add
	fallocate64@@GLIBC_2.11.
2009-05-16 14:30:47 +00:00