Commit graph

11373 commits

Author SHA1 Message Date
Elliott Hughes
6f9d7444e8 Merge "Fix running the bionic benchmarks on the host." 2014-12-01 21:40:25 +00:00
Elliott Hughes
f2bb57cfe3 Fix running the bionic benchmarks on the host.
Bug: 18556607
Change-Id: I4e75bfcde788b43e1926be1b0146acf09b496390
2014-12-01 13:11:38 -08:00
Yabin Cui
3e6ef3f902 Merge "support _POSIX_CPUTIME" 2014-12-01 17:06:02 +00:00
David 'Digit' Turner
fabb4282be Merge "libc: Fix headers to allow direct inclusion." 2014-12-01 16:50:04 +00:00
David 'Digit' Turner
aad1a39dfb libc: Fix headers to allow direct inclusion.
These headers are missing a few #includes to allow their direct
inclusion from C

http://b.android.com/79841

Change-Id: Ifc712c17f4da70b26adb67d4d49ed659f53c3621
2014-12-01 15:44:24 +01:00
Elliott Hughes
7602628e97 Merge "Add error-check when mapping socket to fd" 2014-11-27 19:05:13 +00:00
Robert Alm
3638a83657 Add error-check when mapping socket to fd
The call to fdopen can fail in several ways.
The fprintf on the next line will then dereference a
NULL-pointer FILE*.
Added a NULL-check, closed the socket, returned system error
and added a comment about it.

Change-Id: I7a6b26aa3c79452b1fdd76af12dfa75da88cbad7
2014-11-27 11:01:50 -08:00
Elliott Hughes
4614032705 Merge "Move a private x86-64 header file out of the limelight." 2014-11-27 17:20:50 +00:00
Elliott Hughes
1b66f6e9d7 Move a private x86-64 header file out of the limelight.
Currently this is on everyone's include path and is getting exported
via the NDK.

Change-Id: Ia417839fb65c7e0afddcd9fae3438665dae8e752
2014-11-26 19:31:19 -08:00
Elliott Hughes
87516a6508 Merge "[MIPS] Rewrite of setjmp/longjmp for mips64 and mipsr6" 2014-11-27 02:28:50 +00:00
Elliott Hughes
cc0a9e6bdf Merge "bionic tests: add setjmp/_setjmp/sigsetjmp tests." 2014-11-27 01:33:09 +00:00
Yongqin Liu
9fea4090f1 bionic tests: add setjmp/_setjmp/sigsetjmp tests.
Bug: 17288973
Change-Id: I2808eee58cbddae1b16fbe19a715b72d6dbaaec3
Signed-off-by: Yongqin Liu <yongqin.liu@linaro.org>
2014-11-26 17:31:24 -08:00
Yabin Cui
d5c652756b support _POSIX_CPUTIME
Bug: 18490039
Change-Id: I01fa83b48e1b908de1f227b6e4f98e280bcd50ee
2014-11-26 17:14:50 -08:00
Nicolas Geoffray
f64c43ba6c Merge "Revert "Use mmap to create the pthread_internal_t."" 2014-11-26 11:57:46 +00:00
Nicolas Geoffray
5b8ceff5f8 Revert "Use mmap to create the pthread_internal_t."
Unfortunately, this change provokes random crashes for ART, and
I have seen libc crashes on the device that might be related to it.

Reverting it fixes the ART crashes. there is unfortunately no
stack trace for the crashes, but just a "Segmentation fault" message.


This reverts commit cc5f6543e3.

