Commit Graph

4006 Commits

Author SHA1 Message Date
Roland McGrath
a917305749 Fix glob64 broken by cleanup. 2013-05-06 17:11:12 -07:00
Roland McGrath
9723ffc524 Move dummy glob64.c alongside glob.c that defines glob64. 2013-05-06 16:11:11 -07:00
Roland McGrath
d5e8275481 Split _dl_writev out from _dl_debug_vdprintf. 2013-05-06 11:30:41 -07:00
Roland McGrath
cc0e6ed81f Consolidate definitions of _FORTIFY_SOURCE wrappers for open{,64}{,at}. 2013-05-03 16:33:26 -07:00
Adhemerval Zanella
83e7640f6b PowerPC: Add time vDSO support
PowerPC kernel now provides a vDSO implementation for time syscall
(commit fcb41a2030abe0eb716ef0798035ef9562097f42). This patch changes
time syscall wrapper to use the vDSO when available. It also changes
the default non vDSO time on PowerPC to use sysdeps/posix/time.c
(since gettimeofday is a vDSO call).
2013-05-03 15:04:54 -05:00
Andreas Jaeger
164fd39d05 Sync with Linux 3.9
* sysdeps/gnu/netinet/tcp.h (TCP_TIMESTAMP): New value, from
	Linux 3.9.
	* sysdeps/unix/sysv/linux/bits/socket.h (PF_VSOCK, AF_VSOCK):
	Add.
	(PF_MAX): Adjust for VSOCK change.
2013-05-03 20:52:00 +02:00
Heiko Carstens
5c95f7b66b S/390: Change struct statfs[64] member types to unsigned values
Kay Sievers reported that coreutils' stat tool has a problem with
s390's statfs[64] definition:

> The definition of struct statfs::f_type needs a fix. s390 is the only
> architecture in the kernel that uses an int and expects magic
> constants lager than INT_MAX to fit into.
>
> A fix is needed to make Fedora boot on s390, it currently fails to do
> so. Userspace does not want to add code to paper-over this issue.

[...]

> Even coreutils cannot handle it:
>   #define RAMFS_MAGIC  0x858458f6
>   # stat -f -c%t /
>   ffffffff858458f6
>
>   #define BTRFS_SUPER_MAGIC 0x9123683E
>   # stat -f -c%t /mnt
>   ffffffff9123683e

The bug is caused by an implicit sign extension within the stat tool:

out_uint_x (pformat, prefix_len, statfsbuf->f_type);

where the format finally will be "%lx".
A similar problem can be found in the 'tail' tool.
s390 is the only architecture which has an int type f_type member in
struct statfs[64]. Other architectures have either unsigned ints or
long values, so that the problem doesn't occur there.

Therefore change the type of the f_type member to unsigned int, so
that we get zero extension instead sign extension when assignment to
a long value happens.

Reported-by: Kay Sievers <kay@vrfy.org>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
2013-04-23 08:59:35 +02:00
Adam Conrad
ccdad15df5 Remove __wur from setfsuid and setfsgid. 2013-04-18 23:58:16 -06:00
Siddhesh Poyarekar
d755bba40f Preserve errno across _PC_CHOWN_RESTRICTED call on XFS
Fix BZ #15305.

On kernel versions earlier than 2.6.29, the Linux kernel exported a
sysctl called restrict_chown for xfs, which could be used to allow
chown to users other than the owner.  2.6.29 removed this support,
causing the open_not_cancel_2 to fail and thus modify errno.  The fix
is to save and restore errno so that the caller sees it as unmodified.

Additionally, since the code to check the sysctl is not useful on
newer kernels, we add an ifdef so that in future the code block gets
rmeoved completely.
2013-04-03 10:56:45 +05:30
Thomas Schwinge
572676160d New <math.h> macro named issignaling to check for a signaling NaN (sNaN).
It is based on draft TS 18661 and currently enabled as a GNU extension.
2013-04-02 13:51:02 +02:00
Roland McGrath
a600e5cef5 Consolidate Linux and POSIX libc_fatal code. 2013-03-19 17:07:15 -07:00
Roland McGrath
bc16e260d0 Move _dl_non_dynamic_init, _dl_aux_init declarations. 2013-03-15 14:32:04 -07:00
Adhemerval Zanella
ef26eece63 PowerPC: gettimeofday optimization by using IFUNC 2013-03-15 10:58:56 -03:00
Siddhesh Poyarekar
e25cfa6005 Fix formatting in last change 2013-03-14 08:18:48 +05:30
Petr Baudis
58a1335e76 Fix __times() handling of EFAULT when buf is NULL 2013-03-14 01:16:53 +01:00
Andreas Schwab
fb6b0fcbf1 Remove extra pthread_atfork compat symbols 2013-03-11 09:47:01 +01:00
Adhemerval Zanella
edf66e57fc PowerPC: unify math_ldbl.h implementations
This patch removes redudant definition from PowerPC specific
math_ldbl, using the definitions from ieee754 math_ldbl.h.
2013-03-08 11:07:15 -03:00
Andreas Jaeger
4dd4e15794 Install <bits/mman-linux.h>
* sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add
	bits/mman-linux.h.
