Some layers, for example ScreenDecorOverlay*, only carry black, white or gray
with some transpanrency, these values are special as they are color space
agnostic. We don't need to do color conversion on them, instead we want to
intercept the color space before we send to hardware composer for validation.
This patch adds an API to allow this to happen, layers that can be considered
color space agnostic can call this API.
BUG: 126616348
Test: Build, flash and boot. Verify by calling in Letterbox.
Change-Id: I2e1384865bbae6c1bca5ab55962af6a4d529d81d
Generalize runtime option checking functions, so that they can be used
to check options other than the ones starting with `-Xgc:`
Test: core/jni/runtime_native_boot-flags-test.sh
Bug: 72446017
Bug: 120794191
Bug: 123754583
Bug: 119800099
Change-Id: I263a177486f8e24ce92928973f7c8853baf0983b
When wrap.sh is used in a debuggable app, AssetManager tries to execute
idmap2 in the app's security context, not in zygote context. And idmap2
isn't allowed to execute in the app's context, thus making an abort.
The abort makes Android studio can't debug the app. To avoid the abort,
check if idmap2 is accessible before executing it.
Bug: 124109020
Test: test manually that android studio can debug the app with this
Test: change.
Change-Id: I82d772358b2266433f82319896a4ca662cc3c273
This is in preparation of checking other device configuration flags.
Test: core/jni/runtime_native_boot-flags-test.sh
Bug: 72446017
Bug: 120794191
Bug: 123754583
Bug: 119800099
Change-Id: I14d6defe5f7e9fcf2f3dd27a4d0fae81f2aec596
There are some potential issues with the current usage of
KeyedVector (see bug). To work around these issues,
use the official std::unordered_map.
Bug: 126161446
Test: presubmit
Change-Id: I86873a3929ba068c8bb9e60699978d7726a1a444
This patch adds in AudioSystem setter/getter of volume index
and also getter on index min and max according to the given
audio attributes.
Bug: 124767636
Test: dumpsys media.audio_policy
Change-Id: Ia20fcfbf5e20c98de5eb07551c299dc99d678fb8
Signed-off-by: François Gaffie <francois.gaffie@renault.com>
This CL adds introspection APIs for Audio Volume group
and callback notification on group volume change.
It allows to keep the same level of service available today
in CarAudioManager and is a starting point to get rid of Stream Alias
hard coded in AudioServer.
Bug: 124767636
Test: dumpsys media.audio_policy
Change-Id: I48909df93c146f071acd24cd3ecc608cb98b4d7e
Signed-off-by: François Gaffie <francois.gaffie@renault.com>
expose ISurfaceComposer::getAllowedDisplayConfigs to SurfaceControl.
Test: manual test to call getAllowedDisplayConfigs() from SurfaceControl
observe config change.
Bug: 122905403
Change-Id: I0587ac5ed2eb29788c2ce941d9c54ebfd215ddf9
In order to ensure only one matching algorithm is implemented in the
audio policy engine, we cannot use the list of audio product strategy
to let the client of this API inferring the product strategy to use.
It shall request the audio policy manager which product strategy shall be
followed by a given Audio Attributes.
Bug: 124767636
Test: dumpsys media.audio_policy
Change-Id: I372a47df4a35efd68a3ea327581af54823997dba
Signed-off-by: François Gaffie <francois.gaffie@renault.com>
Useful to link together the pids of the zygote and its children in logcat
output.
Test: Flash and boot, run "adb logcat"
Change-Id: I524b70aed7d1ce7a378df0e2b2063e23f1f9a454
* changes:
Teaches the System Server to enable the Zygote's blastula pool.
Added pool management code around zygote state changes.
Improved file descriptor cleanup in Zygote.
Bug: 123301872
Bug: 117601185
Test: Manual (Ie18811ba29a1db163aca08472b04ae185e9344f0)
Test: CTS (Ie4b0a232effc67ab7a7fc6070302c722177cadfa)
Test: Infeasible (verify desired ColorSpace is used)
When calling setTargetColorSpace on an ImageDecoder for an animated
image, pass this to the AnimatedImageDrawable. Also respect an EXTENDED
ColorSpace as a cue to decode to RGBA_F16, as with Bitmaps.
Call ImageDecoder#checkState for AnimatedImageDrawables, as with
Bitmaps.
Change-Id: I5f6e11ee14ce4477bfedf2d1fdde8e15ed5f24d5
Currently libnativeloader appends vendor lib path if apk is from vendor
partition. Similar to this, as part of mainline core, we should add
product lib path if apk if from product partition.
Bug: 124705551
Test: m -j && tested from crosshatch with product apps (such as Wallpaper)
Change-Id: Iaa8d0ea61b1b9ab8a1da676a492f75c6a5d71d5d
The previous implementation allocated an array of size
CMSG_SPACE(count) to store CMSG_LEN(count * sizeof(int)) elements, which
leads to bad things happening for values of count greater than 1 on
32-bit, and 2 on 64-bit.
Test: atest android.net.LocalSocketTest
Test: atest android.net.cts.LocalSocketTest
Change-Id: I0a9502c3358d8fa92d2d20e344c6270d6baedc07
The "gctype" device configuration flag (from the "runtime_native_boot"
namespace) was a string passed verbatim as an argument to the runtime
option "-Xgc". It was too generic, conveyed no typing information, and
was error-prone (there was no control over what was passed from the
server to the zygote, and then to the runtime).
This change replaces "gctype" with a specific, Boolean
"enable_generational_cc" flag. This new flag better reflects the
nature of the experiment to be conducted (either enable or disable
generational garbage collection in ART's concurrent copying
collector).
Test: core/jni/runtime_native_boot-flags-test.sh
Bug: 72446017
Bug: 120794191
Bug: 123754583
(cherry picked from commit 72b16f0ad0a4f0f81c0db4a24ecd6629348950e0)
Change-Id: I5f30f38914bb44d6ce9dc6870ee2c566ce66278a
Merged-In: I30a73171c0dc3c7bc891c4f164eed0ba42b0f420
These flags live in device configuration namespace
`runtime_native_boot`. Exercise them by checking that they are passed
to the zygote process(es) as a runtime option after a reboot.
At the moment this test only checks flag `gctype`, which is the only
flag currently implemented in namespace `runtime_native_boot`.
Test: core/jni/runtime_native_boot-flags-test.sh
Bug: 72446017
Bug: 120794191
Bug: 123524494
Bug: 123754583
(cherry picked from commit 0645bcb84393b8048ceee9df5f90c5ba2dfa0184)
Change-Id: I015fe475818162f5bbc7f18a64764cb14ab0a768
Merged-In: I6cf43c3ee0d405fb1b69a450587dd712f911358d
ART does not support changing the garbage collector type/configuration
dynamically at the moment, so we can only change it when the runtime
starts, i.e. at boot time.
Also materialize "gctype" and "runtime_native_boot" as named constants.
Bug: 120794191
Bug: 72446017
Test: adb shell device_config put runtime_native_boot gctype nogenerational_cc && adb reboot
Test: adb shell device_config put runtime_native_boot gctype generational_cc && adb reboot
(cherry picked from commit 7b098c8487a05360de8f80fde48cfd28a3aa8321)
Change-Id: Ied0eacf46ab92ba128d0a538a314f42c18c5b8f5
Merged-In: Ibf765a5f442136d6327be99786ea9ae4b4537d59