OSDN Git Service

android-x86/bionic.git
9 years agoMerge "Proper MB_CUR_MAX."
Dan Albert [Thu, 31 Jul 2014 00:14:42 +0000 (00:14 +0000)]
Merge "Proper MB_CUR_MAX."

9 years agoProper MB_CUR_MAX.
Dan Albert [Wed, 30 Jul 2014 17:53:48 +0000 (10:53 -0700)]
Proper MB_CUR_MAX.

Previously this was hard coded to 4. This is only the case for UTF-8
locales.

As a side effect, this properly reports C.UTF-8 as the default locale
instead of C.

Change-Id: I7c73cc8fe6ffac61d211cd5f75287e36de06f4fc

9 years agoMerge "Fix memchr with a zero length."
Christopher Ferris [Wed, 30 Jul 2014 23:25:50 +0000 (23:25 +0000)]
Merge "Fix memchr with a zero length."

9 years agoFix memchr with a zero length.
Christopher Ferris [Wed, 30 Jul 2014 23:06:56 +0000 (16:06 -0700)]
Fix memchr with a zero length.

The memchr implementation for 64 bit fails if these conditions occur:

- The buffer is 32 byte aligned.
- The buffer contains the character in the first byte.
- The count sent in is zero.

The function should return NULL, but it's not.

Bug: 16676625
Change-Id: Iab33cc7a8b79920350c72f054dff0e0a3cde69ce

9 years agoMerge "Use libunwindbacktrace for debug malloc code."
Christopher Ferris [Wed, 30 Jul 2014 02:16:16 +0000 (02:16 +0000)]
Merge "Use libunwindbacktrace for debug malloc code."

9 years agoUse libunwindbacktrace for debug malloc code.
Christopher Ferris [Fri, 25 Jul 2014 00:52:23 +0000 (17:52 -0700)]
Use libunwindbacktrace for debug malloc code.

Create a method of disabling the debug allocation code paths so that
it's possible to use the libunwindbacktrace library without any
modifications.

Use this path to create and destroy the maps for the process. It's not
stricly necessary in the init code since the symbols are not modified
until after the initialize calls.

Also, remove the debug_XXX source files that doesn't need to be in libc.so.

Fix the maps reading code since it was completely broken for 64 bit.

Bug: 16408686

Change-Id: I6b02ef6ce26fdb7a59ad1029e7cbba9accceb704

9 years agoMerge "Fix linkage of grantpt(3)."
Elliott Hughes [Tue, 29 Jul 2014 17:43:10 +0000 (17:43 +0000)]
Merge "Fix linkage of grantpt(3)."

9 years agoFix linkage of grantpt(3).
Elliott Hughes [Sat, 26 Jul 2014 00:24:00 +0000 (17:24 -0700)]
Fix linkage of grantpt(3).

Also clean up the implementation of all the pty functions, add tests,
and fix the stub implementations of ttyname(3) and ttyname_r(3).

Bug: https://code.google.com/p/android/issues/detail?id=58888
Change-Id: I0fb36438cd1abf8d4e87c29415f03db9ba13c3c2

9 years agoMerge "Remove declarations for things that don't exist."
Elliott Hughes [Wed, 30 Jul 2014 00:36:51 +0000 (00:36 +0000)]
Merge "Remove declarations for things that don't exist."

9 years agoRemove declarations for things that don't exist.
Elliott Hughes [Tue, 29 Jul 2014 23:43:55 +0000 (16:43 -0700)]
Remove declarations for things that don't exist.

The <grp.h> ones prevent gdb from building out of the box.

Change-Id: I0efbffad2215cfcd75b4d442dfc972444b51d97c

9 years agoMerge "Fix dlsym(3) to do breadth first search."
Dmitriy Ivanov [Tue, 29 Jul 2014 21:42:55 +0000 (21:42 +0000)]
Merge "Fix dlsym(3) to do breadth first search."

9 years agoFix dlsym(3) to do breadth first search.
Dmitriy Ivanov [Tue, 29 Jul 2014 00:32:20 +0000 (17:32 -0700)]
Fix dlsym(3) to do breadth first search.

  dlsym(3) with handle != RTLD_DEFAULT|RTLD_NEXT performs
  breadth first search through the dependency tree.

