Commit Graph

8400 Commits

Author SHA1 Message Date
Peter Collingbourne
feed681f63 libandroid_runtime: Link libselinux dynamically instead of statically. am: d7e42641de
am: 73ce15e8a8

Change-Id: I92c09f1137b7052b2177994268fbd5ae07f6c57e
2018-09-14 17:44:38 -07:00
Peter Collingbourne
73ce15e8a8 libandroid_runtime: Link libselinux dynamically instead of statically.
am: d7e42641de

Change-Id: I9fa8026f7463be7b76fecd97862ec0046c7ce040
2018-09-14 17:20:08 -07:00
Michael Dooley
c106550132 Merge "Revert "Adding getModelState API to sound trigger"" 2018-09-14 16:21:17 +00:00
Michael Dooley
81f71f1c27 Revert "Adding getModelState API to sound trigger"
This reverts commit 4f809fe73e.

Reason for revert: fix build breakage

Change-Id: I75a54189f96fc21f6cb12dd8a05e513b1bda027c
2018-09-14 16:09:18 +00:00
Michael Dooley
a707ba1cb0 Merge "Adding getModelState API to sound trigger" 2018-09-14 12:32:09 +00:00
Peter Collingbourne
d7e42641de libandroid_runtime: Link libselinux dynamically instead of statically. 2018-09-13 14:34:32 -07:00
TreeHugger Robot
1ae324d31d Merge "Exposes {start,stop}AudioSource to JAVA layer" 2018-09-10 20:29:32 +00:00
TreeHugger Robot
2f1e32fff5 Merge "Refactor HWUI readback code to be backend independent" 2018-09-10 19:22:57 +00:00
Stan Iliev
1a025a7163 Refactor HWUI readback code to be backend independent
Implement readback from Surface, TextureView and HW Bitmap
for Vulkan pipeline by wrapping the graphics buffer in an SkImage.
Refactor both Vulkan and GL readback to use common code.
TextureView readback is moved from IRenderPipeline interface to
Readback class. Refactor all 3 readback flows to use common
implementation.

Test: Passed all view, uirendering and graphics CTS tests with GL
Test: Passed many CTS test with Vulkan, that require readback
Bug: 113673613
Change-Id: Ifbfd8170a5401f87a709b4b1b9fa058e8e11768d
2018-09-10 13:18:04 -04:00
Hongwei Wang
f44a568ffb Exposes {start,stop}AudioSource to JAVA layer
- Android Automotive directly calls AudioSystem at the time being,
AudioManager is not updated in this CL

TODO:

- AudioPolicyManager::connectAudioSource is a no-op for
AUDIO_DEVICE_API_VERSION_3_0

Bug: 112161027
Test: m -j
Change-Id: I27a28cd1fd2992c4a7a9a67feb606f35cae43cc3
2018-09-08 12:12:15 -07:00
TreeHugger Robot
8019cb8898 Merge "Refactor String8 to std::string calls" 2018-09-05 17:35:38 +00:00
mike dooley
4f809fe73e Adding getModelState API to sound trigger
Test: built android
Bug-Id: 70206501
Change-Id: Ieb83a366d4ddd471186d5089efe0675ea6285454
2018-09-05 15:58:27 +02:00
Stan Iliev
564ca3e2c9 Reland "TextureView Vulkan support and optimized OpenGL draw"
Fix an issue with incorrect texture matrix, when there is 90/270 rotation.
This happened, because after refactoring SkImage has buffer width/height,
instead of layer width/height.
This reverts commit a683eb3945.

Bug: 113673613
Test: Ran TextureView CTS and lensblur in camera app
Change-Id: If3bcf9cd5195de09fd67a753708568a8e3ca3a9a
2018-09-05 01:58:34 +00:00
Stan Iliev
a683eb3945 Revert "Revert "Revert "TextureView Vulkan support and optimized OpenGL draw"""
This reverts commit 85f9096b52.

Reason for revert: lensblur broken.

