Destroy sessions in following scenarios:
* when setSecurityLevel fail in openSession_1_1
* before handling mock errors in closeSession
* after releasing offline keySetIds
Bug: 153663446
Test: [Native]MediaDrmClearkeyTest
Test: VtsHalDrmV1_<0|1|2|3>TargetTest
Change-Id: I4357051e0be6daa199c5fc3e7505ce65d982e237
Some system services (e.g. SoundTriggerMiddleware) assume that
whenever they start, the audio HAL is in its default (reset) state.
init.rc scripts tie the lifetimes of the audio HAL and system
processes, but when using stop/start this is not the case, and this
may cause spurious crashes in this case.
stop/start is apparently being relied on in some test infrastructure,
so this change is needed to avoid causing problems for those systems
or false detection of problems, which are not actually present in
production.
Bug: 154029444
Test: Manually verify that the audio HAL is stopped on
'adb shell stop', restarted on 'adb shell start' and that the
system boots correctly after.
Change-Id: Icb6eeddfa48b1a49a4d48baae41f9086eb83a9ca
VtsValidateMediaCodecs and VtsValidateMediaProfiles
are just the GTest of vts_mediaCodecs_validate_test
and vts_mediaProfiles_validate_test.
Bug: 142397658
Bug: 154732221
Bug: 154725134
Test: $atest vts_mediaCodecs_validate_test
$atest vts_mediaProfiles_validate_test
Change-Id: I84ec8ae5ccbcfafb282b653a36e2ad25abdd6b27
Merged-In: I84ec8ae5ccbcfafb282b653a36e2ad25abdd6b27
getMicrophones() should return aggregated mic information
from all HW modules, not just primary.
Also:
- Fix assignment of mPrimaryHardwareDev that should be
first from HW module name and then according to primary output
if no module with name "primary" is loaded.
- Make sure we do not dereference mPrimaryHardwareDev if null.
Note that this should not happen with current rule that a primary module
must be present.
- Implement consistent locking scheme where both mPrimaryHardwareDev and
mAudioHwDevs are guarded by mHardwareLock
Bug: 154772890
Test: AudioManagerTest#testGetMicrophones
Change-Id: I7c9449bb705a6fbebdc0642166e58348d47b7ee8
The python test runs each gtest with various command line options.
Such logic should all be part of gtest for them to be parameterized
gtest.
Bug: 154351999
Test: atest VtsHalMediaC2V1_0TargetAudioDecTest \
VtsHalMediaC2V1_0TargetAudioEncTest \
VtsHalMediaC2V1_0TargetComponentTest \
VtsHalMediaC2V1_0TargetMasterTest \
VtsHalMediaC2V1_0TargetVideoDecTest \
VtsHalMediaC2V1_0TargetVideoEncTest
Change-Id: I8fe666305e198db0869f2c91b7f35fa0560abd9d
std::remove_if will only move elements around within the range it was
handed. In order to have the elements actually removed from the vector,
we need to erase() them.
Caught by clang-tidy:
/buildbot/src/googleplex-android/rvc-release/frameworks/av/media/codec2/vndk/util/C2InterfaceUtils.cpp:219:9:
warning: the value returned by this function should be used
[bugprone-unused-return-value]
(and 3 others)
Bug: 154665437
Test: TreeHugger
Change-Id: I9244baf7d6f46cce4c2d8f66fcf57b19c19d32ab
Merged-In: I9244baf7d6f46cce4c2d8f66fcf57b19c19d32ab
If an optional ID3v2.4 extended header was present, it would be
treated as a frame, causing parse errors. Fix by doing ID3v2.4
per-frame unsynchronization after skipping over the extended
header.
Bug: 154357105
Bug: 151448144
Test: CTS, manual w/ temporary additional logging.
Change-Id: Iaeb8cab866b98dcf97f81d3ade4a1c8d26add3a5
Call various functions after calling AAudioStream_release().
Bug: 154274446
Bug: 154274027
Test: this is a test
Change-Id: Ia0938362502b15a4ae5608f0619e0bc5ce78ca22
Free the AudioEndpoint and check for nullptr to
prevent accessing shared memory that had been freed.
This is to protect against calls to the stream after
AAudioStream_release() has been called.
Bug: 154274446
Bug: 154274027
Test: libaaudio/tests/test_various.cpp
Change-Id: I194d502fd48c4d31602ffce76aca6b28753ad7d2
Do not allow changing volume on an output when
the specified device is not supported by the
corresponding output profile.
There is a similar sanity check in setOutputDevices()
but there was none in AudioOutputDescriptor::setvolume().
Bug: 153411189
Test: atest AudioManagerTest
Test: manual audio smoke tests
Change-Id: I539697c54d70c442ba1ce38d212b43cd3ef0138c
This can prevent some loud noises during unit tests.
Also use std::unique_ptr
Bug: 154342174
Test: libaaudio/tests/test_various.cpp
Change-Id: I1c1dc0f4a6a29cf7d7a656392a81a325847de22d
The list of possible paths for the audio configuration
files is now retrieved using audio_get_configuration_paths()
function. All duplicated lists of known configuration
directories have been removed.
Bug: 153680356
Test: test audio on built image working
atest VtsHalAudioV6_0TargetTest VtsHalAudioPolicyV6_0TargetTest
Change-Id: I8c369442f5ca7baa17df95e6a001396fc9de5681
Merged-In: I8c369442f5ca7baa17df95e6a001396fc9de5681
Use listManifestByInterface in v1.2 servicemanager to list all
instances of drm service from the manifest. If it's lazy hal, the
service will be started as lazy hal service in getService.
Test: Play secure video in ExoPlayer
Bug: 153636761
Change-Id: Ifda4c9c433cfc1cd38980b10b8641f1db4460773
Do not systematically request a stream disconnect upon
EVENT_NEW_IAUDIOTRACK received AudioTrack but only if the new
audio Track properties have changed in such a way that the initial
contract is broken.
Bug: 139763500
Test: OboeTester TEST DISCONNECT
Test: OboeTester TEST OUTPUT while enabling/disabling Live Caption
Change-Id: I3b43275a888e23471fcd1ce20725f5731a77a255