Bug: 16653281
Change-Id: I017a6975d1a62abb0218a7eb59ae4deba458e324

9 years agoMerge "Added a bionic systrace class and tracing to pthread_mutex.cpp."
Elliott Hughes [Tue, 29 Jul 2014 16:38:31 +0000 (16:38 +0000)]
Merge "Added a bionic systrace class and tracing to pthread_mutex.cpp."

9 years agoAdded a bionic systrace class and tracing to pthread_mutex.cpp.
Brigid Smith [Mon, 21 Jul 2014 22:38:06 +0000 (15:38 -0700)]
Added a bionic systrace class and tracing to pthread_mutex.cpp.

bionic_systrace.h contains an implementation of tracing that
can be used with systrace.py and its associated viewer.  pthread_mutex
now uses this tracing to track pthread_mutex contention, which can be
enabled by using the "bionic" command line option to systrace.

Bug: 15116468
Change-Id: I30ed5b377c91ca4c36568a0e647ddf95d4e4a61a

9 years agoMerge "Fix mips/mips64 build"
Dmitriy Ivanov [Tue, 29 Jul 2014 04:58:16 +0000 (04:58 +0000)]
Merge "Fix mips/mips64 build"

9 years agoFix mips/mips64 build
Dmitriy Ivanov [Tue, 29 Jul 2014 00:53:29 +0000 (17:53 -0700)]
Fix mips/mips64 build

 Add _start entry label to mips/mips64 linker begin.S

Change-Id: Idcdfc3391427b53880650798be0583a7ac022bcc

9 years agoMerge "Start hiding "private/bionic_time.h"."
Elliott Hughes [Fri, 25 Jul 2014 22:01:28 +0000 (22:01 +0000)]
Merge "Start hiding "private/bionic_time.h"."

9 years agoStart hiding "private/bionic_time.h".
Elliott Hughes [Fri, 25 Jul 2014 18:55:59 +0000 (11:55 -0700)]
Start hiding "private/bionic_time.h".

Bug: 15765976
Change-Id: Ibd9cf07067ec8dffe9fda6c3d498d4ab90708220

9 years agoMerge "en_US.UTF-8 is also supported."
Dan Albert [Fri, 25 Jul 2014 18:35:03 +0000 (18:35 +0000)]
Merge "en_US.UTF-8 is also supported."

9 years agoen_US.UTF-8 is also supported.
Dan Albert [Fri, 25 Jul 2014 18:24:03 +0000 (11:24 -0700)]
en_US.UTF-8 is also supported.

Change-Id: Ic35fad3596dc5e24ee8ae35543a274a471f27bb2

9 years agoMerge "Implement <sys/fsuid.h>."
Elliott Hughes [Wed, 30 Jul 2014 23:16:27 +0000 (23:16 +0000)]
Merge "Implement <sys/fsuid.h>."

9 years agoImplement <sys/fsuid.h>.
Elliott Hughes [Wed, 30 Jul 2014 22:05:09 +0000 (15:05 -0700)]
Implement <sys/fsuid.h>.

Change-Id: I1e5e50444a1b5a430ba5b5d9b8b1d91219af5e92

9 years agoMerge "[MIPSR6] Use C-coded string ops on mips32r6/mips64r6"
Elliott Hughes [Wed, 30 Jul 2014 22:15:43 +0000 (22:15 +0000)]
Merge "[MIPSR6] Use C-coded string ops on mips32r6/mips64r6"

9 years agoMerge "Only wipe TLS for user-supplied stacks."
Elliott Hughes [Wed, 30 Jul 2014 21:55:13 +0000 (21:55 +0000)]
Merge "Only wipe TLS for user-supplied stacks."

9 years agoOnly wipe TLS for user-supplied stacks.
Elliott Hughes [Wed, 30 Jul 2014 21:48:10 +0000 (14:48 -0700)]
Only wipe TLS for user-supplied stacks.

Bug: 16667988
Change-Id: Id180ab2bc6713e1612386120a306db5bbf1d6046

9 years agoMerge "[MIPS] Fix atomic_is_lock_free test for mips32. On 32-bit MIPS, 64-bit atomic...
Elliott Hughes [Thu, 24 Jul 2014 23:20:59 +0000 (23:20 +0000)]
Merge "[MIPS] Fix atomic_is_lock_free test for mips32. On 32-bit MIPS, 64-bit atomic ops are achieved through locks. So allow the test to fail for atomic_intmax_t on 32-bit MIPS."