2013-03-07 13:06:20 +01:00
Siddhesh Poyarekar
adbb8027be Remove PIPE_BUF Linux-specific code
Fixes BZ #12723

The variable pipe buffer size does nothing to the value of PIPE_BUF,
since the number of bytes that are atomically written is still
PIPE_BUF on Linux.
2013-03-07 12:15:08 +05:30
Andreas Jaeger
664a9ce4ca Use <bits/mman-linux.h> for MIPS
* sysdeps/unix/sysv/linux/bits/mman-linux.h (MAP_ANONYMOUS):
	Allow definition via __MAP_ANONYMOUS.

	* sysdeps/unix/sysv/linux/mips/bits/mman.h: Remove all defines
	provided by bits/mman-linux.h and include <bits/mman-linux.h>.
	(__MAP_ANONYMOUS): Define.
2013-03-06 17:36:37 +01:00
Andreas Jaeger
8e39047d31 Remove MAP_GROWSUP on s390
* sysdeps/unix/sysv/linux/s390/bits/mman.h (MAP_GROWSUP):
	Remove, it's not part of Linux headers.
2013-03-06 16:39:56 +01:00
Andreas Jaeger
67525cb832 Sync with Linux 3.8 2013-03-06 16:35:19 +01:00
Joseph Myers
2d67d91ac0 Remove powerpc64 bounded-pointers code. 2013-03-06 00:10:21 +00:00
Andreas Jaeger
890b58d3bd Define MCL_CURRENT, MCL_FUTURE in bits/mman-linux.h
* sysdeps/unix/sysv/linux/s390/bits/mman.h: Include
	<bits/mman-linux.h>.
	(MCL_CURRENT, MCL_FUTURE): Do not define here, the generic value
	is fine.
	* sysdeps/unix/sysv/linux/sh/bits/mman.h: Move include of
	<bits/mman-linux.h> to end of file.
	(MCL_CURRENT, MCL_FUTURE): Do not define here, the generic value
	is fine.
	* sysdeps/unix/sysv/linux/x86/bits/mman.h: Move include of
	<bits/mman-linux.h> to end of file.
	(MCL_CURRENT, MCL_FUTURE): Do not define here, the generic value
	is fine.
	* sysdeps/unix/sysv/linux/sparc/bits/mman.h: Move include of
	<bits/mman-linux.h> to end of file.

	* sysdeps/unix/sysv/linux/bits/mman-linux.h [!MCL_CURRENT]
	(MCL_CURRENT, MCL_FUTURE): Define here.
2013-03-05 19:40:13 +01:00
Andreas Krebbel
c3e94a9533 S/390: Fix rt_sigprocmask syscall invocation in get/set/swapcontext. 2013-03-05 08:15:33 +01:00
Andreas Jaeger
539d8e0188 Create <bits/mman-linux.h>
* sysdeps/unix/sysv/linux/bits/mman-linux.h: New file, with
	Linux common definitions.

	* sysdeps/unix/sysv/linux/sh/bits/mman.h: Remove all defines
	provided by bits/mman-linux.h and include <bits/mman-linux.h>.
	* sysdeps/unix/sysv/linux/x86/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/s390/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/powerpc/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/sh/bits/mman.h: Likewise.
	* sysdeps/unix/sysv/linux/sparc/bits/mman.h: Likewise.
