Instead of storing full cipher URIs, only store partial URIs, and
construct the full URI as needed.
Bug: 124940460
Test: CTS
Change-Id: Iedf84e2f6657c0abd5a3dafaa5cabb1b6e854579
Modules contributing mainline modules (APK/APEX) should set
min_sdk_version as well as apex_available.
For now setting min_sdk_version doesn't change build outputs.
But build-time checks will be added soon.
This is second part of two CLs: covers non-mainline files
Bug: 152655956
Test: m
Change-Id: I55336e644990d3f175e0c011856b52ec600e452a
Modules contributing mainline modules (APK/APEX) should set
min_sdk_version as well as apex_available.
For now setting min_sdk_version doesn't change build outputs.
But build-time checks will be added soon.
This is one of two parts: covers mainline-related files.
Bug: 152655956
Test: m
Change-Id: I558b2d717d6cbae920db008d1b0f3ed61958937b
Force DIRECT flag if current playback thread is direct output thread.
This can happen when the playback is re-routed to direct output stream
by dynamic audio policy.
Bug: 130296239
Test: manual
Change-Id: I24efd87f74bacf6b769d3663e9521eb27b1704e9
This interim solution satisfies requirements of performance
tests (audioserver stopped together with zygote) and
requirements of VTS tests (audio HAL keeps running when
zygote stops).
Bug: 155364397
Test: atest VtsHalAudioV6_0TargetTest
atest VtsHalAudioEffectV6_0TargetTest
Change-Id: I111f0cc397024a38e146981d1e5299ce4f6bd5e2
If outBuffer is specificed, displayStride is the stride of the
outBuffer (line 595). Then, the "Output buffer too small" check
ends up comparing a buffer's width to the buffer's own stride
which effectively requires that a buffer's width is equal to it's stride.
Bug: 155485791
Test: cts -t android.media.cts.DecoderTest
Change-Id: Ia66591f816aac0d8aad5c1b5b9a0aeff2cc80185
Merged-In: Ia66591f816aac0d8aad5c1b5b9a0aeff2cc80185
common_time and mediadrm only has OWNERS file
for now, so no TEST_MAPPING FILE is added.
Bug: 155319496
Test: atest
Change-Id: Ie4d27837a3acdc554c4c4f259ad1ed25c1088e5b
If outBuffer is specificed, displayStride is the stride of the
outBuffer (line 526 for avc and line 521 for hevc). Then, the
"Output buffer too small" check ends up comparing a buffer's width
to the buffer's own stride which effectively requires that a
buffer's width is equal to it's stride.
For android.media.cts.DecoderTest#testCodecBasicHEVC, the test
has an outBuffer with width 720 and stride 768 which fails the
check.
Bug: b/146515640
Test: cts -t android.media.cts.DecoderTest
Change-Id: I732f77445cad5390895c8e43f46d11c423c9b2e4
An app (B) that asks for an exclusive stream can steal
an exclusive stream from an earlier app (A).
App B will be given the MMAP resource as a SHARED stream.
The stream for app A will be disconnected and released
by the service.
If app A reopens a stream then it will get a SHARED
stream.
The order of the opening of the streams is controlled by using a
recursive_mutex in AAudioService::openStream().
Bug: 129846760
Test: media/libaaudio/tests/test_steal_exclusive.cpp
Test: also
Test: Launch AudioTroubleMaker. It should say "EXCLUSIVE".
Test: Press Home button.
Test: Siren sound from AudioTroubleMaker should continue.
Test: Launch OboeTester
Test: TEST OUTPUT, then Open, Start
Test: You should get an MMAP SHARED stream on Pixel.
Test: Go back to AudioTroubleMaker. It should say "SHARED".
Change-Id: I7f8339d8ed62546520a9b46ed398418b41ca2832
This test starts an exclusive stream.
Then a few seconds later it starts a second exclusive stream.
The first stream should get stolen and they should both end up
as SHARED streams.
See comment at start of test_steal_exclusive.cpp for more information.
Bug: 129846760
Test: this is a test
Test: adb shell test_steal_exclusive
Change-Id: Idff0c394ccee2310dd2d38e7715f823e50955e73
Revert "Add isUidActiveOrForeground() for camera/audio to use."
Revert "Add isUidActiveOrForeground for camera/audio to use."
Revert submission 10829580-isUidForeground
Reason for revert: In CameraService.cpp, before this change, around "am.isUidActive", there was up to 300 ms retry. After this change, the code could move forward fast without retry, but at "mAppOpsManager->startOpNoThrow" call, for the same reason as uid is not updated fast enough, "mAppOpsManager->startOpNoThrow" could also fail.
This CL does not really fix the root cause, but it changes the timing and now the code fails at "mAppOpsManager->startOpNoThrow" call.
Also the timing change may also cause recent multiple CTS test failures.
Bug: 154570809, 155032617, 154849083
Reverted Changes:
Iffed63293:Add isUidActiveOrForeground() for camera/audio to ...
I3685e0c8d:Add isUidActiveOrForeground() for camera/audio to ...
I51ed1fe78:Add isUidActiveOrForeground for camera/audio to us...
Change-Id: I8acde2524201b6c6d0d5c0ff9cfb2053ffbcb8ef
Shifting a signed 32-bit value by 31 bits is implementation-defined
behavior, so we change the value to unsigned.
Bug: 147147992
Test: TreeHugger
Change-Id: Iaefb85f77e5a9f8e7cd361a25a1c05fffc35ccb1
Handle the case where the HAL doesn't advertise
preCorrectionActiveArraySize by initializing it to activeArraySize.
Test: "dumpsys media.camera" before and after the change
Bug: 145300768
Change-Id: I1281686d9b324793a4a99c6a4ddf5d693172507b
For easy transition from SchedTune to UtilClamp, direct access to these
cgroups should be abstracted by using task profiles. Replace writepid
commands with new task_profiles command.
Bug: 155419956
Test: change .rc file and confirm task profile is applied
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Id00370b25af973a4b3813a4a1d6ccbd1e555c87f
Merged-In: Id00370b25af973a4b3813a4a1d6ccbd1e555c87f
Release all buffers on Codec2 stop() in order to quick release in case
of using multiple Codec's from application.
Bug: 146679370
Test: atest CtsMediaTestCases -- --module-arg CtsMediaTestCases:size:small
Change-Id: I7a025c2d349442f93dbfab0bd1892df46229ef56
Enable clang thread safety analysis. Convert comments on TS
into directives. Fix missing lock acquisitions. Add missing
default initializers for the fields of UidPolicy and
SensorPrivacyPolicy
Also remove unused fields mpAudioPolicyDev and mpAudioPolicy
from AudioPolicyService.
TODO: Consider protecting pointers to command threads,
APM instance and the client, and system usages with a separate
lock.
Bug: 70398235
Bug: 155336464
Test: make, flash, and test audio on device
execute "adb shell cmd media.audio_policy" commands
Change-Id: I47b132c8b5c977812fad5c89fa57882a37779c18
Merged-In: I47b132c8b5c977812fad5c89fa57882a37779c18
A packet with size 0 would never be removed from the queue,
and thus processed over and over again.
Bug: 129282427
Test: PoC, manual
Change-Id: Ia03a2b23df555a3c8ab53aac4589cb9b0a1b45a8