9 years ago[MIPS] Fix atomic_is_lock_free test for mips32.
Raghu Gandham [Thu, 24 Jul 2014 22:56:51 +0000 (15:56 -0700)]
[MIPS] Fix atomic_is_lock_free test for mips32.
On 32-bit MIPS, 64-bit atomic ops are achieved through locks.
So allow the test to fail for atomic_intmax_t on 32-bit MIPS.

Change-Id: I78e7807e50f899a0fea0d5b388d9ebb53228aaa0

9 years agoMerge "Fix global variable initialization for linker"
Dmitriy Ivanov [Thu, 24 Jul 2014 23:09:17 +0000 (23:09 +0000)]
Merge "Fix global variable initialization for linker"

9 years agoFix global variable initialization for linker
Dmitriy Ivanov [Thu, 24 Jul 2014 22:33:25 +0000 (15:33 -0700)]
Fix global variable initialization for linker

 Linker now calls init functions for itself.

Change-Id: Ibd099812493041ac70f591e3f379ee742b4683b8

9 years agoMerge "Implement twalk(3), add unit tests."
Elliott Hughes [Thu, 24 Jul 2014 22:11:05 +0000 (22:11 +0000)]
Merge "Implement twalk(3), add unit tests."

9 years agoImplement twalk(3), add unit tests.
Elliott Hughes [Wed, 23 Jul 2014 23:02:26 +0000 (16:02 -0700)]
Implement twalk(3), add unit tests.

I've also added insque(3) and remque(3) (from NetBSD because the OpenBSD
ones are currently broken for non-circular lists).

I've not added the three hash table functions that should be in this header
because they operate on a single global hash table and thus aren't likely
to be useful.

Bug: https://code.google.com/p/android/issues/detail?id=73719
Change-Id: I97397a7b921e2e860fd9c8032cafd9097380498a

9 years ago[MIPSR6] Use C-coded string ops on mips32r6/mips64r6
Duane Sand [Thu, 10 Jul 2014 22:24:27 +0000 (15:24 -0700)]
[MIPSR6] Use C-coded string ops on mips32r6/mips64r6

The existing assembler code uses deprecated lwl/lwr/swl/swr ops.
Replacing those with misalignment-forgiving lw/sw ops may
involve careful performance tuning.

Change-Id: I47a042f7b22b87d7d52e46c29c44b1db1ba8b693

9 years agoMerge "[MIPSR6] setjmp supports mips32r6 and FP64A/FPXX reg models"
Elliott Hughes [Thu, 24 Jul 2014 03:57:12 +0000 (03:57 +0000)]
Merge "[MIPSR6] setjmp supports mips32r6 and FP64A/FPXX reg models"

9 years ago[MIPSR6] setjmp supports mips32r6 and FP64A/FPXX reg models
Duane Sand [Mon, 14 Jul 2014 22:30:14 +0000 (15:30 -0700)]
[MIPSR6] setjmp supports mips32r6 and FP64A/FPXX reg models

Save and restore floating point registers via 64-bit
load/stores when possible.  Use assembler's builtin macro
ops to generate pairs of 32-bit load/stores on Mips I cpus.

Some cpus or FR modes have only 16 even-numbered dp fp regs.
This is exposed by _MIPS_FPSET, defined by existing compilers.

Change-Id: I7f617a3ffea8da41c402ef3a68ab32c91d3d7622

9 years agoMerge "debuggerd: if PR_GET_DUMPABLE=0, don't ask for dumping"
Nick Kralevich [Wed, 23 Jul 2014 22:51:37 +0000 (22:51 +0000)]
Merge "debuggerd: if PR_GET_DUMPABLE=0, don't ask for dumping"

9 years agodebuggerd: if PR_GET_DUMPABLE=0, don't ask for dumping
Nick Kralevich [Wed, 23 Jul 2014 20:56:23 +0000 (13:56 -0700)]
debuggerd: if PR_GET_DUMPABLE=0, don't ask for dumping

PR_GET_DUMPABLE is used by an application to indicate whether or
not core dumps / PTRACE_ATTACH should work.

