OSDN Git Service

android-x86/bionic.git
7 years agoDon't receive structs containing pointers over sockets. lollipop-x86
Elliott Hughes [Thu, 13 Nov 2014 01:00:30 +0000 (17:00 -0800)]
Don't receive structs containing pointers over sockets.

Fixes x86-64 netd.

Change-Id: Iee5ef802ebbf2e000b2593643de4eec46f296c04

9 years agoadd syscalls ioperm and iopl
Chih-Wei Huang [Fri, 27 Feb 2015 11:11:35 +0000 (19:11 +0800)]
add syscalls ioperm and iopl

9 years agochange PROP_NAME_MAX to 128
Chih-Wei Huang [Tue, 30 Jun 2009 09:43:31 +0000 (17:43 +0800)]
change PROP_NAME_MAX to 128

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Wed, 4 Feb 2015 14:08:53 +0000 (06:08 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoFixes to the update-tzdata.py tool
Neil Fuller [Mon, 2 Feb 2015 16:50:05 +0000 (16:50 +0000)]
Fixes to the update-tzdata.py tool

We build one too many times. Creating a missing directory
is sufficient.

The tz2icu needs some files in the CWD. Added symlinks.

Bug: 19230091
(cherry-pick of commit 0662c3e5b33840e19f4c14b85bf619c33b3a0d0f)
Change-Id: Ie21d848f1b776ec745473b9122e003fdf0acf105

9 years agoUpdate tzdata to tzdata2015a
Neil Fuller [Mon, 2 Feb 2015 11:24:22 +0000 (11:24 +0000)]
Update tzdata to tzdata2015a

Time Zone Data v. 2015a (Released 2015-01-29)
http://www.iana.org/time-zones/repository/releases/tzdata2015a.tar.gz

Information from NEWS:

Release 2015a - 2015-01-29 22:35:20 -0800

  Changes affecting future time stamps

    The Mexican state of Quintana Roo, represented by America/Cancun,
    will shift from Central Time with DST to Eastern Time without DST
    on 2015-02-01 at 02:00.  (Thanks to Steffen Thorsen and Gwillim Law.)

    Chile will not change clocks in April or thereafter; its new standard time
    will be its old daylight saving time.  This affects America/Santiago,
    Pacific/Easter, and Antarctica/Palmer.  (Thanks to Juan Correa.)

    New leap second 2015-06-30 23:59:60 UTC as per IERS Bulletin C 49.
    (Thanks to Tim Parenti.)

  Changes affecting past time stamps

    Iceland observed DST in 1919 and 1921, and its 1939 fallback
    transition was Oct. 29, not Nov. 29.  Remove incorrect data from
    Shanks about time in Iceland between 1837 and 1908.

    Some more zones have been turned into links, when they differed
    from existing zones only for older time stamps.  As usual,
    these changes affect UTC offsets in pre-1970 time stamps only.
    Their old contents have been moved to the 'backzone' file.
    The affected zones are: Asia/Aden, Asia/Bahrain, Asia/Kuwait,
    and Asia/Muscat.

  Changes affecting code

    tzalloc now scrubs time zone abbreviations compatibly with the way
    that tzset always has, by replacing invalid bytes with '_' and by
    shortening too-long abbreviations.

    tzselect ports to POSIX awk implementations, no longer mishandles
    POSIX TZ settings when GNU awk is used, and reports POSIX TZ
    settings to the user.  (Thanks to Stefan Kuhn.)

  Changes affecting build procedure

    'make check' now checks for links to links in the data.
    One such link (for Africa/Asmera) has been fixed.
    (Thanks to Stephen Colebourne for pointing out the problem.)

  Changes affecting commentary

    The leapseconds file commentary now mentions the expiration date.
    (Problem reported by Martin Burnicki.)

    Update Mexican Library of Congress URL.

Bug: 19212588
Change-Id: Idc07ac862901500d4a1dbd0f4aadcfd0aa9d10b8

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Thu, 8 Jan 2015 17:31:57 +0000 (09:31 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoPrint error when prelink fails for main executable
Dmitriy Ivanov [Wed, 7 Jan 2015 19:16:58 +0000 (11:16 -0800)]
Print error when prelink fails for main executable

Bug: 18931021
Change-Id: Ieefdcf60f1506af522714300030754a4ed61c08e

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Mon, 8 Dec 2014 14:09:01 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoRestore symbols from <arpa/nameser.h>.
Elliott Hughes [Thu, 4 Dec 2014 20:39:46 +0000 (12:39 -0800)]
Restore symbols from <arpa/nameser.h>.

Bug: 18627252
Bug: https://code.google.com/p/android/issues/detail?id=81690

(cherry picked from commit 42804c4b30e813d3140cba877d3ae6bbef0d3a17)

Change-Id: Idd33578b31bba9a4afdfd15c7b193d10974aea90

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Wed, 3 Dec 2014 14:08:43 +0000 (06:08 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoAvoid pathological behavior in OpenBSD's fread.
Elliott Hughes [Tue, 2 Dec 2014 00:13:30 +0000 (16:13 -0800)]
Avoid pathological behavior in OpenBSD's fread.

(cherry picked from commit 20841a137beac5caa824e3586c7bd91d879ff92e)

Bug: https://code.google.com/p/android/issues/detail?id=81155
Bug: 18556607
Change-Id: Ibdfebc20dce4c34ad565014523c9b074e90ea665

9 years agoMerge "Put stdin/stdout/stderr symbols in place." into lmp-mr1-dev
Elliott Hughes [Tue, 2 Dec 2014 18:56:49 +0000 (18:56 +0000)]
Merge "Put stdin/stdout/stderr symbols in place." into lmp-mr1-dev

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Tue, 2 Dec 2014 14:08:56 +0000 (06:08 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoPut stdin/stdout/stderr symbols in place.
Elliott Hughes [Tue, 2 Dec 2014 05:27:59 +0000 (21:27 -0800)]
Put stdin/stdout/stderr symbols in place.

To help with future binary compatibility.

Bug: 18553223
Change-Id: Ia8103b4f189c18528b11948ac9e520f61b9ccc0e

9 years agoFail queries fast if no DNS servers are configured.
Lorenzo Colitti [Fri, 28 Nov 2014 11:03:23 +0000 (20:03 +0900)]
Fail queries fast if no DNS servers are configured.

When no DNS servers are configured (and thus there is no chance
that the DNS query will suceed), res_nsend returns early, but
it does not tell the cache that the query has failed.
Therefore, if the caller retries the query, it will block for
PENDING_REQUEST_TIMEOUT (= 20 seconds) waiting for the "existing
query" (which isn't actually doing anything) to complete.

Bug: 18240188
Bug: 18327075
Change-Id: I0df13ff4a17ee65e640be96695a3af31b020963a

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Mon, 24 Nov 2014 14:09:01 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoFix flockfile(3) and friends for stdin/stdout/stderr too.
Elliott Hughes [Wed, 19 Nov 2014 23:16:51 +0000 (15:16 -0800)]
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

(cherry picked from commit c48c3e4bb3d1665f3e9fa2785daafa72dfe59399)

Change-Id: Ia0c43ed4ac69daea8152aee9516415a6e3f8a042

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Tue, 18 Nov 2014 14:09:23 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Mon, 17 Nov 2014 14:09:15 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agosysconf(3) returns long.
Elliott Hughes [Fri, 14 Nov 2014 23:14:44 +0000 (15:14 -0800)]
sysconf(3) returns long.

On LP32, this makes no difference. Not an ABI change.

On LP64, results are going to be in %rax or x0 whether they're 32- or 64-bit,
and the only difference is going to be whether the top bits are clobbered.

(cherry picked from commit 60d84af1726225320b26683b726e5e735d9d76e8)

Bug: 18390956
Change-Id: I722461498bc5494e2972fb07d5189dffe76e8993

9 years agobionic: libc: Added path to vendor build properties file.
Daniel Rosenberg [Tue, 11 Nov 2014 00:59:57 +0000 (16:59 -0800)]
bionic: libc: Added path to vendor build properties file.

Signed-off-by: Daniel Rosenberg <drosen@google.com>
(cherry picked from commit 71d220c1de1372e20c8bbec4ccf387991a3bb549)

Bug: 18281574
Change-Id: I2843f23ecb4c4ca79b230d8041bbca02dbedeadc

9 years agomerge in lmp-mr1-release history after reset to lmp-mr1-dev
The Android Automerger [Thu, 13 Nov 2014 14:10:24 +0000 (06:10 -0800)]
merge in lmp-mr1-release history after reset to lmp-mr1-dev

9 years agoMerge "Fix tzdata update tools for 'backzone'." into lmp-mr1-dev
Elliott Hughes [Wed, 12 Nov 2014 17:19:56 +0000 (17:19 +0000)]
Merge "Fix tzdata update tools for 'backzone'." into lmp-mr1-dev

9 years agoUpgrade bionic to tzdata2014j.
Elliott Hughes [Wed, 12 Nov 2014 00:44:21 +0000 (16:44 -0800)]
Upgrade bionic to tzdata2014j.

From the release notes:

   Changes affecting current and future time stamps

     Turks & Caicos' switch from US eastern time to UTC-4 year-round
     did not occur on 2014-11-02 at 02:00.  It's currently scheduled
     for 2015-11-01 at 02:00.  (Thanks to Chris Walton.)

   Changes affecting past time stamps

     Many pre-1989 time stamps have been corrected for Asia/Seoul and
     Asia/Pyongyang, based on sources for the Korean-language Wikipedia
     entry for time in Korea.  (Thanks to Sanghyuk Jung.)  Also, no
     longer guess that Pyongyang mimicked Seoul time after World War II,
     as this is politically implausible.

     Some more zones have been turned into links, when they differed
     from existing zones only for older time stamps.  As usual,
     these changes affect UTC offsets in pre-1970 time stamps only.
     Their old contents have been moved to the 'backzone' file.
     The affected zones are: Africa/Addis_Ababa, Africa/Asmara,
     Africa/Dar_es_Salaam, Africa/Djibouti, Africa/Kampala,
     Africa/Mogadishu, Indian/Antananarivo, Indian/Comoro, and
     Indian/Mayotte.

Bug: 18330681

(cherry picked from commit b11d8e057c86c3926128af9d07180d9328e144c6)

Change-Id: Ifd48e7446e400dccae3afd5cbef96ca843775477

9 years agoFix tzdata update tools for 'backzone'.
Elliott Hughes [Tue, 11 Nov 2014 22:10:51 +0000 (14:10 -0800)]
Fix tzdata update tools for 'backzone'.

To maintain the status quo, we need to pull in backzone file. This file
can't be built on its own, so the easiest fix is to give zic(1) all the
files at once.

We also now have a situation where we have links to links, so we need to
dereference them until we find actual data.

Bug: 18330681

(cherry picked from commit 2c2463bd3065f0a5fef34a47e3eb94aad64b0cea)

Change-Id: I654b80518a7144038d8b3ea7223f49e2b1d2ad13

9 years agomerge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36
The Android Automerger [Sat, 8 Nov 2014 14:09:36 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36

9 years agomerge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36
The Android Automerger [Thu, 6 Nov 2014 14:09:56 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36

9 years agomerge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36
The Android Automerger [Wed, 5 Nov 2014 14:09:40 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to 9d3382d97a2cdc8c8f78c7825ece16f09292fc36

9 years agoRevert "Fix dlsym() to take into account RTLD_GLOBAL/LOCAL"
Dmitriy Ivanov [Tue, 4 Nov 2014 06:12:19 +0000 (22:12 -0800)]
Revert "Fix dlsym() to take into account RTLD_GLOBAL/LOCAL"

This reverts commit c85e82dde5c4b2accc50a9e17740b9005dfbae6a.

Bug: 18222321
Bug: 18211780
Change-Id: I32f4048bd5ea85dc8a3dfccce8cf141b241ab692

9 years agoRevert "Add RTLD_NODELETE flag support"
Dmitriy Ivanov [Tue, 4 Nov 2014 06:08:31 +0000 (22:08 -0800)]
Revert "Add RTLD_NODELETE flag support"

This reverts commit c87f65d2cd0690d81665f8b241c1d763f72b6f80.

Bug: 18222321
Bug: 18211780
Change-Id: I00252e26a28a41ab9f1e2dd3b32f0f80d86297f1

9 years agoRevert "Fix relocation to look for symbols in local group"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:15:25 +0000 (21:15 -0800)]
Revert "Fix relocation to look for symbols in local group"

This reverts commit fd2747bb585fc51b5ad56db09c0e9b66c7091a92.

Bug: 18222321
Bug: 18211780
Change-Id: I2d4ebab1e73b7277161af76b99f8249825b22d65

9 years agoRevert "Remove unnecessary lookups during relocations"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:15:15 +0000 (21:15 -0800)]
Revert "Remove unnecessary lookups during relocations"

This reverts commit 6442dbd3bcadbd5e522465743a8d8cf56338ae1c.

Bug: 18222321
Bug: 18211780
Change-Id: I87b18a32238a1f75afe56149221b6691f50d9f56

9 years agoRevert "Fix mips build"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:14:31 +0000 (21:14 -0800)]
Revert "Fix mips build"

This reverts commit bf3d5ef5fd240d4c5fbde1b32f9084dbc720840b.

Bug: 18222321
Bug: 18211780
Change-Id: I902ed888197b358c77303f1acb6d5ffd7ae6dcd3

9 years agoRevert "Fix symbol lookup order during relocation"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:14:07 +0000 (21:14 -0800)]
Revert "Fix symbol lookup order during relocation"

This reverts commit 976402cca13a1f4f3aa988fd301575e134ef5f2c.

Bug: 18222321
Bug: 18211780
Change-Id: Iafdd3d843db7b1cf288be9a0232022816622c944

9 years agoRevert "Fix arm64 and arm builds."
Dmitriy Ivanov [Tue, 4 Nov 2014 05:13:55 +0000 (21:13 -0800)]
Revert "Fix arm64 and arm builds."

This reverts commit 445111a1c977e94a4233efd54f3690defa4a7582.

Bug: 18222321
Bug: 18211780
Change-Id: I4fa9e1b63ec9b528f8bfed73c2ec15046c43a2fe

9 years agomerge in lmp-mr1-release history after reset to d18f4b25785761c022906b93b2123b3be90182e8
The Android Automerger [Tue, 4 Nov 2014 14:09:42 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to d18f4b25785761c022906b93b2123b3be90182e8

9 years agoRevert "Fix dlsym() to take into account RTLD_GLOBAL/LOCAL"
Dmitriy Ivanov [Tue, 4 Nov 2014 06:12:19 +0000 (22:12 -0800)]
Revert "Fix dlsym() to take into account RTLD_GLOBAL/LOCAL"

This reverts commit c85e82dde5c4b2accc50a9e17740b9005dfbae6a.

Bug: 18222321
Bug: 18211780
Change-Id: I32f4048bd5ea85dc8a3dfccce8cf141b241ab692

9 years agoRevert "Add RTLD_NODELETE flag support"
Dmitriy Ivanov [Tue, 4 Nov 2014 06:08:31 +0000 (22:08 -0800)]
Revert "Add RTLD_NODELETE flag support"

This reverts commit c87f65d2cd0690d81665f8b241c1d763f72b6f80.

Bug: 18222321
Bug: 18211780
Change-Id: I00252e26a28a41ab9f1e2dd3b32f0f80d86297f1

9 years agoRevert "Fix relocation to look for symbols in local group"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:15:25 +0000 (21:15 -0800)]
Revert "Fix relocation to look for symbols in local group"

This reverts commit fd2747bb585fc51b5ad56db09c0e9b66c7091a92.

Bug: 18222321
Bug: 18211780
Change-Id: I2d4ebab1e73b7277161af76b99f8249825b22d65

9 years agoRevert "Remove unnecessary lookups during relocations"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:15:15 +0000 (21:15 -0800)]
Revert "Remove unnecessary lookups during relocations"

This reverts commit 6442dbd3bcadbd5e522465743a8d8cf56338ae1c.

Bug: 18222321
Bug: 18211780
Change-Id: I87b18a32238a1f75afe56149221b6691f50d9f56

9 years agoRevert "Fix mips build"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:14:31 +0000 (21:14 -0800)]
Revert "Fix mips build"

This reverts commit bf3d5ef5fd240d4c5fbde1b32f9084dbc720840b.

Bug: 18222321
Bug: 18211780
Change-Id: I902ed888197b358c77303f1acb6d5ffd7ae6dcd3

9 years agoRevert "Fix symbol lookup order during relocation"
Dmitriy Ivanov [Tue, 4 Nov 2014 05:14:07 +0000 (21:14 -0800)]
Revert "Fix symbol lookup order during relocation"

This reverts commit 976402cca13a1f4f3aa988fd301575e134ef5f2c.

Bug: 18222321
Bug: 18211780
Change-Id: Iafdd3d843db7b1cf288be9a0232022816622c944

9 years agoRevert "Fix arm64 and arm builds."
Dmitriy Ivanov [Tue, 4 Nov 2014 05:13:55 +0000 (21:13 -0800)]
Revert "Fix arm64 and arm builds."

This reverts commit 445111a1c977e94a4233efd54f3690defa4a7582.

Bug: 18222321
Bug: 18211780
Change-Id: I4fa9e1b63ec9b528f8bfed73c2ec15046c43a2fe

9 years agoEnsure we initialize stdin/stdout/stderr's recursive mutexes.
Elliott Hughes [Mon, 3 Nov 2014 20:32:17 +0000 (12:32 -0800)]
Ensure we initialize stdin/stdout/stderr's recursive mutexes.

(cherry-pick of 6a03abcfd23f31d1df06eb0059830e22621282bb.)

Bug: 18208568
Change-Id: I9da16ce0f9375bc363d1d02be706d73fd3b1e150

9 years agomerge in lmp-mr1-release history after reset to 445111a1c977e94a4233efd54f3690defa4a7582
The Android Automerger [Mon, 3 Nov 2014 14:09:01 +0000 (06:09 -0800)]
merge in lmp-mr1-release history after reset to 445111a1c977e94a4233efd54f3690defa4a7582

9 years agomerge in lmp-mr1-release history after reset to 445111a1c977e94a4233efd54f3690defa4a7582
The Android Automerger [Sun, 2 Nov 2014 14:08:55 +0000 (06:08 -0800)]
merge in lmp-mr1-release history after reset to 445111a1c977e94a4233efd54f3690defa4a7582

9 years agomerge in lmp-mr1-release history after reset to 653263a96459c5c1811623bd84201c324a870280
The Android Automerger [Sat, 1 Nov 2014 13:09:02 +0000 (06:09 -0700)]
merge in lmp-mr1-release history after reset to 653263a96459c5c1811623bd84201c324a870280

9 years agoFix arm64 and arm builds.
Dmitriy Ivanov [Sat, 1 Nov 2014 00:27:02 +0000 (17:27 -0700)]
Fix arm64 and arm builds.

Bug: 18186310

(cherry picked from commit 4e446b19d8710cd2004785db4a00f18f249fe73f)

Change-Id: Ibc77a9ade36dc6b9bf5a316b5ab9ae5f0a70e826

9 years agoFix symbol lookup order during relocation
Dmitriy Ivanov [Thu, 28 Aug 2014 21:12:12 +0000 (14:12 -0700)]
Fix symbol lookup order during relocation

  Relocate symbol against DF_1_GLOBAL shared libraries
  loaded before this shared library. This includes
  main executable, ld_preloads and other libraries
  that have DF_1_GLOBAL flag set.

Bug: 2643900
Bug: 15432753
Bug: 18186310

(cherry picked from commit d225a5e65223b375a63548c4b780f04d8f3d7b60)

Change-Id: I4e889cdf2dfbf8230b0790053d311ee6b0d0ee2d

9 years agoFix mips build
Dmitriy Ivanov [Thu, 23 Oct 2014 21:34:12 +0000 (14:34 -0700)]
Fix mips build

Bug: 18186310

(cherry picked from commit 90b74fb8671db6f5512821a033e12a6248e5c804)

Change-Id: I8d4ed254e5c421b65b62c401abdb1ee07e5dc3b2

9 years agoRemove unnecessary lookups during relocations
Dmitriy Ivanov [Thu, 23 Oct 2014 21:19:07 +0000 (14:19 -0700)]
Remove unnecessary lookups during relocations

  local_group includes this library and its dependencies.

Bug: 18186310

(cherry picked from commit e47b3f8456fc34ac136e9fddef59a9ae37febcbe)

Change-Id: I93c2d873e924df7319569307444bf603d7d27bf0

9 years agoFix relocation to look for symbols in local group
Dmitriy Ivanov [Tue, 21 Oct 2014 16:23:18 +0000 (09:23 -0700)]
Fix relocation to look for symbols in local group

  The local group is a sequence of libraries in default (breadth-first)
  order. It allows RTLD_LOCALLY loaded library to correctly relocate
  symbols within its group (see test-cases).

  Local group lookup is performed after main executable and ld_preloads.

Bug: 2643900
Bug: 15432753
Bug: 18186310

(cherry picked from commit cfa97f172dc1b10d650fefbb6ccffd88ce72a5fb)

Change-Id: I5fa8c673f929e4652c738912c7ae078d7ec286d2

9 years agoCorrect way to specify additional dependencies
Dmitriy Ivanov [Fri, 17 Oct 2014 18:47:18 +0000 (11:47 -0700)]
Correct way to specify additional dependencies

 Previous one was not covering all the targets

Bug: 17548097
Bug: 18186310

(cherry picked from commit 4a9e1937c56511aef579312bf39ab345f9179230)

Change-Id: I2cd9e58893555d16cbfe291b2d1279621489d5ad

9 years agoAdd dlfcn_test to glibc test suite.
Dmitriy Ivanov [Fri, 31 Oct 2014 06:42:45 +0000 (23:42 -0700)]
Add dlfcn_test to glibc test suite.

Bug: 18186310

(cherry picked from commit eb27bbae8f0edc6b62ca2db73256c7fb53b9e9bf)

Change-Id: I1d608dfa12dbafbdcdb8bc6d818c5872404c19e0

9 years agoIgnore DT_BIND_NOW (0x18)
Dmitriy Ivanov [Wed, 15 Oct 2014 21:59:01 +0000 (14:59 -0700)]
Ignore DT_BIND_NOW (0x18)

Bug: 18186310
Bug: 17552334

(cherry picked from commit ea6eae182ad64312f80b9adddac511d8938e23e7)

Change-Id: I07d6f6fbb462fea329581d0da02f6d88be1c262f

9 years agoResolve "unused DT entry" warnings for x86_64
Dmitriy Ivanov [Mon, 6 Oct 2014 18:30:43 +0000 (11:30 -0700)]
Resolve "unused DT entry" warnings for x86_64

Bug: 18186310

(cherry picked from commit 513e29e16f16a6ffa1636ba282d599fd6b437aeb)

Change-Id: I1e4c5af2cdc09dc978c7a78fcdcf8796c919751e

9 years agoAdd RTLD_NODELETE flag support
Dmitriy Ivanov [Mon, 19 May 2014 22:06:58 +0000 (15:06 -0700)]
Add RTLD_NODELETE flag support

Bug: 18186310
Bug: https://code.google.com/p/android/issues/detail?id=64069

(cherry picked from commit 1b20dafdbe65e43b9f4c95057e8482380833ea91)

Change-Id: Ic02eec22a7c322ece65eb40730a3404f611526b1

9 years agoFix mips build
Dmitriy Ivanov [Tue, 30 Sep 2014 23:30:22 +0000 (16:30 -0700)]
Fix mips build

Bug: 18186310

(cherry picked from commit ecf532fa1cfe91ca946243c11ef154c602870ba6)

Change-Id: Ia12f2fa28c8cd3204eb7d6b4c7d872f4e81fb8ef

9 years agoFix unused DT entry warnings.
Dmitriy Ivanov [Tue, 30 Sep 2014 02:14:45 +0000 (19:14 -0700)]
Fix unused DT entry warnings.

 DT_STRSZ Implement strtab boundary checks
 DT_FLAGS_1 Warn if flags other than DF_1_NOW|DF_1_GLOBAL are set

Bug: 17552334
Bug: 18186310

(cherry picked from commit 6cdeb5234d7f4523fe9d83974f265d80f10512a6)

Change-Id: I7ffc7bc600798308a77ad949a644949b64250ae2

9 years agoReturn has_DT_SYMBOLIC flag.
Dmitriy Ivanov [Mon, 29 Sep 2014 19:10:36 +0000 (12:10 -0700)]
Return has_DT_SYMBOLIC flag.

This reverts commit 8f61d991831f0ea515fa50a5c38dbbcfbab0dd28

 Despite the fact that static linker does all the work while linking
 -Bsymbolic executables, according to the SCO doc following DT_SYMBOLIC
 and DF_SYMBOLIC flags is still a requirement for the dynamic linker
 as well.

 (see http://www.sco.com/developers/gabi/2012-12-31/ch5.dynamic.html)

Bug: 18186310

(cherry picked from commit 96bc37f2e1093416a432135265fd7a4db6c3df17)

Change-Id: Ie217be4f3305d877066e4cfe91975ae1c7768330

9 years agoFix a couple more cases of missing CLOEXEC.
Elliott Hughes [Tue, 23 Sep 2014 00:43:09 +0000 (17:43 -0700)]
Fix a couple more cases of missing CLOEXEC.

The debuggerd case can probably never happen, because you're crashing at this
point anyway. The system property one seems possible though.

Bug: 18186310

(cherry picked from commit 0dc39f9952c5e3a3121ea77357bb264ef0f8ded7)

Change-Id: I3e84488fc246f6c28cbd82e96d0cd4343a12c28a

9 years agoTemporary disable DL_WARNs for unused DT_*
Dmitriy Ivanov [Wed, 17 Sep 2014 23:46:40 +0000 (16:46 -0700)]
Temporary disable DL_WARNs for unused DT_*

Bug: 17552334
Bug: 18186310

(cherry picked from commit 1b77423eff21e916186fcb208f138e436e9f3052)

Change-Id: I8a9d05195a862bc287fff7156913606f0311b8bb

9 years agoFix 64bit build
Dmitriy Ivanov [Wed, 17 Sep 2014 06:34:20 +0000 (23:34 -0700)]
Fix 64bit build

Bug: 18186310

(cherry picked from commit f240aa8089ea1574a7d799720efb66528f6ceb99)

Change-Id: Id46f1f9be90a17a58fb44d3540095c8c685c9726

9 years agoFix some unused DT_ warnings
Dmitriy Ivanov [Tue, 16 Sep 2014 22:51:25 +0000 (15:51 -0700)]
Fix some unused DT_ warnings

 * DT_PLTGOT - ignored for non-mips
 * DT_RELCOUNT/RELACOUNT - ignored
 * DT_RELENT/RELAENT - sanity checks
 * DT_SYMENT - sanity check
 * DT_SONAME - ignore for now.

Bug: 18186310

(cherry picked from commit 4a6e9a835a84aca965f0170f604381dae7f130be)

Change-Id: Ib40095f0770d65628fc7abac5a471378de35ebe7

9 years agoRemove has_DT_SYMBOLIC flag
Dmitriy Ivanov [Tue, 16 Sep 2014 21:31:06 +0000 (14:31 -0700)]
Remove has_DT_SYMBOLIC flag

  From the elf-spec: "Symbolically bound shared objects are
  identified by the .dynamic entry DT_SYMBOLIC. This tag is
  informational only; the runtime linker processes symbol
  lookups from these objects in the same manner as any
  other object."

Bug: 18186310

(cherry picked from commit 8f61d991831f0ea515fa50a5c38dbbcfbab0dd28)

Change-Id: I37024799ac8d1837993c8ae78780a448bedd6539

9 years agoFix dlsym() to take into account RTLD_GLOBAL/LOCAL
Dmitriy Ivanov [Tue, 16 Sep 2014 00:00:10 +0000 (17:00 -0700)]
Fix dlsym() to take into account RTLD_GLOBAL/LOCAL

  Symbols from libraries opened with RTLD_LOCAL (default)
  should not be visible via dlsym(RLTD_DEFAULT/RTLD_NEXT, .)

Bug: 17512583
Bug: 18186310

(cherry picked from commit e8ba50fe0d51fbefee1a8f5bb62bf51d841512c8)

Change-Id: Idf6bbe2233fb2bfc0c88677e7d1fc518fb3f7a8b

9 years agoReformatting
Dmitriy Ivanov [Fri, 12 Sep 2014 16:43:13 +0000 (09:43 -0700)]
Reformatting

 No functional changes.

Bug: 18186310

(cherry picked from commit 6abf624d122bec8c80cc9fe1b692265bf1b28b1b)]

Change-Id: I0acf52d8ee7fe2d4f44bc832cbe9fabe1782f03f

9 years agoOnly use <atomic> for C++11 and newer.
Dan Albert [Thu, 16 Oct 2014 14:52:51 +0000 (07:52 -0700)]
Only use <atomic> for C++11 and newer.

Any pre-C++11 clients of stdatomic.h that use libc++ are being forced
over to <atomic>, which they don't have the language support to use.

Bug:17736764

Change-Id: I62445c1f2541410a1569498c09433c7196635537
(cherry picked from commit 3ce0769aa5f9a991af1d167f730d987dd002253c)

9 years agomerge in lmp-mr1-release history after reset to b0693ec58247c36a7427267783cb756cc055aed8
The Android Automerger [Thu, 30 Oct 2014 13:08:57 +0000 (06:08 -0700)]
merge in lmp-mr1-release history after reset to b0693ec58247c36a7427267783cb756cc055aed8

9 years agoMerge changes I0feda6b2,I22d13fde,I49d7d09d,Ice490bfe into lmp-mr1-dev
Elliott Hughes [Wed, 29 Oct 2014 23:22:30 +0000 (23:22 +0000)]
Merge changes I0feda6b2,I22d13fde,I49d7d09d,Ice490bfe into lmp-mr1-dev

* changes:
  Fix the type of u_ar0 in <sys/user.h>.
  Add greg_t for arm64.
  POSIX says <signal.h> gets you ucontext_t.
  Add in_port_t and move it and in_addr_t to the correct header file.

9 years agoFix the type of u_ar0 in <sys/user.h>.
Elliott Hughes [Sat, 25 Oct 2014 03:57:09 +0000 (20:57 -0700)]
Fix the type of u_ar0 in <sys/user.h>.

(cherry picked from commit e03950fa0c5567edf70d011b856a027e03b1c0f7)

Bug: 18172268
Change-Id: I0feda6b253882f68f47bcf30fad998286cc7f620

9 years agoAdd greg_t for arm64.
Elliott Hughes [Fri, 19 Sep 2014 17:31:49 +0000 (10:31 -0700)]
Add greg_t for arm64.

This was already present for the other architectures. I think we skipped
this because glibc seems to have an incorrect definition (int rather than
long), but the kernel has the sane definition (just not in a uapi header).

(cherry picked from commit 8e4d371091e5738346f5c6ad395b8487c2a5ec67)

Bug: 18172268
Change-Id: I22d13fdeb6431ea122dd028a229782dcaf2286b2

9 years agoPOSIX says <signal.h> gets you ucontext_t.
Elliott Hughes [Sat, 13 Sep 2014 03:04:40 +0000 (20:04 -0700)]
POSIX says <signal.h> gets you ucontext_t.

POSIX also says that ucontext_t's uc_sigmask has type sigset_t.

MIPS64 strace needs this.

The #define is to keep chromium off our lawn; otherwise it tries to redefine
all this stuff itself. We should probably clean that up and remove the #define.

(cherry picked from commit 26a8eb50a84e131d34d10d5d167d67e9995399bd)

Bug: 18172268
Change-Id: I49d7d09dabfc6c6926a8e1f4b235d041e2f2fc4d

9 years agoAdd in_port_t and move it and in_addr_t to the correct header file.
Elliott Hughes [Tue, 19 Aug 2014 19:43:50 +0000 (12:43 -0700)]
Add in_port_t and move it and in_addr_t to the correct header file.

No one's reported this, but I saw it in an Android port of fuser(1).

We still have lots of problems in our network headers because we
get most of the structs direct from the kernel, and it doesn't use
types like this (which is why we've got away without this one for
so long). One day we should probably look at cleaning that up, but
doing so can wait.

(cherry picked from commit 35d226e05d92824c6eb992e7a64ea22efc8bae03)

Bug: 18172268
Change-Id: Ice490bfe84afb04722d738128053d4c533b8a664

9 years agoAdd stpcpy assembler version.
Christopher Ferris [Tue, 30 Sep 2014 18:53:13 +0000 (11:53 -0700)]
Add stpcpy assembler version.

For generic, continue to use the C version of the code.

Bug: 13746695

(cherry picked from commit 7d849ac378515efa1522e538e6e1d3b546cae97d)

Change-Id: Iae44785f37f9bb59103ab78fb9f74c92f8a95c7f

9 years agomerge in lmp-mr1-release history after reset to 0cc59dd303205de7110e298e9b90b1c3b98f4711
The Android Automerger [Wed, 29 Oct 2014 13:08:51 +0000 (06:08 -0700)]
merge in lmp-mr1-release history after reset to 0cc59dd303205de7110e298e9b90b1c3b98f4711

9 years agoCleanup arm assembly.
Christopher Ferris [Mon, 29 Sep 2014 22:34:20 +0000 (15:34 -0700)]
Cleanup arm assembly.

Remove the old arm directives.
Change the non-local labels to .L labels.
Add cfi directives to strcpy.S.

Bug: 18157900

(cherry picked from commit c8bd2abab24afe563240297018c4fa79944f193b)

Change-Id: Ifa1c3d16553d142eaa0d744af040f0352538106c

9 years agoAdd __memcpy_chk assembly for 64 bit.
Christopher Ferris [Thu, 25 Sep 2014 00:05:20 +0000 (17:05 -0700)]
Add __memcpy_chk assembly for 64 bit.

Bug: 17623887

(cherry picked from commit 8cf61dab5f11ed5654a5760ab47cec0239caafe0)

Change-Id: I91e66ca0c26f04b50308059f9c89d388d55f6e3a

9 years agoClean up the architecture-specific makefiles.
Elliott Hughes [Wed, 17 Sep 2014 02:06:31 +0000 (19:06 -0700)]
Clean up the architecture-specific makefiles.

Group things appropriately and name each group.

Bug: 18160821

(cherry picked from commit 7c02d9428ca18ac600f7ba7d51bb24ca71e733f6)

Change-Id: I863242515af44058154d03e2d8c34678e682d66a

9 years agoNo arm source refers to SOFTFLOAT.
Elliott Hughes [Tue, 16 Sep 2014 23:27:35 +0000 (16:27 -0700)]
No arm source refers to SOFTFLOAT.

So why bother #defining it?

Bug: 18160821

(cherry picked from commit b1a6c319c40674d71e30313040d3b33b8bddf24b)

Change-Id: I9cd9c144ba7071fddda12fa16d1232ad861b66be

9 years agoFix mips signed/unsigned signal_test.cpp build breakage.
Elliott Hughes [Thu, 4 Sep 2014 22:43:10 +0000 (15:43 -0700)]
Fix mips signed/unsigned signal_test.cpp build breakage.

(cherry picked from commit aa13e839f06231b9299bb683a71abd954294b49b)

Bug: 17436734
Change-Id: I167fc5d74c49cca7031c5739bc53fdf3bde71887

9 years agoRemove the unnecessary generic-neon code.
Christopher Ferris [Wed, 24 Sep 2014 01:31:45 +0000 (18:31 -0700)]
Remove the unnecessary generic-neon code.

Bug: 18156619
(cherry picked from commit 2169e17482da91865e412e55b52b88d7c8db47f6)

Change-Id: I4a7f5bb9ad4c27b274f3a3c86c1617ca0578b98f

9 years agoMerge "Don't mask out SA_RESTORER from sa_flags." into lmp-mr1-dev
Elliott Hughes [Tue, 28 Oct 2014 15:36:55 +0000 (15:36 +0000)]
Merge "Don't mask out SA_RESTORER from sa_flags." into lmp-mr1-dev

9 years agoMerge "Disable tzdata in $ANDROID_DATA." into lmp-mr1-dev
Elliott Hughes [Tue, 28 Oct 2014 15:06:30 +0000 (15:06 +0000)]
Merge "Disable tzdata in $ANDROID_DATA." into lmp-mr1-dev

9 years agoDon't mask out SA_RESTORER from sa_flags.
Elliott Hughes [Thu, 4 Sep 2014 20:54:42 +0000 (13:54 -0700)]
Don't mask out SA_RESTORER from sa_flags.

glibc doesn't do this, and we probably shouldn't either.

Bug: 16703540
Bug: 17436734

(cherry picked from commit afe58ad9892de27a7acb0aaded6312ee0f958314)

Change-Id: Iada5d0ae814f438cb276f056b2b5e3675f0e3666

9 years agomerge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933
The Android Automerger [Tue, 28 Oct 2014 13:10:08 +0000 (06:10 -0700)]
merge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933

9 years ago[x86,x86_64] Fix libgcc unwinding through signal
Pavel Chupin [Fri, 26 Sep 2014 12:02:09 +0000 (16:02 +0400)]
[x86,x86_64] Fix libgcc unwinding through signal

This change provides __restore/__restore_rt on x86 and __restore_rt on
x86_64 with unwinding information to be able to unwind through signal
frame via libgcc provided unwinding interface. See comments inlined for
more details.

Also remove the test that had a dependency on
__attribute__((cleanup(foo_cleanup))). It doesn't provide us with any
better test coverage than we have from the newer tests, and it doesn't
work well across a variety architectures (presumably because no one uses
this attribute in the real world).

Tested this on host via bionic-unit-tests-run-on-host on both x86 and
x86-64.

Bug: 17436734
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
(cherry picked from commit 50321e2e66f19998970e59d666bc9af387345b3a)

Change-Id: Iba90e36958b00c7cc7db5eeebf888dc89ce4d619

9 years agoStack unwinding unit tests.
Elliott Hughes [Thu, 18 Sep 2014 00:21:20 +0000 (17:21 -0700)]
Stack unwinding unit tests.

Bug: 17436734

(cherry picked from commit bee1993a14b47bc7acda544242f405ae45e42566)

Change-Id: I7205a862ba2c3b474e287f5e9c8982cef4610af9

9 years agoUse the kernel's sa_restorer for aarch64.
Elliott Hughes [Tue, 16 Sep 2014 22:49:50 +0000 (15:49 -0700)]
Use the kernel's sa_restorer for aarch64.

gdb was happy with what we had, but libgcc and libunwind weren't.
libgcc is happy with the kernel's restorer (because of the extra nop),
though libunwind looks like it's going to need code changes regardless.

We could make our restorer more like the kernel's one, but why bother
when we can just let the kernel supply the canonical one?

Bug: 17436734

(cherry picked from commit 1cff9a89645a8f362a9ce19c7f9544e98c1fd9e7)

Change-Id: Ie13d73fd97395e1979a67c2294e036a97c50000d

9 years agoFix 32-bit arm unwinding through signal frames.
Elliott Hughes [Tue, 16 Sep 2014 20:57:39 +0000 (13:57 -0700)]
Fix 32-bit arm unwinding through signal frames.

gdb was already okay; libgcc and libunwind need a little extra help.

Bug: 17436734

(cherry picked from commit 148dff3ec6114a03acc722ae43990f1b342abad9)

Change-Id: I2cc997017acc57c930284af5264f353656b98c7b

9 years agoFix signal trampolines.
Elliott Hughes [Wed, 10 Sep 2014 22:20:40 +0000 (15:20 -0700)]
Fix signal trampolines.

* LP32 should use sa_restorer too. gdb expects this, and future (>= 3.15) x86
  kernels will apparently stop supporting the case where SA_RESTORER isn't
  set.

* gdb and libunwind care about the exact instruction sequences, so we need to
  modify the code slightly in a few cases to match what they're looking for.

* gdb also cares about the exact function names (for some architectures),
  so we need to use __restore and __restore_rt rather than __sigreturn and
  __rt_sigreturn.

* It's possible that we don't have a VDSO; dl_iterate_phdr shouldn't assume
  that getauxval(AT_SYSINFO_EHDR) will return a non-null pointer.

This fixes unwinding through a signal handler in gdb for all architectures.
It doesn't fix libunwind for arm and arm64. I'll keep investigating that...

(cherry picked from commit 36f451a6d93b6807944d99fa23396e039c47e845)

Bug: 17436734
Change-Id: Ic1ea1184db6655c5d96180dc07bcc09628e647cb

9 years agoDisable tzdata in $ANDROID_DATA.
Elliott Hughes [Mon, 27 Oct 2014 20:38:21 +0000 (13:38 -0700)]
Disable tzdata in $ANDROID_DATA.

Bug: 18139284
Change-Id: I2670dc1791d635139a5d39a438dc08777439476b

9 years agomerge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933
The Android Automerger [Mon, 27 Oct 2014 13:08:44 +0000 (06:08 -0700)]
merge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933

9 years agomerge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933
The Android Automerger [Sun, 26 Oct 2014 13:08:41 +0000 (06:08 -0700)]
merge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933

9 years agomerge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933
The Android Automerger [Sat, 25 Oct 2014 13:08:59 +0000 (06:08 -0700)]
merge in lmp-mr1-release history after reset to aa6cd5819c8ebd254d995388798a4b51af7ca933

9 years agoUse mxcr_mask instead of mxcsr_mask to match glibc.
Elliott Hughes [Fri, 24 Oct 2014 03:29:42 +0000 (20:29 -0700)]
Use mxcr_mask instead of mxcsr_mask to match glibc.

Bug: 18097559

(cherry picked from commit f485547b9267263e1de220a3cc368deaec367191)

Change-Id: I242105faa8210abc9635a951b25b127cd64ed23c

9 years agomerge in lmp-mr1-release history after reset to 8fab8119dd176a280b62e9e8f2b4f08c0d76f36d
The Android Automerger [Thu, 23 Oct 2014 13:09:33 +0000 (06:09 -0700)]
merge in lmp-mr1-release history after reset to 8fab8119dd176a280b62e9e8f2b4f08c0d76f36d

9 years agoUpdate bionic to tzdata2014i.
Elliott Hughes [Wed, 22 Oct 2014 19:31:02 +0000 (12:31 -0700)]
Update bionic to tzdata2014i.

From the release notes:

   Changes affecting future time stamps

     Pacific/Fiji will observe DST from 2014-11-02 02:00 to
     2015-01-18 03:00.  (Thanks to Ken Rylander for the heads-up.)
     Guess that future years will use a similar pattern.

     A new Zone Pacific/Bougainville, for the part of Papua New
     Guinea that plans to switch from UTC+10 to UTC+11 on
     2014-12-28 at 02:00.  (Thanks to Kiley Walbom for the
     heads-up.)

   Changes affecting time zone abbreviations

     Since Belarus is not changing its clocks even though Moscow
     is, the time zone abbreviation in Europe/Minsk is changing
     from FET to its more-traditional value MSK on 2014-10-26 at
     01:00.  (Thanks to Alexander Bokovoy for the heads-up about
     Belarus.)

     The new abbreviation IDT stands for the pre-1976 use of UT+8
     in Indochina, to distinguish it better from ICT (UT+7).

   Changes affecting past time stamps

     Many time stamps have been corrected for Asia/Ho_Chi_Minh
     before 1976 (thanks to Trần Ngọc Quân for an indirect pointer
     to Trần Tiến Bình's authoritative book).  Asia/Ho_Chi_Minh has
     been added to zone1970.tab, to give tzselect users in Vietnam
     two choices, since north and south Vietnam disagreed after our
     1970 cutoff.

     Asia/Phnom_Penh and Asia/Vientiane have been turned into
     links, as they differed from existing zones only for older
     time stamps.  As usual, these changes affect pre-1970 time
     stamps only.  Their old contents have been moved to the
     'backzone' file.

Bug: 18085936

(cherry picked from commit a05c2a2a705c8298154db6665cbbb4dbe3cdbbd5)

Change-Id: If0253cc1515e1bc98e99c6e24eec797836ca7c27

9 years agoMerge "Fix generic __memcpy_chk implementation." into lmp-mr1-dev
Christopher Ferris [Wed, 22 Oct 2014 20:16:18 +0000 (20:16 +0000)]
Merge "Fix generic __memcpy_chk implementation." into lmp-mr1-dev