Change-Id: I83ac163159fc537bc15936a0f8597a7512ca9d6e
2018-09-04 15:42:18 +00:00
Stan Iliev
85f9096b52 Revert "Revert "TextureView Vulkan support and optimized OpenGL draw""
This reverts commit 867c43de05.

Reason for revert: Fixed issue with unsupported hardware buffer formats by landing https://skia-review.googlesource.com/c/skia/+/150470 "Support more hardware buffer formats"

Bug: 113673613
Change-Id: I1f7c528f138e290160e75833c8d989d9535002ee
2018-08-31 22:13:15 +00:00
Joel Fernandes
efd71f890d Merge "Rename map names in read_mapinfo" am: 84b5650315 am: bff9eedce1
am: bec1129388

Change-Id: I96b1413300d98fccbd37d52d0c5e2c3d0d2f2798
2018-08-30 13:27:16 -07:00
Joel Fernandes
bff9eedce1 Merge "Rename map names in read_mapinfo"
am: 84b5650315

Change-Id: I2b0dfc1807037c73b09d629f52b04c2f2e8f2d18
2018-08-30 12:47:00 -07:00
Joel Fernandes
84b5650315 Merge "Rename map names in read_mapinfo" 2018-08-30 19:30:58 +00:00
Stan Iliev
e6cfb09cc4 Merge "Revert "TextureView Vulkan support and optimized OpenGL draw"" 2018-08-30 18:56:41 +00:00
John Reck
867c43de05 Revert "TextureView Vulkan support and optimized OpenGL draw"
This reverts commit c8e22a6532.

Reason for revert: broke camera, b/113555199

Bug: 113555199
Change-Id: Iae9b462694d5de0cd99427afead63b567fb4d71d
2018-08-30 18:42:08 +00:00
TreeHugger Robot
af6e72f037 Merge "SF: Remove setFinalCrop impl 1/2" 2018-08-29 22:58:24 +00:00
TreeHugger Robot
54b9892f3c Merge "TextureView Vulkan support and optimized OpenGL draw" 2018-08-29 15:51:15 +00:00
Vishnu Nair
aeab1b8251 SF: Remove setFinalCrop impl 1/2
setFinalCrop functionality is reimplemented by creating a new bounds layer
and applying a crop on this layer. see ag/4625718

Test: go/wm-smoke

Change-Id: I3ffb6dc2e2afd5170f6c6dee9e928ed0600656b1
2018-08-29 08:37:38 -07:00
Stan Iliev
c8e22a6532 TextureView Vulkan support and optimized OpenGL draw
Render TextureView as hardware bitmaps, instead of GL textures.
Cache SkImage for each observed GraphicBuffer, which is faster
even for GL.
Implement C++ SurfaceTexture, which allows Java SurfaceTexture
to be used with Vulkan HWUI render thread and application GL.
threads. Delete GLLayer and VkLayer classes and texture code
from old HWUI pipeline.

Test: Ran skiagl and skiavk pipeline with a TextureView app.
Test: TextureView CTS tests pass for GL pipeline.
Test: Ran Android NDK Native codec sample app.
Change-Id: Idc94f864ce2d34fd6ceff4be4fc7d3327e99879c
2018-08-29 10:22:03 -04:00
Victor Khimenko
eac760d236 Merge "Add fallback case to layers_extensions.cpp"
am: 46e75a69e8

Change-Id: I64ab2e76d6555131d7e1a6b6d2b2b92b040d9405
2018-08-28 13:45:20 -07:00
Victor Khimenko
46e75a69e8 Merge "Add fallback case to layers_extensions.cpp" 2018-08-28 20:24:33 +00:00
Minchan Kim
696873ea17 Add system_server to system group only if per_app_memcg is true
P18 or other high-performance devices shouldn't use per-memcg so
it was disabled on those devices[1]. However, we didn't turn off
for system_server memcg so those devices still have two seperate
LRU groups which would have less efficient memory reclaim.

Therefore, this patch makes memcg use for system_server only if
per_app_memcg is enabled.

[1] https://googleplex-android-review.git.corp.google.com/c/platform/system/core/+/4178592