Security sensitive applications often set PR_SET_DUMPABLE to 0 to
disable core dumps, to avoid leaking sensitive memory to persistent
storage. Similarly, they also set PR_SET_DUMPABLE to zero to prevent
PTRACE_ATTACH from working, again to avoid leaking the contents
of sensitive memory.

Honor PR_GET_DUMPABLE when connecting to debuggerd. If an application
has said it doesn't want its memory dumped, then we shouldn't
ask debuggerd to dump memory on its behalf.

FORTIFY_SOURCE tests: Modify the fortify_source tests to set
PR_SET_DUMPABLE=0. This reduces the total runtime of
/data/nativetest/bionic-unit-tests/bionic-unit-tests32 from approx
53 seconds to 25 seconds. There's no need to connect to debuggerd
when running these tests.

Bug: 16513137
Change-Id: Idc7857b089f3545758f4d9b436b783d580fb653f

9 years agoMerge "Fix belated review comments on syslog change."
Elliott Hughes [Wed, 23 Jul 2014 20:07:38 +0000 (20:07 +0000)]
Merge "Fix belated review comments on syslog change."

9 years agoFix belated review comments on syslog change.
Elliott Hughes [Wed, 23 Jul 2014 18:38:38 +0000 (11:38 -0700)]
Fix belated review comments on syslog change.

Bug: 14292866
Change-Id: I3cd92084cb55b5673f6ba62d51952941b79deb51

9 years agoMerge "Fix 'adb shell /system/bin/linker' crash"
Dmitriy Ivanov [Mon, 28 Jul 2014 23:38:32 +0000 (23:38 +0000)]
Merge "Fix 'adb shell /system/bin/linker' crash"

9 years agoFix 'adb shell /system/bin/linker' crash
Dmitriy Ivanov [Mon, 28 Jul 2014 22:05:51 +0000 (15:05 -0700)]
Fix 'adb shell /system/bin/linker' crash

Bug: https://code.google.com/p/android/issues/detail?id=63174
Change-Id: I072290ea11109c07f277ad3dec7f44fcb7bf6aa6

9 years agoMerge "syscall(3)'s return type should be long."
Elliott Hughes [Mon, 28 Jul 2014 22:33:51 +0000 (22:33 +0000)]
Merge "syscall(3)'s return type should be long."

9 years agosyscall(3)'s return type should be long.
Elliott Hughes [Mon, 28 Jul 2014 19:24:22 +0000 (12:24 -0700)]
syscall(3)'s return type should be long.

This doesn't require us to change any of the syscall implementations
because (a) the LP32 ones have sizeof(int) == sizeof(long) anyway,
which is how we never noticed this bug before and (b) the LP64 ones
all use a 64-bit register for the result (and for the syscall number
too).

Bug: https://code.google.com/p/android/issues/detail?id=73952
Change-Id: I9866c3579a7a94de27bfbe80ad7a822c3183c7fb

9 years agoMerge "Remove localtime_tz and strftime_tz."
Elliott Hughes [Fri, 25 Jul 2014 23:19:40 +0000 (23:19 +0000)]
Merge "Remove localtime_tz and strftime_tz."

9 years agoRemove localtime_tz and strftime_tz.
Elliott Hughes [Fri, 25 Jul 2014 22:50:31 +0000 (15:50 -0700)]
Remove localtime_tz and strftime_tz.

This also brings our copy of strftime.c much closer to upstream, though
we still have several GNU extensions and hacks to deal with Android32's
broken time_t.

Bug: 15765976
Change-Id: Ic9ef36e8acd3619504ecc4d73feec2b61fd4dfa1

9 years agoMerge "Use vsnprintf(3) in syslog(3)."
Elliott Hughes [Mon, 28 Jul 2014 16:44:57 +0000 (16:44 +0000)]
Merge "Use vsnprintf(3) in syslog(3)."

9 years agoUse vsnprintf(3) in syslog(3).
Elliott Hughes [Sat, 26 Jul 2014 03:31:47 +0000 (20:31 -0700)]
Use vsnprintf(3) in syslog(3).

It seemed like a clever trick to use the internal log message formatting
code in syslog(3), but on reflection that means you can't (for example)
format floating point numbers. This patch switches us over to using good
old vsnprintf(3), even though that requires us to jump through a few hoops.

