diff options
Diffstat (limited to 'sysdeps/unix/sysv/linux')
-rw-r--r-- | sysdeps/unix/sysv/linux/alpha/getcontext.S | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/bits/poll.h | 6 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/kernel-features.h | 39 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S | 1 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S | 1 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S | 4 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S | 5 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/sparc/bits/poll.h | 9 |
9 files changed, 41 insertions, 32 deletions
diff --git a/sysdeps/unix/sysv/linux/alpha/getcontext.S b/sysdeps/unix/sysv/linux/alpha/getcontext.S index bf9820ac73..f010f337e6 100644 --- a/sysdeps/unix/sysv/linux/alpha/getcontext.S +++ b/sysdeps/unix/sysv/linux/alpha/getcontext.S @@ -1,5 +1,5 @@ /* Save current context. - Copyright (C) 2004 Free Software Foundation, Inc. + Copyright (C) 2004, 2006 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 @@ -57,6 +57,8 @@ weak_alias (__getcontext, getcontext) __getcontext_x: cfi_register (64, 0) + .set noat + /* Return value of getcontext. $0 is the only register whose value is not preserved. */ stq $31, UC_SIGCTX+SC_REGS($16) diff --git a/sysdeps/unix/sysv/linux/bits/poll.h b/sysdeps/unix/sysv/linux/bits/poll.h index dccb8b6665..d7996b46c5 100644 --- a/sysdeps/unix/sysv/linux/bits/poll.h +++ b/sysdeps/unix/sysv/linux/bits/poll.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1997, 2001 Free Software Foundation, Inc. +/* Copyright (C) 1997, 2001, 2006 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 @@ -36,8 +36,10 @@ #endif #ifdef __USE_GNU -/* This is an extension for Linux. */ +/* These are extensions for Linux. */ # define POLLMSG 0x400 +# define POLLREMOVE 0x1000 +# define POLLRDHUP 0x2000 #endif /* Event types always implicitly polled for. These bits need not be set in diff --git a/sysdeps/unix/sysv/linux/kernel-features.h b/sysdeps/unix/sysv/linux/kernel-features.h index 9f3f3965f4..37d25b1a5c 100644 --- a/sysdeps/unix/sysv/linux/kernel-features.h +++ b/sysdeps/unix/sysv/linux/kernel-features.h @@ -105,10 +105,10 @@ # define __ASSUME_STAT64_SYSCALL 1 #endif -/* On sparc and ARM the truncate64/ftruncate64/mmap2/stat64/lstat64/fstat64 +/* On sparc the truncate64/ftruncate64/mmap2/stat64/lstat64/fstat64 syscalls were introduced in 2.3.35. */ #if __LINUX_KERNEL_VERSION >= 131875 \ - && ((defined __sparc__ && !defined __arch64__) || defined __arm__) + && (defined __sparc__ && !defined __arch64__) # define __ASSUME_TRUNCATE64_SYSCALL 1 # define __ASSUME_MMAP2_SYSCALL 1 # define __ASSUME_STAT64_SYSCALL 1 @@ -191,7 +191,7 @@ don't know when it got introduced). But PowerPC64 does not support separate FCNTL64 call, FCNTL is already 64-bit */ #if __LINUX_KERNEL_VERSION >= 132100 \ - && (defined __arm__ || defined __powerpc__ || defined __sh__) \ + && (defined __powerpc__ || defined __sh__) \ && !defined __powerpc64__ # define __ASSUME_FCNTL64 1 #endif @@ -260,24 +260,10 @@ #endif /* The vfork syscall on x86 and arm was definitely available in 2.4. */ -#if __LINUX_KERNEL_VERSION >= 132097 && (defined __i386__ || defined __arm__) +#if __LINUX_KERNEL_VERSION >= 132097 && defined __i386__ # define __ASSUME_VFORK_SYSCALL 1 #endif -/* There are an infinite number of PA-RISC kernel versions numbered - 2.4.0. But they've not really been released as such. We require - and expect the final version here. */ -#ifdef __hppa__ -# define __ASSUME_32BITUIDS 1 -# define __ASSUME_TRUNCATE64_SYSCALL 1 -# define __ASSUME_MMAP2_SYSCALL 1 -# define __ASSUME_STAT64_SYSCALL 1 -# define __ASSUME_IPC64 1 -# define __ASSUME_ST_INO_64_BIT 1 -# define __ASSUME_FCNTL64 1 -# define __ASSUME_GETDENTS64_SYSCALL 1 -#endif - /* Alpha switched to a 64-bit timeval sometime before 2.2.0. */ #if __LINUX_KERNEL_VERSION >= 131584 && defined __alpha__ # define __ASSUME_TIMEVAL64 1 @@ -296,15 +282,6 @@ # define __ASSUME_CLONE_THREAD_FLAGS 1 #endif -/* These features were surely available with 2.4.12. */ -#if __LINUX_KERNEL_VERSION >= 132108 && defined __mc68000__ -# define __ASSUME_MMAP2_SYSCALL 1 -# define __ASSUME_TRUNCATE64_SYSCALL 1 -# define __ASSUME_STAT64_SYSCALL 1 -# define __ASSUME_FCNTL64 1 -# define __ASSUME_VFORK_SYSCALL 1 -#endif - /* Beginning with 2.5.63 support for realtime and monotonic clocks and timers based on them is available. */ #if __LINUX_KERNEL_VERSION >= 132415 @@ -359,7 +336,7 @@ /* The utimes syscall has been available for some architectures forever. For x86 it was introduced after 2.5.75, for x86-64, ppc, and ppc64 it was introduced in 2.6.0-test3. */ -#if defined __alpha__ || defined __ia64__ || defined __hppa__ \ +#if defined __alpha__ || defined __ia64__ \ || defined __sparc__ \ || (__LINUX_KERNEL_VERSION > 132427 && defined __i386__) \ || (__LINUX_KERNEL_VERSION > 132609 && defined __x86_64__) \ @@ -468,3 +445,9 @@ && (defined __i386__ || defined __x86_64__) # define __ASSUME_ATFCTS 1 #endif + +/* Support for inter-process robust mutexes was added in 2.6.17. */ +#if __LINUX_KERNEL_VERSION >= 0x020611 \ + && (defined __i386__ || defined __x86_64__) +# define __ASSUME_SET_ROBUST_LIST 1 +#endif diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S b/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S index 1a5251d100..40a7a24f19 100644 --- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S +++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S @@ -45,6 +45,7 @@ ENTRY(__CONTEXT_FUNC_NAME) stw r0,20(r1) cfi_offset (lr, _FRAME_LR_SAVE) stw r31,12(r1) + cfi_offset(r31,-4) lwz r31,_UC_REGS_PTR(r3) /* diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S index a0f018ba41..366206d286 100644 --- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S +++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S @@ -52,8 +52,12 @@ ENTRY (BP_SYM (__clone)) std r29,56(r1) std r30,64(r1) std r31,72(r1) + cfi_offset(r29,-56) + cfi_offset(r30,-64) + cfi_offset(r31,-72) #ifdef RESET_PID std r28,48(r1) + cfi_offset(r28,-48) #endif /* Set up stack frame for child. */ diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S index 98b49ba1dc..8d7c959ff9 100644 --- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S +++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S @@ -144,6 +144,7 @@ ENTRY(__novec_getcontext) std r0,FRAME_LR_SAVE(r1) cfi_offset (lr, FRAME_LR_SAVE) stdu r1,-128(r1) + cfi_adjust_cfa_offset(128) li r3,ENOSYS bl JUMPTARGET(__syscall_error) nop diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S index 68fec9d2aa..48e9af363d 100644 --- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S +++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S @@ -33,6 +33,7 @@ ENTRY(__novec_setcontext) #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL mflr r0 std r31,-8(1) + cfi_offset(r31,-8) std r0,FRAME_LR_SAVE(r1) cfi_offset (lr, FRAME_LR_SAVE) stdu r1,-128(r1) @@ -169,7 +170,9 @@ L(nv_do_sigret): /* If the kernel is not at least 2.4.21 then generate a ENOSYS stub. */ mflr r0 std r0,FRAME_LR_SAVE(r1) + cfi_offset(lr,FRAME_LR_SAVE) stdu r1,-128(r1) + cfi_adjust_cfa_offset(128) li r3,ENOSYS bl JUMPTARGET(__syscall_error) nop @@ -201,6 +204,7 @@ ENTRY(__setcontext) #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL mflr r0 std r31,-8(1) + cfi_offset(r31,-8) std r0,FRAME_LR_SAVE(r1) cfi_offset (lr, FRAME_LR_SAVE) stdu r1,-128(r1) diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S index 5a128606ad..936d641b6b 100644 --- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S +++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S @@ -35,6 +35,7 @@ ENTRY(__novec_swapcontext) std r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r3) mflr r0 std r31,-8(1) + cfi_offset(r31,-8) std r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r3) std r0,FRAME_LR_SAVE(r1) cfi_offset (lr, FRAME_LR_SAVE) @@ -264,6 +265,7 @@ L(nv_do_sigret): /* If the kernel is not at least 2.4.21 then generate a ENOSYS stub. */ mflr r0 std r0,FRAME_LR_SAVE(r1) + cfi_offset(lr,FRAME_LR_SAVE) stdu r1,-128(r1) li r3,ENOSYS bl JUMPTARGET(__syscall_error) @@ -298,11 +300,14 @@ ENTRY(__swapcontext) std r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r3) mflr r0 std r31,-8(1) + cfi_offset(r31,-8) std r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r3) std r0,FRAME_LR_SAVE(r1) + cfi_offset (lr, FRAME_LR_SAVE) std r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r3) std r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r3) stdu r1,-128(r1) + cfi_adjust_cfa_offset(128) std r4,(SIGCONTEXT_GP_REGS+(PT_R4*8))(r3) std r5,(SIGCONTEXT_GP_REGS+(PT_R5*8))(r3) std r6,(SIGCONTEXT_GP_REGS+(PT_R6*8))(r3) diff --git a/sysdeps/unix/sysv/linux/sparc/bits/poll.h b/sysdeps/unix/sysv/linux/sparc/bits/poll.h index f7a7393154..53b94bc50e 100644 --- a/sysdeps/unix/sysv/linux/sparc/bits/poll.h +++ b/sysdeps/unix/sysv/linux/sparc/bits/poll.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1997, 2001 Free Software Foundation, Inc. +/* Copyright (C) 1997, 2001, 2006 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 @@ -35,6 +35,13 @@ # define POLLWRBAND 0x100 /* Priority data may be written. */ #endif +#ifdef __USE_GNU +/* These are extensions for Linux. */ +# define POLLMSG 0x200 +# define POLLREMOVE 0x400 +# define POLLRDHUP 0x800 +#endif + /* Event types always implicitly polled for. These bits need not be set in `events', but they will appear in `revents' to indicate the status of the file descriptor. */ |