2013-03-04 20:26:59 +01:00
Roland McGrath
7775448e57 Fix NEED_DL_SYSINFO_DSO conditionals. 2013-03-01 14:44:44 -08:00
Joseph Myers
b551088322 Remove powerpc32 bounded-pointers code. 2013-02-28 21:23:47 +00:00
Joseph Myers
2366713d87 Remove remaining bounded-pointers support from i386 .S files. 2013-02-21 22:21:52 +00:00
Siddhesh Poyarekar
ba384f6ed9 C++11 thread_local destructors support
This feature is specifically for the C++ compiler to offload calling
thread_local object destructors on thread program exit, to glibc.
This is to overcome the possible complication of destructors of
thread_local objects getting called after the DSO in which they're
defined is unloaded by the dynamic linker.  The DSO is marked as
'unloadable' if it has a constructed thread_local object and marked as
'unloadable' again when all the constructed thread_local objects
defined in it are destroyed.
2013-02-18 19:08:21 +05:30
Siddhesh Poyarekar
8313cb997d FUTEX_*_REQUEUE_PI support for non-x86 code
Add FUTEX_*_REQUEUE_PI support for the default C code and also add
implementations for s-390 and ppc.
2013-02-18 16:07:10 +05:30
Joseph Myers
2969121014 Remove bounded-pointers handling from x86_64 assembly sources. 2013-02-17 21:57:26 +00:00
Joseph Myers
2bdd4ca6b6 Remove miscellaneous bounded-pointers relics in C code. 2013-02-15 00:51:53 +00:00
Joseph Myers
e97ed6ddbe Remove bp-sym.h and BP_SYM uses from C code. 2013-02-14 13:12:02 +00:00
Joseph Myers
70d9946a44 Remove __ptrvalue, __bounded and __unbounded. 2013-02-13 23:30:40 +00:00
Joseph Myers
a2da1673fe Remove CHECK_N and bp-checks.h. 2013-02-08 20:06:30 +00:00
Joseph Myers
f3aae3f3eb Remove CHECK_1 and CHECK_1_NULL_OK. 2013-02-08 01:12:11 +00:00
Roland McGrath
f1d70dad53 Remove lots of inline keywords. 2013-02-07 14:44:18 -08:00
Roland McGrath
7bd642f580 Move nss directory into sysdeps Subdirs. 2013-02-05 14:32:48 -08:00
Joseph Myers
6277fdabc0 Remove CHECK_STRING, CHECK_STRING_NULL_OK and __ubp_memchr. 2013-02-04 16:29:39 +00:00
Joseph Myers
e782a927c2 Remove BOUNDED_N and BOUNDED_1. 2013-02-01 06:35:29 +00:00
Joseph Myers
3a7ac8a0f5 Remove bp-start.h and INIT_ARGV_and_ENVIRON. 2013-02-01 00:06:18 +00:00
Joseph Myers
32a45bea39 Remove CHECK_SIGSET and CHECK_SIGSET_NULL_OK. 2013-01-31 23:00:15 +00:00
Joseph Myers
2e8a5c8c46 Remove bp-semctl.h and CHECK_SEMCTL. 2013-01-31 22:59:04 +00:00
Joseph Myers
c2d549290d Remove bp-thunks code. 2013-01-31 22:57:06 +00:00
Pino Toscano
67b3f58c83 ulimit: remove buggy bsd implementation
The bsd implementation of ulimit produces wrong return values, so remove it
in favour of the posix implementation.

The only regression for non-Linux implementations using bsd sysdeps and not
providing an own ulimit is that the __UL_GETMAXBRK case (which is non-standard)
is left unimplemented (giving EINVAL).
2013-01-23 17:29:35 +01:00
Pino Toscano
9cbbc4aebe ulimit: move linux implementation as posix
The linux implementation of ulimit works correctly and has nothing specific
to Linux, so move it as general posix implementation.
2013-01-23 17:25:53 +01:00
Joseph Myers
052aff9578 Make bits/wchar.h correct for all architectures (bug 15036). 2013-01-23 00:42:51 +00:00
Anton Blanchard
471a1672d4 PowerPC: Rename __kernel_vdso_get_tbfreq to __kernel_get_tbfreq.
In order for the __kernel_get_tbfreq vDSO call to work the
INTERNAL_VSYSCALL_NCS macro needed to be updated to prevent it from
assuming an integer return type (since the timebase frequency is a 64-bit
value) by specifying the type of the return type as a macro parameter.  The
macro then specifically declares the return value as a 'register' (or
implied pair) of the denoted type.  The compiler is then informed that this
register (or implied pair) is to be used for the return value.
2013-01-18 07:44:38 -06:00
Pino Toscano
2a26ef3a01 Add HAVE_MREMAP for mremap usage
Introduce (only on Linux) and use a HAVE_MREMAP symbol to advertize mremap
availability.