There's no obvious way to unit test this, so I wrote a little program and
ran that.

(cherry-pick of b1b60c30bf321c0fc02264b953b5c16c49d34457.)

Bug: 14292866
Change-Id: I9c83500ba9cbb209b6f496067a91bf69434eeef5

9 years agoMerge "[MIPS] Drop soft-fp targets"
Elliott Hughes [Thu, 24 Jul 2014 18:06:45 +0000 (18:06 +0000)]
Merge "[MIPS] Drop soft-fp targets"

9 years ago[MIPS] Drop soft-fp targets
Duane Sand [Thu, 24 Jul 2014 17:56:54 +0000 (10:56 -0700)]
[MIPS] Drop soft-fp targets

Change-Id: I583bf8242d3034ebfc48548499cdb3316094c8e3

9 years agoMerge "Fix generate-NOTICE to cope better with BSD __COPYRIGHT macros."
Elliott Hughes [Wed, 23 Jul 2014 18:34:15 +0000 (18:34 +0000)]
Merge "Fix generate-NOTICE to cope better with BSD __COPYRIGHT macros."

9 years agoFix generate-NOTICE to cope better with BSD __COPYRIGHT macros.
Elliott Hughes [Wed, 23 Jul 2014 18:10:48 +0000 (11:10 -0700)]
Fix generate-NOTICE to cope better with BSD __COPYRIGHT macros.

Change-Id: I99f9d2e0a28342663cec6aed483e1a23c12e5e87

9 years agoMerge "Fix a couple of bugs in generate-NOTICE and regenerate the NOTICE files."
Elliott Hughes [Wed, 23 Jul 2014 16:37:52 +0000 (16:37 +0000)]
Merge "Fix a couple of bugs in generate-NOTICE and regenerate the NOTICE files."

9 years agoFix a couple of bugs in generate-NOTICE and regenerate the NOTICE files.
Elliott Hughes [Wed, 23 Jul 2014 04:24:47 +0000 (21:24 -0700)]
Fix a couple of bugs in generate-NOTICE and regenerate the NOTICE files.

Change-Id: Id6fcb74292e661504d0758bfce24abdc18cb8d32

9 years agoMerge "Remove the unused swab.S."
Elliott Hughes [Wed, 23 Jul 2014 03:27:59 +0000 (03:27 +0000)]
Merge "Remove the unused swab.S."

9 years agoRemove the unused swab.S.
Elliott Hughes [Wed, 23 Jul 2014 03:21:31 +0000 (20:21 -0700)]
Remove the unused swab.S.

Change-Id: Id30eac5a21b649d6a039a0d7ca0496177fbfb571

9 years agoMerge "[MIPS] Allow united mipsel and mips64el gcc toolchain"
Elliott Hughes [Wed, 23 Jul 2014 02:39:15 +0000 (02:39 +0000)]
Merge "[MIPS] Allow united mipsel and mips64el gcc toolchain"

9 years ago[MIPS] Allow united mipsel and mips64el gcc toolchain
Duane Sand [Wed, 16 Jul 2014 19:29:34 +0000 (12:29 -0700)]
[MIPS] Allow united mipsel and mips64el gcc toolchain

Explicitly tell 32-bit links that they are doing 32-bit links.
This is needed when using united 32-bit and 64-bit toolchains.
This is harmless when using older separate 32-only toolchains.

Change-Id: I70cbd3f5867e59b1f6f829793444242fb0894aa6

9 years agoMerge "Use upstream OpenBSD's arc4random."
Elliott Hughes [Tue, 22 Jul 2014 01:59:20 +0000 (01:59 +0000)]
Merge "Use upstream OpenBSD's arc4random."

9 years agoUse upstream OpenBSD's arc4random.
Elliott Hughes [Fri, 18 Jul 2014 22:57:41 +0000 (15:57 -0700)]
Use upstream OpenBSD's arc4random.

The getentropy_linux.c is lightly modified to build on Android, but we're now
completely in sync with upstream OpenBSD's arc4random implementation.

Change-Id: If32229fc28aba908035fb38703190d41ddcabc95

10 years agoMerge "Rewrite syslog(3) to use Android logging."
Elliott Hughes [Tue, 22 Jul 2014 01:47:48 +0000 (01:47 +0000)]
Merge "Rewrite syslog(3) to use Android logging."