Change-Id: I68dca8e1e9b9edcce7eb84596e8db619e40e8052
2014-11-26 11:56:54 +00:00
Duane Sand
3a4786348e [MIPS] Rewrite of setjmp/longjmp for mips64 and mipsr6
Change-Id: Idcd13413520dd503bc9cf782553675313e500a83
2014-11-25 17:33:10 -08:00
Yabin Cui
4a6069a8af Merge "Use mmap to create the pthread_internal_t." 2014-11-25 23:53:44 +00:00
Yabin Cui
cc5f6543e3 Use mmap to create the pthread_internal_t.
Bug: 16847284
Change-Id: Ic8c85f95afac1d8422ecb69674c688d1fecb6a44
2014-11-25 15:25:06 -08:00
Yabin Cui
eb3a5e026e Merge "flesh out sysconf(3) and the _POSIX_* constants" 2014-11-24 01:59:23 +00:00
Elliott Hughes
95a02366f2 Merge "Sync with upstream OpenBSD fts.c." 2014-11-23 18:06:29 +00:00
Dan Albert
806dd9f90c Merge "Move some pthread functions to signal.h." 2014-11-22 22:38:51 +00:00
Elliott Hughes
2818279ace Sync with upstream OpenBSD fts.c.
Change-Id: Ia7e26b603f6461095b5a8d7e8a6cdf4f8279fa84
2014-11-21 19:27:28 -08:00
Yabin Cui
1c19194c9d flesh out sysconf(3) and the _POSIX_* constants
Bug: 17571891
Change-Id: I81036615486bde65969ae5662587fcc88348474e
2014-11-21 19:10:52 -08:00
Elliott Hughes
d77c1ec90a Merge "Bring our <machine/endian.h> files back in sync." 2014-11-22 02:41:44 +00:00
Elliott Hughes
ee369fb319 Bring our <machine/endian.h> files back in sync.
They'd drifted slightly which led to a compilation error in toybox,
which was assuming pid_t was defined. arm and arm64 were picking it
up via <endian.h> but x86 wasn't.

Change-Id: I58401e6c0066959dfc3b305b020876aaf7074bbf
2014-11-21 18:34:36 -08:00
Dmitriy Ivanov
80838f190a Merge "Mips: remove arch-specific atexit.h" 2014-11-21 22:59:07 +00:00
Dmitriy Ivanov
4ae178f81d Mips: remove arch-specific atexit.h
Change-Id: I687ff4ead6c5e81db44782bf851cb84f87bfe085
2014-11-21 14:42:53 -08:00
Dmitriy Ivanov
ff1c25262d Merge "Mips: Remove unused files" 2014-11-21 22:38:47 +00:00
Dmitriy Ivanov
e3e8d15f23 Mips: Remove unused files
Change-Id: If98b832ee32f6dcd9f5d7ae21c601c210adfad6b
2014-11-21 14:29:43 -08:00
Dmitriy Ivanov
6b1230b576 Merge "Mips: Reuse atexit.h from libc/arch-common" 2014-11-21 21:17:19 +00:00
Dmitriy Ivanov
c619603a31 Mips: Reuse atexit.h from libc/arch-common
Change-Id: Ica1670e6d3d1b6b0c64df93720efa65586e67727
2014-11-21 13:07:36 -08:00
Dan Albert
66ca82495c Merge "Revert "<sched.h> should offer both __sched_priority and sched_priority."" 2014-11-21 20:15:55 +00:00
Dan Albert
75ef63d6cf Move some pthread functions to signal.h.
POSIX specifies that pthread_kill(3) and pthread_sigmask(3) are
supposed to live in signal.h rather than pthread.h.

Since signal.h now needs pthread_t and pthread_attr_t, I've moved
those defintions into include/machine/pthread_types.h to keep the
namespace clean. I also sorted some includes. The combination of these
two things seems to have exploded into a cascade of missing includes,
so this patch also cleans up all those.

Change-Id: Icfa92a39432fe83f542a797e5a113289d7e4ad0c
2014-11-21 10:26:09 -08:00
Dan Albert
f664034887 Revert "<sched.h> should offer both __sched_priority and sched_priority."
This was only ever added to keep strace compiling, but strace has
since (actually, prior) fixed their source to use the less ugly name,
so we don't need this anymore (good riddance, #define!).