Move the malloc-sysdep.h include from arena.c to malloc.c, since what is
provided by malloc-sysdep.h is needed earlier in malloc.c, before the inclusion
of arena.c.
2013-01-17 21:08:12 +01:00
Mike Frysinger
357679d2fc scsi/sg.h: include stddef.h for size_t
This header uses size_t but doesn't include stddef.h for it.  So when
packages happen to include this before any header that defines size_t,
they get a build failure.

Reviewed-by: Carlos O'Donell <codonell@redhat.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2013-01-15 12:56:21 -05:00
David S. Miller
8794a96418 Adjust sparc for Roland's multiarch sysdep directory changes.
* sysdeps/sparc/sparc32/sparcv9/fpu/unix/sysv/linux/multiarch/Implies:
	Move to...
	* sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/fpu/multiarch/Implies:
	Here.
2013-01-11 18:04:10 -08:00
Joseph Myers
6a57d93130 Remove __GLIBC_HAVE_LONG_LONG. 2013-01-11 21:13:25 +00:00
Andreas Jaeger
c6fe55cf60 Add MSG_FASTOPEN
[BZ #15003]
	* sysdeps/unix/sysv/linux/bits/socket.h (MSG_FASTOPEN): New
	value. Sync with Linux 3.7.
2013-01-11 11:53:13 +01:00
Joseph Myers
828beb132d Use __extension__ with long long in installed headers. 2013-01-10 20:19:45 +00:00
H.J. Lu
1a20cb20ff Correct _XXX_ILP32_OFFBIG for x32 2013-01-10 08:38:48 -08:00
Andreas Schwab
557eead076 Revert "Use ieee754/dbl-64/wordsize-64 on powerpc64"
This reverts commit 7a9d2c3971.
2013-01-10 10:44:05 +01:00
Andreas Schwab
7a9d2c3971 Use ieee754/dbl-64/wordsize-64 on powerpc64
* sysdeps/ieee754/ldbl-opt/wordsize-64/s_ceil.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_finite.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_floor.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_frexp.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_isinf.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_isnan.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_llround.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_logb.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_lround.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_modf.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_nearbyint.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_remquo.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_rint.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_round.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_scalbln.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_scalbn.c: New file.
	* sysdeps/ieee754/ldbl-opt/wordsize-64/s_trunc.c: New file.
	* sysdeps/unix/sysv/linux/powerpc/powerpc64/Implies: Add
	ieee754/ldbl-opt/wordsize-64.
	* sysdeps/powerpc/powerpc64/Implies: Add
	ieee754/dbl-64/wordsize-64.
2013-01-10 09:59:58 +01:00
Andreas Schwab
988197f0cc Define flags for fallocate 2013-01-10 09:59:57 +01:00
Anton Blanchard
d5e0b9bd6e PowerPC: Change sched_getcpu to use vDSO getcpu instead of syscall. 2013-01-09 20:30:11 -06:00
Joseph Myers
eede9df980 Don't check __GNUC__ together with __USE_EXTERN_INLINES. 2013-01-08 20:08:56 +00:00
Andreas Jaeger
c40ea3d9a3 BZ#14985: Remove erroneous EPOLL_NONBLOCK
[BZ# 14985]
	* sysdeps/unix/sysv/linux/sparc/bits/epoll.h (EPOLL_NONBLOCK):
	Remove.
	* sysdeps/unix/sysv/linux/bits/epoll.h (EPOLL_NONBLOCK):
	Likewise.
	* sysdeps/unix/sysv/linux/x86/bits/epoll.h (EPOLL_NONBLOCK):
	Likewise.

ChangeLog.mips:
	[BZ# 14985]
	* sysdeps/unix/sysv/linux/mips/bits/epoll.h (EPOLL_NONBLOCK):
	* Remove.

ChangeLog.hppa:
	[BZ# 14985]
	* sysdeps/unix/sysv/linux/hppa/sys/epoll.h (EPOLL_NONBLOCK):
	Remove.

ChangeLog.alpha:
	[BZ# 14985]
	* sysdeps/unix/sysv/linux/alpha/bits/epoll.h (EPOLL_NONBLOCK):
	Remove.
2013-01-08 19:32:00 +01:00
Joseph Myers
568035b787 Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
Joseph Myers
f4cf5f2d8b Add script to update copyright notices and reformat some to facilitate its use. 2013-01-01 16:29:10 +00:00
Mike Frysinger
e933a9432c linux: posix_fadvise: support __NR_fadvise64_64
Some arches do not have a __NR_fadvise64 but do have __NR_fadvise64_64.
If the former is unavailable, fallback to the latter.

Reviewed-by: Carlos O'Donell <carlos@systemhalted.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-12-06 20:00:43 -05:00
Siddhesh Poyarekar
f16946dd9c Fix "set but not used" warnings for powerpc64 2012-12-06 20:20:45 +05:30
Joseph Myers
20f0018d92 Fix powerpc32 "set but not used" warnings from INTERNAL_SYSCALL_DECL. 2012-12-04 14:40:17 +00:00
Mike Frysinger
37db69de1d clock_getcpuclockid: delete unused HAS_CPUCLOCK
In commit 26889eacc2 (Remove
__ASSUME_POSIX_CPU_TIMERS), all users of HAS_CPUCLOCK were
dropped.  Punt the fallback definition too.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-11-29 19:31:40 -05:00
Andreas Schwab
4cc34c3511 Revert "2012-11-07 Andreas Jaeger <aj@suse.de>"
This reverts commit 01f34a3bd8.

The issue has been fixed in the kernel.
2012-11-28 16:19:03 +01:00
Carlos O'Donell
105ce2ce62 Document syscall signature prefixes in sysdep/unix/make-syscalls.sh 2012-11-20 14:40:34 -05:00
Thomas Schwinge
123be9deda Add recvmmsg and sendmmsg to the generic glibc API. 2012-11-20 19:26:04 +01:00
Joseph Myers
12df29e2d2 Include string.h in sysdeps/unix/sysv/linux/fxstatat.c. 2012-11-17 03:43:53 +00:00
David S. Miller
640ac3f1bf Fix check-localplt regressions on sparc.
* sysdeps/unix/sysv/linux/sparc/sparc64/get_clockfreq.c: Include
	inttypes.h
	(__get_clockfreq_via_proc_openprom): Use __open, __read, and
	__close rather than their public counterparts.
2012-11-11 15:46:01 -08:00
Joseph Myers
8b748aed2a Support --with-pkgversion and --with-bugurl. 2012-11-09 22:13:45 +00:00
Andreas Jaeger
2c1adbcb76 PowerPC: Use <bits/fcntl-linux.h>
* sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h: Remove all
	definitions and declarations that are provided by
	<bits/fcntl-linux.h> and include <bits/fcntl-linux.h>.
2012-11-09 16:41:38 +01:00
Andreas Krebbel
d0f8457e6b S/390: Add hwcap value for transactional execution. 2012-11-08 09:53:00 +01:00
David S. Miller
60e8270d6c Fix NULL ucontext->uc_link handling on sparc64.
* sysdeps/unix/sysv/linux/sparc/sparc64/__start_context.S: New file.
	* sysdeps/unix/sysv/linux/sparc/sparc64/makecontext.c
	(__start_context): Declare.
	(__makecontext_ret): Delete.
	(__makecontext): Hook up __start_context instead of
	__makecontext_ret.
	* sysdeps/unix/sysv/linux/sparc/sparc64/Makefile
	(sysdep_routines): Add __start_context when in stdlib.
2012-11-07 21:01:06 -08:00
Jeff Law
01f34a3bd8 2012-11-07 Andreas Jaeger <aj@suse.de>
[BZ #14809]
        * sysdeps/unix/sysv/linux/sys/sysctl.h (_UAPI_LINUX_KERNEL_H)
        (_UAPI_LINUX_TYPES_H): Starting with Linux 3.7, the include header
        guards are changed.  Only define if not yet defined, #undef back
        after including linux/sysctl.h if defined here.
2012-11-07 11:58:37 -07:00
Thomas Schwinge
b830319d49 [BZ #157] Remove include/stub-tag.h for good. 2012-11-04 19:59:40 +01:00
Pino Toscano
72e182e38d Fix small indendation issues in paths.h files 2012-11-04 10:10:58 +01:00
Andreas Schwab
d6cffd3ec0 PowerPC: Fix uc_link == NULL handling for makecontex.
If the function registered with makecontext returns with a NULL context
link the process should exit with zero, not non-zero.
2012-11-01 20:10:39 -05:00
Andreas Schwab
5a03cb1e85 Fix powerpc abilist sort order 2012-10-31 23:28:48 +01:00
Tulio Magno Quites Machado Filho
90aff2ff13 Correct order of entries in powerpc libc.abilist files. 2012-10-31 17:03:55 -05:00
Andreas Jaeger
86ebe6b133 Remove redundant defines of __O_LARGEFILE
* sysdeps/unix/sysv/linux/x86/bits/fcntl.h (__O_LARGEFILE)
	[!__x86_64]: Do not define, take value from <bits/fcntl-linux.h>.
	* sysdeps/unix/sysv/linux/s390/bits/fcntl.h (__O_LARGEFILE):
	[__WORDSIZE != 64]: Likewise.

	* sysdeps/unix/sysv/linux/generic/bits/fcntl.h: (__O_LARGEFILE)
	[__WORDSIZE != 64]: Do not define, take value from
	<bits/fcntl-linux.h>.
2012-10-27 13:49:30 +02:00
David S. Miller
e2211bed12 Fix sparc64 build.
* sysdeps/unix/sysv/linux/sparc/sparc64/get_clockfreq.c
	(__get_clockfreq_via_proc_openprom): Use strtoumax instead
	of strtoull.
2012-10-25 15:41:32 -07:00
Roland McGrath
1e9d84cdbc Use __getdents instead of __getdirentries in sparc __get_clockfreq_via_proc_openprom. 2012-10-25 14:49:28 -07:00
Roland McGrath
6e6249d0b4 BZ#14743: Move clock_* symbols from librt to libc. 2012-10-24 14:50:46 -07:00
Andreas Jaeger
9fddec1a48 F_GETLK cleanup for <bits/fcntl.h> 2012-10-24 08:54:46 +02:00
Andreas Jaeger
b4b4c2968e Fix O_RSYNC
(O_RSYNC): Define to __O_RSYNC if it exists, otherwise to O_SYNC.
2012-10-22 19:59:22 +02:00
Andreas Jaeger
2a0e2669f9 Always define __O_LARGEFILE 2012-10-22 16:23:20 +02:00
Andreas Jaeger
7cd37b437c Improve <bits/fcntl-linux.h>: F_GETLK etc.
(F_GETLK, F_SETLK, F_SETLKW) [!F_GETLK]: Define values for [!__USE_FILE_OFFSET64].
2012-10-22 09:31:13 +02:00
Andreas Jaeger
1728f92d42 Install <bits/fcntl-linux.h>
(sysdep_headers): Add bits/fcntl-linux.h.
2012-10-22 09:24:14 +02:00
Andreas Jaeger
481b90b9d6 Use __O_LARGEFILE instead of O_LARGEFILE 2012-10-22 09:20:00 +02:00
Andreas Jaeger
88d4247f19 SH: Use <bits/fcntl-linux.h>
Remove all definitions and declarations that are provided by
<bits/fcntl-linux.h> and include <bits/fcntl-linux.h>.
2012-10-21 20:01:32 +02:00
Andreas Jaeger
335e6931e2 Reorganization of bits/fcntl.h for Linux
Create a new bits/fcntl-linux.h that contains Linux generic code and a
include it from the architecture specific bits/fcntl.h.

Architectures done: x86, SPARC, s390
2012-10-20 12:54:49 +02:00
Joseph Myers
ced52c719c Remove _G_OPEN64, _G_LSEEK64, _G_MMAP64, _G_FSTAT64 from _G_config.h. 2012-10-18 18:50:43 +00:00
Andreas Schwab
ca38dc17d8 Avoid PLT references from __get_clockfreq on powerpc 2012-10-12 16:54:06 +02:00
Alexandre Oliva
e745142509 * crypt/crypt-entry.c: Include fips-private.h.
(__crypt_r, __crypt): Disable MD5 and DES if FIPS is enabled.
* crypt/md5c-test.c (main): Tolerate disabled MD5.
* sysdeps/unix/sysv/linux/fips-private.h: New file.
* sysdeps/generic/fips-private.h: New file, dummy fallback.
2012-10-10 07:05:46 -03:00
Roland McGrath
b8493de0ec Add missing magic to GLIBC_PROVIDES. 2012-10-09 15:41:30 -07:00
Joseph Myers
c8450f70fa Remove _G_off64_t and _G_stat64 from _G_config.h. 2012-10-09 15:09:32 +00:00
Andreas Schwab
1ab2935061 Fix missing include in sysdeps/unix/sysv/linux/powerpc/get_timebase_freq.c 2012-10-08 12:13:39 +02:00
Khem Raj
c2b598a945 powerpc: add name_to_handle_at, open_by_handle etc. to bits/fcntl.h
Fixes BZ #14251.
2012-10-04 23:24:45 -04:00
Roland McGrath
9043e2288e Name space hygeine for madvise. 2012-10-04 16:31:43 -07:00
Roland McGrath
010188c6ea Remove sysdeps/unix/bsd/confstr.h file. 2012-10-03 13:43:58 -07:00
Roland McGrath
51367701af Get rid of unused __swblk_t type. 2012-10-01 14:39:29 -07:00
Roland McGrath
93c65d4384 Clean up init-first.c files. 2012-10-01 12:55:34 -07:00
Roland McGrath
ac51c94918 Move _G_config.h with Linuxism to linux/ directory. 2012-09-28 15:45:07 -07:00
Tulio Magno Quites Machado Filho
8ad11b9a9c Add __ppc_get_timebase_freq to ppc.h. 2012-09-25 16:53:14 -05:00
Siddhesh Poyarekar
9fab36eb58 Shrink heap on linux when overcommit_memory == 2
Using madvise with MADV_DONTNEED to release memory back to the kernel
is not sufficient to change the commit charge accounted against the
process on Linux.  It is OK however, when overcommit is enabled or is
heuristic.  However, when overcommit is restricted to a percentage of
memory setting the contents of /proc/sys/vm/overcommit_memory as 2, it
makes a difference since memory requests will fail.  Hence, we do what
we do with secure exec binaries, which is to call mmap on the region
to be dropped with MAP_FIXED. This internally unmaps the pages in
question and reduces the amount of memory accounted against the
process.
2012-09-25 14:30:52 +05:30
Joseph Myers
26889eacc2 Remove __ASSUME_POSIX_CPU_TIMERS. 2012-09-01 21:32:04 +00:00
Siddhesh Poyarekar
050af9c4e8 Don't make ttyname* fail if proc filesystem is not available
The ttyname and ttyname_r functions on Linux now fall back to
searching for the tty file descriptor in /dev/pts or /dev if /proc is
not available.  This allows creation of chroots without the procfs
mounted on /proc.

Fixes BZ #14516.
2012-08-29 10:04:23 +05:30
Joseph Myers
ad845c0be9 Remove __ASSUME_STAT64_SYSCALL. 2012-08-27 19:36:04 +00:00
Joseph Myers
4efcc02265 Make dl-fxstatat64.c include of fxstatat64.c use <> not "". 2012-08-23 11:34:37 +00:00
Roland McGrath
3cc3ef96d6 BZ#13696: Add --disable-nscd configure option. 2012-08-22 13:31:12 -07:00
Joseph Myers
0e1d99119e Remove __ASSUME_FADVISE64_64_SYSCALL. 2012-08-21 21:07:22 +00:00
Joseph Myers
a35cbf28fb Remove __ASSUME_SWAPCONTEXT_SYSCALL. 2012-08-20 14:39:53 +00:00
Joseph Myers
445f7ecd66 Define __ASSUME_UTIMES for s390. 2012-08-20 14:38:48 +00:00
Joseph Myers
348363b2c3 Remove __ASSUME_MMAP2_SYSCALL. 2012-08-20 14:37:27 +00:00
Andreas Krebbel
bc5bc0e510 S/390: Remove 32 bit getrlimit.c. 2012-08-20 15:10:13 +02:00
Mike Frysinger
fdab8fd335 update linux nice.c include path too after recent file shuffle
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-08-17 22:42:49 -04:00
Roland McGrath
e3b398f925 Adjust old #include's of sysdeps/unix/time.c to point to sysdeps/posix/time.c instead. 2012-08-17 14:16:12 -07:00
Roland McGrath
7c6f9d53c1 Move some things from sysdeps/unix to sysdeps/posix. 2012-08-17 13:52:32 -07:00
Roland McGrath
c31fdb83d2 Merge unix/inet/syscalls.list into unix/syscalls.list. 2012-08-17 12:56:33 -07:00
Roland McGrath
e66a42f57f Split sys/param.h out into common file and sysdeps bits/param.h file. 2012-08-17 09:55:17 -07:00
Joseph Myers
93a78ac437 Remove __ASSUME_POSIX_TIMERS. 2012-08-16 14:03:43 +00:00
Joseph Myers
f2c05b9ecf Remove __ASSUME_CLONE_THREAD_FLAGS. 2012-08-14 22:34:04 +00:00
Joseph Myers
121dce05fe Move Linux kernel version conditionals to kernel-features.h. 2012-08-10 15:53:27 +00:00
H.J. Lu
f85fa27058 Avoid DWARF definition DIE on ifunc symbols 2012-08-09 16:04:37 -07:00
Joseph Myers
b36137f1d6 Remove __ASSUME_TGKILL. 2012-08-08 23:22:53 +00:00
Roland McGrath
cdd915fd16 Missing #include updates for dirstream code move from unix to posix. 2012-08-08 09:18:37 -07:00
Joseph Myers
93df14eee8 Remove some pre-2.6.16 Linux kernel conditionals. 2012-08-07 23:03:35 +00:00
Roland McGrath
a281decc87 Move common dirent implementation from sysdeps/unix to sysdeps/posix. 2012-08-07 14:47:34 -07:00
Roland McGrath
22895b4767 Make the bsd4.4/bits/fcntl.h be the generic one. 2012-08-07 14:12:10 -07:00
Roland McGrath
707a53b600 Update bsd4.4/bits/fcntl.h to match modern NetBSD bits. 2012-08-07 14:10:37 -07:00
Roland McGrath
f0bd3e25fb Make the bsd4.4/bits/dirent.h be the generic one. 2012-08-07 13:17:26 -07:00
Roland McGrath
d34689de84 Define _DIRENT_MATCHES_DIRENT64 in bsd4.4/bits/dirent.h 2012-08-07 13:15:18 -07:00
Joseph Myers
6dad2c0688 Remove pre-2.6.16 Linux kernel support. 2012-08-07 16:40:32 +00:00
Roland McGrath
8e49df1d65 Clean up {alphasort,versionsort,scandir,scandirat}{,64} for struct dirent == struct dirent64. 2012-08-06 16:48:36 -07:00
Roland McGrath
03af952060 Clean up lockf64, fseeko64, ftello64, fgetpos64, fsetpos64 for off64_t == off_t. 2012-08-06 16:48:14 -07:00
H.J. Lu
3a31811ede Remove x32/iofopen.c and x32/iofopen64.c 2012-08-06 12:56:52 -07:00
Joseph Myers
85fe199795 Remove some pre-2.6.0 Linux kernel conditionals. 2012-08-03 19:54:08 +00:00
Joseph Myers
7aab07e4e5 Remove pre-2.6.0 Linux kernel support (bug 13717). 2012-08-03 13:42:47 +00:00
Marek Polacek
b67e9372b2 Get rid of ASM_TYPE_DIRECTIVE{,_PREFIX}. 2012-08-02 21:04:29 +02:00
Joseph Myers
23bddc0668 Remove __ASSUME_FCNTL64. 2012-08-01 21:27:58 +00:00
Joseph Myers
a9f1039f0a Remove __ASSUME_VFORK_SYSCALL (and some __NR_vfork conditionals). 2012-08-01 20:49:45 +00:00
Roland McGrath
cd97c96688 Clean up mkstemp64/mkostemp64 for O_LARGEFILE==0. 2012-08-01 10:42:38 -07:00
Roland McGrath
09c0ee5f8c BZ#14138: Move getrlimit (ugetrlimit) syscall to syscalls.list. 2012-08-01 10:25:11 -07:00
Florian Weimer
7e66ee5142 * posix/unistd.h (setuid, setreuid, seteuid, setresuid):
Declare with warn_unused_result.
	(setgid, setregid, setegid, setresgid): Likewise.
	* sysdeps/unix/sysv/linux/sys/fsuid.h (setfsuid, setfsgid):
	Likewise.
	* WUR-REPORT: Remove set*id functions.
2012-08-01 18:12:58 +02:00
Roland McGrath
bea9b19322 Fix lots of bitrot for stub configurations. 2012-07-30 16:34:33 -07:00
Andreas Jaeger
b1b2aaf8eb Merge Linux 3.5 ptrace changes
(__ptrace_eventcodes): Add new value PTRACE_EVENT_SECCOMP from Linux 3.5.
(__ptrace_setoptions): Add new value PTRACE_O_TRACESECCOMP, adjust PTRACE_O_MASK.
2012-07-26 13:13:26 +02:00