9 years agoRewrite syslog(3) to use Android logging.
Elliott Hughes [Mon, 21 Jul 2014 23:35:24 +0000 (16:35 -0700)]
Rewrite syslog(3) to use Android logging.

Since we don't have syslogd on Android and you can't run one on a non-rooted
device, it's more useful if syslog output just goes to the regular Android
logging system.

Bug: 14292866
Change-Id: Icee7f088b97f88ccbdaf471b98cbac7f19f9210a

9 years agoMerge "There is no _MIN for unsigned types."
Dan Albert [Tue, 22 Jul 2014 00:30:52 +0000 (00:30 +0000)]
Merge "There is no _MIN for unsigned types."

9 years agoThere is no _MIN for unsigned types.
Dan Albert [Tue, 22 Jul 2014 00:16:30 +0000 (17:16 -0700)]
There is no _MIN for unsigned types.

Change-Id: I49c38e51197b750210bdbf28c9cf6db30452a206

10 years agoMerge "Fix mbsrtowcs(3)'s handling of len parameter."
Dan Albert [Mon, 21 Jul 2014 18:47:05 +0000 (18:47 +0000)]
Merge "Fix mbsrtowcs(3)'s handling of len parameter."

9 years agoFix mbsrtowcs(3)'s handling of len parameter.
Dan Albert [Sun, 20 Jul 2014 18:51:26 +0000 (11:51 -0700)]
Fix mbsrtowcs(3)'s handling of len parameter.

The len parameter is a _maximum_ length. The previous code was treating
it as an exact length, causing the following typical call to fail:

    mbsrtowcs(out, &in, sizeof(out), state); // sizeof(out) > strlen(in)

Change-Id: I48e474fd54ea5f122bc168a4d74bfe08704f28cc

10 years agoMerge "__libc_fatal should print a newline to stderr."
Dan Albert [Mon, 21 Jul 2014 18:16:34 +0000 (18:16 +0000)]
Merge "__libc_fatal should print a newline to stderr."

9 years ago__libc_fatal should print a newline to stderr.
Dan Albert [Sun, 20 Jul 2014 18:49:46 +0000 (11:49 -0700)]
__libc_fatal should print a newline to stderr.

Change-Id: I088dc880d7488a65beac8cda95f530f3db41f112

10 years agoMerge "Clean up some misinformation around prctl."
Elliott Hughes [Fri, 18 Jul 2014 23:28:06 +0000 (23:28 +0000)]
Merge "Clean up some misinformation around prctl."

10 years agoClean up some misinformation around prctl.
Elliott Hughes [Fri, 18 Jul 2014 22:55:41 +0000 (15:55 -0700)]
Clean up some misinformation around prctl.

prctl shouldn't be in <unistd.h>.

Change-Id: I29609fc91c033e1ad143b75d9b4eb17aefbd63d6

10 years agoMerge "Use the mmap/munmap for allocation routines."
Christopher Ferris [Fri, 18 Jul 2014 22:05:48 +0000 (22:05 +0000)]
Merge "Use the mmap/munmap for allocation routines."

10 years agoUse the mmap/munmap for allocation routines.
Christopher Ferris [Fri, 18 Jul 2014 19:26:45 +0000 (12:26 -0700)]
Use the mmap/munmap for allocation routines.

To avoid any issues calling malloc related routines, use mmap/munmap.
Specifically, this avoids any problems when this is compiled into a
malloc debug shared library.

Change-Id: Iae2d197145da43dc103ad6024357d8cc2374378f

10 years agoMerge "Remove SIOCKILLADDR from <sys/socket.h>."
Elliott Hughes [Fri, 18 Jul 2014 00:17:29 +0000 (00:17 +0000)]
Merge "Remove SIOCKILLADDR from <sys/socket.h>."

10 years agoRemove SIOCKILLADDR from <sys/socket.h>.
Elliott Hughes [Fri, 18 Jul 2014 00:10:02 +0000 (17:10 -0700)]
Remove SIOCKILLADDR from <sys/socket.h>.

Change-Id: I6b64a9abe01c786a9ec26aee1517cb981a4860fb

