Commit graph

31237 commits

Author SHA1 Message Date
Jiyong Park
262ff01d2b Merge "Set apex_available property" 2020-05-10 06:25:04 +00:00
Jiyong Park
4ede160cb1 Set apex_available property
The marked library(ies) were available to the APEXes via the
hand-written whitelist in build/soong/apex/apex.go. Trying to remove the
whitelist by adding apex_available property to the Android.bp of the
libraries.

Exempt-From-Owner-Approval: cherry-pick from internal

Bug: 150999716
Test: m
Merged-In: If64eff62b9e93af95089e5010c30eb586673b92e
(cherry picked from commit 693a7214d6)
Change-Id: If64eff62b9e93af95089e5010c30eb586673b92e
2020-05-10 06:24:42 +00:00
Treehugger Robot
c2a67121c7 Merge "Fix typo in if statement." 2020-05-08 18:34:42 +00:00
Peter Collingbourne
947125edf1 Fix typo in if statement.
It turns out that we weren't actually enabling stack traces due
to a typo in one of the if statements. Fix it.

Bug: 135772972
Change-Id: Ic19352280f65acd621b9d88c361c55680b3327f0
2020-05-08 10:05:39 -07:00
Treehugger Robot
073c3dc1eb Merge "Add goldfish-opengl to use bionic_libc_platform_headers" 2020-05-08 00:53:07 +00:00
Roman Kiryanov
067f51824b Add goldfish-opengl to use bionic_libc_platform_headers
We need __get_tls and TLS_SLOT_OPENGL for our
OpenGL implementation. We currently use .mk files
and this restriction does not apply, since we are
migrating to .bp we need to address restriction.

Bug: 154151802
Test: presubmit
Signed-off-by: Roman Kiryanov <rkir@google.com>
Change-Id: I007664d919204cd4f6a623f9695a56e94bab7ae6
2020-05-07 15:06:55 -07:00
Peter Collingbourne
144a6ab341 Merge "Introduce a new heap tagging level, M_HEAP_TAGGING_LEVEL_SYNC." 2020-05-07 17:51:51 +00:00
Martin Stjernholm
e413ce902d Merge "Export libc_headers from libdl_static for libraries that wrap it without bringing in libc." 2020-05-07 09:19:48 +00:00
Martin Stjernholm
3ddcc1e987 Export libc_headers from libdl_static for libraries that wrap it
without bringing in libc.

Required by the native bridge libdl wrapper.

Test: m (on cf_x86_phone)
Bug: 153590472
Change-Id: Ib9b1b741aaf5b09b24d7dce09a49c2fa7737209f
2020-05-06 23:47:40 +01:00
Martin Stjernholm
98581070c2 Merge "Make Bionic and kernel system includes explicit in the blueprints." 2020-05-06 10:35:39 +00:00
Peter Collingbourne
d3060019de Introduce a new heap tagging level, M_HEAP_TAGGING_LEVEL_SYNC.
The SYNC tagging level enables stack trace collection for allocations and
deallocations, which allows allocation and deallocation stack traces to
appear in tombstones when encountering a tag check fault in synchronous tag
checking mode.

Bug: 135772972
Change-Id: Ibda9f51b29d2c8e2c993fc74425dea7bfa23ab1e
2020-05-05 13:28:16 -07:00
Martin Stjernholm
82d84bcd7e Make Bionic and kernel system includes explicit in the blueprints.
Before this Soong added hardcoded system include paths to
bionic/libc/{include,kernel}, which won't work when Bionic libs are
packaged up as prebuilts in an SDK module snapshot.

Test: Build and boot
Test: Check in out/verbose.log.gz that a C file doesn't get any bionic
  include path for linux_glibc.
Bug: 153590472
Change-Id: I13c8eb3dd7150d6e0fee001b290b53fcebebcfea
2020-05-05 13:34:14 +01:00
Jooyung Han
95c00dcf0b Merge "Set min_sdk_version for mainline dependencies" 2020-05-05 06:43:24 +00:00
Jooyung Han
15c32a8e1a Set min_sdk_version for mainline dependencies
To enforce all modules included in mainline modules(apex/apk),
modules should set min_sdk_version which is the minimum sdk versions
that compiled artifacts run against.

Setting this doesn't change build output.

Bug: 145796956
Test: m
Change-Id: Ibbe3771592677d729c81343fe00859c0afa81918
2020-05-05 10:45:46 +09:00
Treehugger Robot
49f7f10f62 Merge "Add API constant for S." 2020-05-05 00:35:17 +00:00
Quentin Perret
04e4d35cd7 Merge "Fix argument order in api level test" 2020-05-04 09:59:16 +00:00
Alistair Delva
bed98c0deb Fix argument order in api level test
Looks like the arguments were unintentionally swapped?