This reverts commit bbb34f9536.
2014-11-21 10:24:40 -08:00
Dmitriy Ivanov
a847073a05 Merge "Rename test_forked -> test_isolated" 2014-11-21 16:02:43 +00:00
Dmitriy Ivanov
0864d8bc47 Rename test_forked -> test_isolated
Change-Id: Ie72627e986c159832cbd3635d8ff5b1af3d5b1eb
2014-11-20 22:53:59 -08:00
Dmitriy Ivanov
8b4b827338 Merge "Add test_forked() option" 2014-11-21 01:21:16 +00:00
Dmitriy Ivanov
00e37818a7 Add test_forked() option
Executing test via test_forked() allows us to
 avoid undesired global state changes in tests like
 atexit, dlopen(.., RTLD_NODELETE) and similar.

Change-Id: I118cdf009269ab5dd7b117c9b61dafa47de2a011
2014-11-20 17:11:06 -08:00
Elliott Hughes
770198d3f7 Merge "Make the ftw(3) tests a bit more thorough." 2014-11-20 00:09:32 +00:00
Elliott Hughes
5313c3ff89 Merge "Fix flockfile(3) and friends for stdin/stdout/stderr too." 2014-11-19 23:48:19 +00:00
Elliott Hughes
63bd43bbdc Make the ftw(3) tests a bit more thorough.
These also test much of fts(3).

Change-Id: Ia9245d6acbbd071191563ab1b91a400044104028
2014-11-19 15:47:53 -08:00
Elliott Hughes
c48c3e4bb3 Fix flockfile(3) and friends for stdin/stdout/stderr too.
stdin/stdout/stderr are special; their mutexes are initialized by
__sinit. There's no unit test for this, because __sinit has already
been called by the time the first unit test runs, but you could
reproduce this failure with a trivial main() that calls flockfile
or ftrylockfile on one of the standard streams before otherwise
using stdio.

Bug: 18208568
Change-Id: I28d232cf05a9f198a2bed61854d8047b23d2091d
2014-11-19 15:16:51 -08:00
Dmitriy Ivanov
6b48b20a1e Merge "Yet another relocation test" 2014-11-19 19:35:59 +00:00
Dmitriy Ivanov
7699d13a74 Yet another relocation test
This time we check if a -> b -> c function in 'a' relocates against
 implementation in 'c'.

Change-Id: I528180c3efd346bd447ea0237e5a8a0ac3cc031f
2014-11-19 10:39:05 -08:00
David 'Digit' Turner
c9278b8a17 Merge "libc: Move <sgidefs.h> to libc/arch-mips/" 2014-11-19 14:49:52 +00:00
Yabin Cui
649f78df79 Merge "fix shared gid support in getpwnam/getgrnam" 2014-11-19 04:25:24 +00:00
Yabin Cui
a04c79b9d3 fix shared gid support in getpwnam/getgrnam
Bug: 18374693
Change-Id: I5353403cbbead6f6abac87bee2cf53a60dba408c
2014-11-18 19:58:04 -08:00
Dmitriy Ivanov
27aa9c5b50 Merge "Fix jump to unmapped memory on atexit" 2014-11-18 21:25:37 +00:00
Dmitriy Ivanov
a2547055f2 Fix jump to unmapped memory on atexit
Split d-tor calls and soinfo_free to 2 separate steps

Bug: 18338888
Change-Id: Idbcb7242ade16fa18cba7fe30505ebd8d6023622
2014-11-18 13:16:27 -08:00
David 'Digit' Turner
6e50cb4544 libc: Move <sgidefs.h> to libc/arch-mips/
This is a MIPS-only header, and should not be part of the common
headers. See http://b.android.com/79841 for context.

Change-Id: I610bc3ff626b57e7854dad15a4a2f67e1e5ded75
2014-11-18 20:13:10 +01:00