10 years agoMerge "Remove PR_SET_TIMERSLACK_PID from <sys/prctl.h>."
Elliott Hughes [Fri, 18 Jul 2014 00:17:16 +0000 (00:17 +0000)]
Merge "Remove PR_SET_TIMERSLACK_PID from <sys/prctl.h>."

10 years agoRemove PR_SET_TIMERSLACK_PID from <sys/prctl.h>.
Elliott Hughes [Fri, 18 Jul 2014 00:12:35 +0000 (17:12 -0700)]
Remove PR_SET_TIMERSLACK_PID from <sys/prctl.h>.

Change-Id: Ie70f23c80e8473ac9617b74967d7c84709f5b00d

10 years agoMerge "Fix private/bionic_name_mem.h build breakage."
Elliott Hughes [Thu, 17 Jul 2014 22:09:56 +0000 (22:09 +0000)]
Merge "Fix private/bionic_name_mem.h build breakage."

10 years agoFix private/bionic_name_mem.h build breakage.
Elliott Hughes [Thu, 17 Jul 2014 22:09:17 +0000 (15:09 -0700)]
Fix private/bionic_name_mem.h build breakage.

Change-Id: I8fe9c63dbbb5911721ca56791c0bff4bdf403314

10 years agoMerge "Remove non-standard prctl constants from <sys/prctl.h>."
Elliott Hughes [Thu, 17 Jul 2014 21:35:59 +0000 (21:35 +0000)]
Merge "Remove non-standard prctl constants from <sys/prctl.h>."

10 years agoRemove non-standard prctl constants from <sys/prctl.h>.
Elliott Hughes [Thu, 17 Jul 2014 21:26:33 +0000 (14:26 -0700)]
Remove non-standard prctl constants from <sys/prctl.h>.

Also remove __bionic_name_mem which has exactly one caller, and is only
ever expected to be used in this one place.

Change-Id: I833744f91e887639f5b2d1269f966ee9032af207

10 years agoMerge "Define atomic_charN_t only if charN_t is supported."
Hans Boehm [Thu, 17 Jul 2014 00:41:03 +0000 (00:41 +0000)]
Merge "Define atomic_charN_t only if charN_t is supported."

10 years agoDefine atomic_charN_t only if charN_t is supported.
Hans Boehm [Wed, 16 Jul 2014 18:33:48 +0000 (11:33 -0700)]
Define atomic_charN_t only if charN_t is supported.

Some platform code is apparently compiled with switches that do
not support char16_t and char32_t.  This caused stdatomic.h to fail
to compile.  This CL makes stdatomic.h usable in those environments.

Change-Id: Ie5a17f20b8b545c97128d00605b4eabd2a6bfe3e

10 years agoMerge "ptrace(3) should be varargs."
Elliott Hughes [Wed, 16 Jul 2014 23:30:39 +0000 (23:30 +0000)]
Merge "ptrace(3) should be varargs."

10 years agoptrace(3) should be varargs.
Elliott Hughes [Wed, 16 Jul 2014 22:18:54 +0000 (15:18 -0700)]
ptrace(3) should be varargs.

Bug: 16352070
Change-Id: Ied72e6e79eaf912fc93fc49ae7637af321a31a59

10 years agoMerge "Use VDSO for clock_gettime(2) and gettimeofday(2)."
Elliott Hughes [Wed, 16 Jul 2014 21:28:18 +0000 (21:28 +0000)]
Merge "Use VDSO for clock_gettime(2) and gettimeofday(2)."

10 years agoUse VDSO for clock_gettime(2) and gettimeofday(2).
Elliott Hughes [Tue, 15 Jul 2014 23:53:13 +0000 (16:53 -0700)]
Use VDSO for clock_gettime(2) and gettimeofday(2).

Bug: 15387103
Change-Id: Ifc3608ea65060c1dc38120b10b6e79874f182a36

10 years agoMerge "Make sure not to construct illegal property names."
Christopher Ferris [Wed, 16 Jul 2014 02:27:11 +0000 (02:27 +0000)]
Merge "Make sure not to construct illegal property names."

10 years agoMake sure not to construct illegal property names.
Christopher Ferris [Wed, 16 Jul 2014 02:09:07 +0000 (19:09 -0700)]
Make sure not to construct illegal property names.

Change-Id: I37624e69aec51efd4291f076fb87af3f35d33025