Bug: 155526611
Change-Id: I39d49f94387cfd337c89becb5eb6f85ca638bef1
Signed-off-by: Alistair Delva <adelva@google.com>
2020-05-03 20:10:51 -07:00
Evgenii Stepanov
f9d72d45d8 Merge "[libc] Zero and pattern initialization of heap memory." 2020-05-01 23:58:48 +00:00
Evgenii Stepanov
5a73e03305 [libc] Zero and pattern initialization of heap memory.
Bug: 155227507
Test: scudo_unit_tests

Change-Id: I85075acfd85172f6cc7e48f79eeb577e293d0d30
2020-05-01 14:06:54 -07:00
Treehugger Robot
ac47b2b56e Merge "Adapt to clang-r383902" 2020-05-01 18:11:02 +00:00
Stephen Hines
25b8af496c Adapt to clang-r383902
This change adapts versioner to llvm::StringRef losing its implicit
conversion to std::string().

Test: ./build-prebuilts.sh
Change-Id: Ie1b290cf12e7044a92545470ce4f968cc55d90c9
2020-05-01 03:44:40 -07:00
Yabin Cui
e75527347a Merge "Fix foritfy test for clang update." 2020-05-01 05:28:39 +00:00
Treehugger Robot
9e42d38e21 Merge "fdtrack: fix accept test, add test for accept4." 2020-05-01 00:25:47 +00:00
Josh Gao
9413ae7366 fdtrack: fix accept test, add test for accept4.
accept creates an additional socket behind the scenes to communicate
with netd. Filter out events for temporarily created, but then closed
fds to allow for this.

Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I2168ddc60f307278e3257ffcdf591272d61d45bb
2020-04-30 16:17:04 -07:00
Martin Stjernholm
82c1096cac Merge "Reland "Make bionic_platform_headers available only for Bionic targets"." 2020-04-30 14:11:50 +00:00
Josh Gao
4d0c40be89 Merge changes I8b25accf,I59013f0c,I6c881e5d,I66826f31,I552692ae, ...
* changes:
  fdtrack: add wrapper for socketpair.
  fdtrack: add wrapper for eventfd.
  fdtrack: add wrappers for epoll_create, epoll_create1.
  fdtrack: add wrappers for pipe, pipe2.
  fdtrack: add tests for individual wrappers.
  fdtrack: don't destroy traces.