Bug: 110858093
Test: confirm via cat /dev/memcg/system/tasks is none
Change-Id: Ic0e3157bf8ff5de69767797b5508946ca3efeb68
Merged-In: Ic0e3157bf8ff5de69767797b5508946ca3efeb68
Signed-off-by: Minchan Kim <minchan@google.com>
(cherry picked from commit 5fa8af2b10)
2018-08-28 01:45:11 +00:00
Joel Fernandes (Google)
299488d7c1 Rename map names in read_mapinfo
ART is removing dependency on ashmem for naming maps. Due to this, the
naming of the mappings have changed. Rename them in the debug info so
that it is working.

Also remove "/dev/ashmem/libc malloc", its now "anon:libc malloc" which
is already tested earlier in the code.

Bug: 111903542
Change-Id: I5071384f87701af208d6471c66ba425ccbda22ec
Signed-off-by: Joel Fernandes (Google) <joelaf@google.com>
Signed-off-by: Joel Fernandes <joelaf@google.com>
2018-08-27 17:39:55 +00:00
TreeHugger Robot
6c05ade479 Merge "Throttle requests to ActivityManager.getProcessMemoryInfo()." 2018-08-27 15:37:33 +00:00
Chih-Hung Hsieh
c75a144473 Merge "Use multiple patterns and/or emails in per-file syntax." am: faac4ad153 am: 0e5bd4e656
am: cbac96ed79

Change-Id: Ic3e7ffb8fd4a59ecf4abaa661148adbd002a0dcc
2018-08-27 02:14:59 -07:00
Chih-Hung Hsieh
0e5bd4e656 Merge "Use multiple patterns and/or emails in per-file syntax."
am: faac4ad153

Change-Id: Ia60c2884c1b8372862cae3d3f1e2b41c40cd1cb9
2018-08-27 01:56:06 -07:00
Treehugger Robot
faac4ad153 Merge "Use multiple patterns and/or emails in per-file syntax." 2018-08-27 08:34:46 +00:00
Dianne Hackborn
8c76d91bd2 Throttle requests to ActivityManager.getProcessMemoryInfo().
This is very expensive and needs to run in the system process, we
don't want apps abusing it.

Also don't allow apps to get information about anything but their
own process, unless they have the appropriate privileged permissions.

Bug: 112537519
Test: manual
Change-Id: I01997d6f888341e8eb2afe6a69545dd5be013744
2018-08-26 18:19:07 -07:00
Bill Napier
d7d338f359 Revert "Throttle requests to ActivityManager.getProcessMemoryInfo()."
This reverts commit 1f3b0302fd.

Reason for revert: broke SDK builds.  See ab/4976218

Change-Id: Id532e20eed8e13735a09cca5affc92005b685744
2018-08-24 21:13:13 +00:00
Dianne Hackborn
1f3b0302fd Throttle requests to ActivityManager.getProcessMemoryInfo().
This is very expensive and needs to run in the system process, we
don't want apps abusing it.

Also don't allow apps to get information about anything but their
own process, unless they have the appropriate privileged permissions.

Bug: 112537519
Test: manual
Change-Id: I103a11f8d5b49fd4536795ea52c05de297698cb5
2018-08-24 11:27:50 -07:00
Sudheer Shanka
6d7e402a50 Merge "Allow some apps to get full access to external storage." 2018-08-24 04:00:25 +00:00
Remi NGUYEN VAN
6808a81793 Merge changes I2cea553a,Id8d3dcf6,I19e68e88,I35598935,Idd7dc369, ... am: e01b4ce6c7 am: e06ae295a2
am: d8f0416ffc

Change-Id: Idc8915a99710a1e2bfd456519fb2931639cd5142
2018-08-23 20:51:03 -07:00
Remi NGUYEN VAN
e06ae295a2 Merge changes I2cea553a,Id8d3dcf6,I19e68e88,I35598935,Idd7dc369, ...
am: e01b4ce6c7