10 years agoMerge "Add gen syscalls step to instructions."
Christopher Ferris [Wed, 16 Jul 2014 02:08:18 +0000 (02:08 +0000)]
Merge "Add gen syscalls step to instructions."

10 years agoAdd gen syscalls step to instructions.
Christopher Ferris [Wed, 16 Jul 2014 02:02:33 +0000 (19:02 -0700)]
Add gen syscalls step to instructions.

Also, fix incorrect path to some tools.

Change-Id: I409fc02d7077f0d2811d90be19550e70f5d73c0e

10 years agoMerge "Regenerate the syscalls list after the uapi update."
Elliott Hughes [Wed, 16 Jul 2014 02:06:40 +0000 (02:06 +0000)]
Merge "Regenerate the syscalls list after the uapi update."

10 years agoRegenerate the syscalls list after the uapi update.
Elliott Hughes [Wed, 16 Jul 2014 01:39:27 +0000 (18:39 -0700)]
Regenerate the syscalls list after the uapi update.

Change-Id: I117c5b18f735376dd3ab5061018dc7db9c046202

10 years agoMerge "Fix BIONIC_ROUND_UP_POWER_OF_2 for 64 bit."
Christopher Ferris [Tue, 15 Jul 2014 20:19:33 +0000 (20:19 +0000)]
Merge "Fix BIONIC_ROUND_UP_POWER_OF_2 for 64 bit."

10 years agoFix BIONIC_ROUND_UP_POWER_OF_2 for 64 bit.
Christopher Ferris [Tue, 15 Jul 2014 01:47:23 +0000 (18:47 -0700)]
Fix BIONIC_ROUND_UP_POWER_OF_2 for 64 bit.

There were two bugs here:

- For 64 bit values, this did not properly round up.
- The macro rounded to the power of 2 less than value, not to the power
  of 2 greater than value.

Change-Id: If8cb41536a9d2f5c1bc213676f1e67a7903a36b0

10 years agoMerge "Remove isascii_l(3)."
Dan Albert [Tue, 15 Jul 2014 00:24:28 +0000 (00:24 +0000)]
Merge "Remove isascii_l(3)."

10 years agoRemove isascii_l(3).
Dan Albert [Mon, 14 Jul 2014 22:48:02 +0000 (15:48 -0700)]
Remove isascii_l(3).

Had intended to remove this one before submitting the locale changes,
but forgot. It isn't a standard ctype function, so we don't need it.

Change-Id: Ie9c09fa6c61b1101b5992fa06da30e373a0c6bf7

10 years agoMerge "Fix visibility for a bunch more symbols."
Elliott Hughes [Mon, 14 Jul 2014 22:15:36 +0000 (22:15 +0000)]
Merge "Fix visibility for a bunch more symbols."

10 years agoFix visibility for a bunch more symbols.
Elliott Hughes [Mon, 14 Jul 2014 21:41:47 +0000 (14:41 -0700)]
Fix visibility for a bunch more symbols.

Bug: 11156955
Bug: 15291317
Change-Id: I664f25cce7c17085a101d6593d8e01525a1f6a90

10 years agoMerge "Implement rand/srand in terms of random/srandom."
Elliott Hughes [Mon, 14 Jul 2014 19:19:58 +0000 (19:19 +0000)]
Merge "Implement rand/srand in terms of random/srandom."

10 years agoImplement rand/srand in terms of random/srandom.
Elliott Hughes [Mon, 14 Jul 2014 18:57:03 +0000 (11:57 -0700)]
Implement rand/srand in terms of random/srandom.

Code developed for glibc or older versions of bionic might expect more
randomness than the BSD implementation provides.

Bug: 15829381
Change-Id: Ia5a908a816e0a5f0639f514107a6384a51ec157e

10 years agoMerge "Sync upstream-openbsd."
Elliott Hughes [Mon, 14 Jul 2014 19:15:32 +0000 (19:15 +0000)]
Merge "Sync upstream-openbsd."

10 years agoSync upstream-openbsd.
Elliott Hughes [Mon, 14 Jul 2014 18:22:59 +0000 (11:22 -0700)]
Sync upstream-openbsd.

Change-Id: I5b9961a57e2ff05f63bd218c130bf8347850b9be