2020-04-30 01:54:08 +00:00
Peter Collingbourne
514faf92c8 Merge "Switch to new kernel ptrace interface for reading tags." 2020-04-30 00:55:45 +00:00
Josh Gao
b107eab5ef fdtrack: add wrapper for socketpair.
Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I8b25accf00dc01f6fab351f3ba612f6b0ff9d094
2020-04-29 17:21:16 -07:00
Josh Gao
7de412443d fdtrack: add wrapper for eventfd.
Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I59013f0c4da0debbcc50269c64ae9db0cdc4eaa0
2020-04-29 17:21:16 -07:00
Josh Gao
a38331d833 fdtrack: add wrappers for epoll_create, epoll_create1.
Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I6c881e5d67596c543526536541d5b8086e21d9e9
2020-04-29 17:21:16 -07:00
Josh Gao
1fad5283a0 fdtrack: add wrappers for pipe, pipe2.
Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I66826f312a65ab9f1bd8193bf684e330baa952dc
2020-04-29 17:21:16 -07:00
Josh Gao
9d512402d4 fdtrack: add tests for individual wrappers.
Add tests for all of our existing wrappers (with one commented out,
because it's unexpectedly generating multiple events).

Bug: https://issuetracker.google.com/154450436
Test: bionic-unit-tests
Change-Id: I552692aef952237c2eee0dabec61b7ea7fd230e3
2020-04-29 17:21:12 -07:00
Josh Gao
38d00b80a0 fdtrack: don't destroy traces.
There's a bad interaction with malloc_debug when the libraries are being
destroyed.

Bug: https://issuetracker.google.com/154439915
Test: treehugger
Change-Id: Ib47c8139c3a88dd52865ea93654b2926bd708729
2020-04-29 17:20:24 -07:00
Treehugger Robot
7204ad8cc8 Merge "Add METADATA to bionic: BSD+Apache2+MIT+ISC=NOTICE" 2020-04-29 23:40:01 +00:00
Bob Badour
76474c95b0 Add METADATA to bionic: BSD+Apache2+MIT+ISC=NOTICE
Bug: 68860345
Bug: 69058154
Bug: 151953481

Test: no code changes
Change-Id: Ie25de7ff63fca903030702f6b811fd37f4cade12
2020-04-29 13:08:49 -07:00
Martin Stjernholm
a276343e14 Reland "Make bionic_platform_headers available only for Bionic targets".
The triggering reason for this change is that the SDK snapshot
generation cannot readily handle header libraries that are required for
targets that the SDK itself isn't available for. However, these include
files shouldn't be used without Bionic anyway.

Relanding unchanged - the build problem was due to a split topic.

Test: m checkbuild (on aosp_taimen)
Test: m (on aosp_taimen_hwasan)
Test: atest CtsBionicTestCases
Test: lunch fvp-userdebug && mmm bionic
Bug: 152255951
Change-Id: Iaf49597ea265e6f2a042de5ee873238073b2e545
2020-04-29 18:14:11 +01:00
Martin Stjernholm
d20571efe1 Merge "Revert "Make bionic_platform_headers available only for Bionic t..."" 2020-04-29 12:27:37 +00:00
Martin Stjernholm
ed95d0134d Revert "Make bionic_platform_headers available only for Bionic t..."
Reason for revert: Breaks rvc-d1-dev-plus-aosp: http://ab/6443190
Reverted Changes:
Ide447b89a:bionic_libc_platform_headers is only available whe...
Ia93cd3ec8:bionic_libc_platform_headers is only available whe...
Icdc495588:Make bionic_platform_headers available only for Bi...
Idfd7c87dc:bionic_libc_platform_headers is only available whe...

Bug: 152255951
Bug: 155269399
Change-Id: I214f1165bb0a7e59d3b35a13b3cceb1965be922b
2020-04-29 12:18:36 +00:00
Martin Stjernholm
38d0a7d9dc Merge "Make bionic_platform_headers available only for Bionic targets." 2020-04-29 10:30:23 +00:00
Treehugger Robot
cbc67b3051 Merge "[NFC] Align pointer to type." 2020-04-28 20:02:52 +00:00
Mitch Phillips
ba1e921294 [NFC] Align pointer to type.
Typo fix.

Bug: N/A
Test: N/a
Change-Id: Ia19076da9ea19fc7629e625023e969105d2f8786
2020-04-28 11:33:48 -07:00
Treehugger Robot
5057c42012 Merge "malloc_hooks README.md: fix example compilation failures" 2020-04-27 23:29:41 +00:00
Martin Stjernholm
249f726583 Make bionic_platform_headers available only for Bionic targets.
The triggering reason for this change is that the SDK snapshot
generation cannot readily handle header libraries that are required for
targets that the SDK itself isn't available for. However, these include
files shouldn't be used without Bionic anyway.

Test: m checkbuild (on aosp_taimen)
Test: m (on aosp_taimen_hwasan)
Test: atest CtsBionicTestCases
Test: lunch fvp-userdebug && mmm bionic
Bug: 152255951
Change-Id: Icdc49558893c5355860f78d23275c49ba0119900
2020-04-27 19:07:01 +01:00
Jooyung Han
1d9ccdfb1a Merge "libc: Add stubs.versions=R" 2020-04-25 04:41:43 +00:00
Steven Moreland
6cdeed3124 malloc_hooks README.md: fix example compilation failures
Bug: N/A
Test: N/A
Change-Id: I017f47990417446f1bff5fc7a5bf7e53e8e1f85e
2020-04-25 00:46:45 +00:00
Peter Collingbourne
a41c3256d7 Switch to new kernel ptrace interface for reading tags.
Bug: 135772972
Change-Id: I1839f04130736b8f7ba0c282d4d6833d50b1a9ae
2020-04-24 17:32:23 -07:00
Elliott Hughes
317a2e588b Merge "Block all signals in ScopedSignalBlocker." 2020-04-24 15:50:15 +00:00
Elliott Hughes
3093e71811 Block all signals in ScopedSignalBlocker.
When a thread calls pthread_exit(3), ScopedSignalBlocker blocks all
user-visible signals, but leaves internal-use signals 33/34/36/36/37.
Signal 33 is used to unwind a thread for a backtrace, which can cause us
to access the stack after it's been unmapped. (Avoiding this was the
reason why we have the ScopedSignalBlocker in pthread_exit(3)!)

Fix this (and other potential issues) by changing ScopedSignalBlocker to
call __rt_sigprocmask(2) directly, so we don't mask out the internal-use
signals.

Bug: https://issuetracker.google.com/153624226
Test: not trivially reproducible
Change-Id: I9b125ed41ddee4c5d33b45920f1d142e52db47cb
2020-04-23 15:57:58 -07:00
Treehugger Robot
c33ad20258 Merge "Add AOSP preupload hook." 2020-04-23 20:15:00 +00:00
Elliott Hughes
ed2889fc4d Add AOSP preupload hook.
Test: repo upload in internal master
Change-Id: I8c3604dfa2701d2d82bc60d62562a65a62d7e05e
2020-04-23 11:05:06 -07:00