Change-Id: I1800eb214d501e76b8705a27ca817000d009736e
2018-08-23 20:33:45 -07:00
Chih-Hung Hsieh
c8adc53ea2 Use multiple patterns and/or emails in per-file syntax.
Test: build/make/tools/checkowners.py -c -v OWNERS
Change-Id: Ia3fd16d2deb945ae4d0d66541ff824942d5e77f0
2018-08-23 14:27:46 -07:00
Remi NGUYEN VAN
12da4a5efc Add util to add an ARP table entry
This is to be used by the new DhcpServer to add ARP entries with new
addresses before sending unicast responses.

Test: manual: cat /proc/net/arp with implementation based on this
Bug: b/109584964
Change-Id: I3559893583aa3c49b188ad689a41ee2f3e9d9bf3
2018-08-23 16:01:44 +09:00
Brian Osman
43d6dbdc01 Merge "Implement Bitmap get/setPixel(s) using SkBitmap::read/writePixels" 2018-08-22 15:08:08 +00:00
Sudheer Shanka
98cb3f09fa Allow some apps to get full access to external storage.
Apps with WRITE_MEDIA_STORAGE permission will get
full access to external storage.

Bug: 111890351
Test: manual

Change-Id: Icbfe1f68c0bfca77bdc557e9903ded45994f5945
2018-08-21 19:25:08 -07:00
Brian Osman
91c9c28a85 Implement Bitmap get/setPixel(s) using SkBitmap::read/writePixels
Test: Ran CtsUiRenderingTestCases and android.graphics.cts
Change-Id: Ib32fb41d763a29919ac4744c876eb7af42fabab2
2018-08-21 13:27:34 -04:00
Josh Gao
1bb899b5f5 Merge "Fix double close in NativeLibraryHelper.openApkFd."
am: 657650eaf0

Change-Id: Idde99d51da9babe9338db50962c025f96ab6637a
2018-08-21 03:13:55 -07:00
Dario Freni
4ce4679309 androidfw changes to support /product-services.
See CL I7a6a30bf8e8db9f2738594d187bb9148f138b8da for a more detailed
description of the change.

Test: see CL I7a6a30bf8e8db9f2738594d187bb9148f138b8da description
Bug: 80741439
Change-Id: I6cc9d713c07c319fc2ee1c531af41243bd1d4aee
2018-08-17 16:34:18 +00:00
Victor Khimenko
9f52b4aa3b Add fallback case to layers_extensions.cpp
Bug: http://b/79940628

Test: cts-tradefed run commandAndExit cts -m CtsGpuToolsHostTestCases

Change-Id: I5b15e9dbf4bc9887901f584741980c1eca3252a7
Merged-In: I9f4ffb6b3afa8c4b8048e1d579c1befbb6565e19
2018-08-16 22:37:21 +02:00
Josh Gao
5fc8bbe114 Fix double close in NativeLibraryHelper.openApkFd.
Prior to this patch, we were taking the file descriptor owned by a
ParcelFileDescriptor, and passing it into ZipFileRO::openFd, which
expects to take ownership of the file descriptor, closing it upon
destruction. This leads to a double-close when the ParcelFileDescriptor
tries to close itself. Switch to passing a duped copy of the file
descriptor to ZipFileRO::openFd.

Test: `pm install foo.apk` with fdsan
Change-Id: Ida4ca4a37b82875dc4eef1f37bf2322c422fe038
(cherry-picked from commit b066087d65)
2018-08-14 16:45:46 -07:00
Josh Gao
ccef833bbe Merge "MemoryIntArray: don't double close." am: 9b9728710f am: 71af69dba4
am: bb1805cecc

Change-Id: I5fb8753c61a85080c81900f6122ec6c671af297f
2018-08-14 16:17:02 -07:00
Josh Gao
71af69dba4 Merge "MemoryIntArray: don't double close."
am: 9b9728710f

Change-Id: I32b9873ec32841a08bdd05cca3a7baf861e1c507
2018-08-14 13:54:06 -07:00
Seigo Nonaka
eec33b7d2e Merge "Rewrite system fallback construction with new FontFamily" 2018-08-14 20:33:09 +00:00