hidl-generated makefiles are now generated such that bpfmt(file) == file.
Bug: 67417008
Test: enable bpfmt hook
Change-Id: I1f69d292bc23a7cc293a66110cb02d597e1019ad
This patch ports a change to the HAL interfaces done in master in
order to have the same Audio common HAL interface in both AOSP and master.
This is needed as the Bluetooth HAL uses the audio common HAL and needs
to be frozen in the same state in both AOSP and MASTER.
Add audio format for LHDC Bluetooth codec.
Also add missing audio sources and devices in xsd.
Bug: 124247199
Bug: 120395342
Test: make
Change-Id: Ib55c7d351074d8ef75747bcb1195e1ce15ed8b20
Merged-In: Ib55c7d351074d8ef75747bcb1195e1ce15ed8b20
This patch ports a change to the HAL interfaces done in master in
order to have the same Audio common HAL interface in both AOSP and master.
This is needed as the Bluetooth HAL uses the audio common HAL and needs
to be frozen in the same state in both AOSP and MASTER.
Add AAC_LATM*, CELT and APTX_ADAPTIVE to the list
of audio formats.
Bug: 124247199
Bug: 123082414
Test: make
Change-Id: Id75e1f5016929d5a67e777774aaa892df6f91e78
Merged-In: Id75e1f5016929d5a67e777774aaa892df6f91e78
This patch ports a change to the HAL interfaces done in master in
order to have the same Audio common HAL interface in both AOSP and master.
This is needed as the Bluetooth HAL uses the audio common HAL and needs
to be frozen in the same state in both AOSP and MASTER.
This commit adds the following audio capture sources:
- AUDIO_SOURCE_VOICE_PERFORMANCE: for real time live performances like Karaoke.
- AUDIO_SOURCE_ECHO_REFERENCE: for capturing the reference signal to suppress by an echo
canceller. Protected by privileged permission CAPTURE_AUDIO_OUTPUT.
Also added device AUDIO_DEVICE_IN_ECHO_REFERENCE selected when the requested
capture source is AUDIO_SOURCE_ECHO_REFERENCE.
Bug: 124247199
Bug: 118203066
Test: CTS tests for audio capture
Change-Id: Ia93550b278733ae9cc5cda731b014421002fde35
Merged-In: Ia93550b278733ae9cc5cda731b014421002fde35
This patch ports a change to the HAL interfaces done in master in
order to have the same Audio common HAL interface in both AOSP and master.
This is needed as the Bluetooth HAL uses the audio common HAL and needs
to be frozen in the same state in both AOSP and MASTER.
Currently this is used to indicate the output device
when the input stream is from an intermediate processing
module like MSD.
Bug: 124247199
Bug: 120859615
Test: make
Change-Id: I60bac5c24a263ab0b8965e9dbf9514445e88c270
Merged-In: I60bac5c24a263ab0b8965e9dbf9514445e88c270
This patch ports a change to the HAL interfaces done in master in
order to have the same Audio common HAL interface in both AOSP and master.
This is needed as the Bluetooth HAL uses the audio common HAL and needs
to be frozen in the same state in both AOSP and MASTER.
Bug: 111454766
Bug: 124247199
Test: build
Change-Id: I00c28aa02473ce83b0d9b404b5cf33410c73a2c8
Merged-In: I00c28aa02473ce83b0d9b404b5cf33410c73a2c8
Register Bluetooth Audio Hal v2 by Audio HAL service so Bluetooth stack
can fetch the service interface as well.
Bug: 111519504
Test: manual
Change-Id: I3ac8c0472c58dd4d8a9b1ad8408313b80282cc85
The new format is described in tools/metalava/FORMAT.md.
Fixes: 116589402 Switch signature files over to the v2 format
Fixes: 112626813 Drop "synchronized" modifier from the signature format
Fixes: 122358225 Omit overriding methods that only differ in final [...]
Fixes: 73088715 API Review: Need doclava to output nullability
Fixes: 79739773 API Review: Metalava enforcing constants are constant
Exempt-From-Owner-Approval: Large-scale tooling change
Test: make sdk, make update-api, make checkapi
Change-Id: I767f9fb2941789615c9513072a381e79a5654373
Merged-In: I2943d9a65c24e7ca8fb9ae9b69f7edf06173f467
libxml2 now depends on libandroidicu.
Add the same dependency into the VTS.
TODO: b/121468463 to remove ICU from VtsHalAudio
Bug: 117094880
Test: m checkbuild
Merged-In: I105e7ad1517ecf8780adfb730650e1ad82f65857
Change-Id: I105e7ad1517ecf8780adfb730650e1ad82f65857
This module is for API check of java file generated from
audio_policy_configuration.xsd.
audio_policy_configuration.docs is added to required in
impl library because API check whenever building impl
library.
Bug: 80453829
Test: m -j && make update-api && make check-api
Change-Id: I49499ec244c390ed1e6e9e8ca77d08d7da69ac59
Without this patch vendors can not do any vendor extension extending
the audio enums as it would fails the XSD validation.
Long term, the config xml parsing should be moved in the HAL, until then
allow extension if they are prefixed with EX_.
Test: xmllint --noout --schema hardware/interfaces/audio/5.0/config/audio_policy_configuration.xsd --xinclude out/target/product/*/vendor/etc/audio_policy_configuration.xml
Bug: 117967786
Change-Id: Ie44490824b5b50fdebb50a82299ea348d2a34b84
Signed-off-by: Kevin Rocard <krocard@google.com>
So that it can be used by the Bluetooth HAL.
Test: compile
Change-Id: I2e2b1e12e1f837183c4edbd1d330a13a67d1ecae
Merged-In: I2e2b1e12e1f837183c4edbd1d330a13a67d1ecaf
Signed-off-by: Kevin Rocard <krocard@google.com>
Port audio HAL V5 to AOSP for BT HAL.
The implementation is not ported as that would require to port an
additional ~30 patches and is not needed by the BT team.
Bug: 118203066
Test: Compile
Change-Id: If99a5645d19c9780019704ea4f51f8114d83ee8e
Merged-In: If99a5645d19c9780019704ea4f51f8114d83ee8f
Signed-off-by: Kevin Rocard <krocard@google.com>
This reverts commit 34e4fb2a84.
Reason for revert: b/117506164 is fixed and we no longer suppress ASAN
Bug: 117580200
Change-Id: Ib981bddaa4e218cd13b274db5444f585f3487327
Without this patch vendors can not do any vendor extension extending
the audio enums as it would fails the XSD validation.
Long term, the config xml parsing should be moved in the HAL, until then
allow extension if they are prefixed with EX_.
Test: xmllint --noout --schema hardware/interfaces/audio/4.0/config/audio_policy_configuration.xsd --xinclude out/target/product/*/vendor/etc/audio_policy_configuration.xml
Bug: 117967786
Change-Id: Ie44490824b5b50fdebb50a82299ea348d2a34b84
Signed-off-by: Kevin Rocard <krocard@google.com>
Would the legacy HAL return -ENOENT while retrieving an effect,
the enumeration has to be aborted, and the effects queried so far
need to be returned. A missing 'break' was causing returning
no effects at all.
Bug: 117567478
Test: make
Change-Id: I7cc05004f88b39272d06d2ed33a0693f8e1e3d04
Merged-In: I7cc05004f88b39272d06d2ed33a0693f8e1e3d04
Until the underlying bug is fixed, do not produce a sanitized
binary.
Bug: 117506164
Bug: 117580200
Test: m && SANITIZE_TARGET=address m
Change-Id: I4e6d1206512513c687f7ae065d2974c55c617b61
The test was assuming Stream::getFrameCount() would return the
AudioConfig::frameCount used to create the stream, similarly
to the sampleRate or the channelMask.
Nevertheless this is not the case as the AudioConfig::frameCount
field is not to used by Stream::openOutputStream (nor Input) as
the buffer size is chosen by the HAL, not the framework.
Thus the test can not assume the frameCount chosen by the HAL and
must not test for a particular value.
Test: atest VtsHalAudioV4_0TargetTest
Bug: 116169974
Change-Id: Ibbf0825f540957e01e7c512d851cb9628991f4c4
Signed-off-by: Kevin Rocard <krocard@google.com>
Before this patch the default microphone was required to have characteristics
although it is not always an attached device, thus its characteristics can not
be known by the HAL. Additionally, the HAL might not know the active
microphone info of a input stream if it has not been started yet.
This patch only tests microphones which characteristics are reported by the HAL
and start the input stream before requesting active microphones.
Bug: 109787938
Test: vts-tradefed run vts --module VtsHalAudioV4_0Target
Change-Id: If55bfc8210d4f9443d34951f717c6772b46dde04
Merged-In: If55bfc8210d4f9443d34951f717c6772b46dde04
The test creates an instance of the Audio HAL then destroys it and create it again.
The test assumed that the destruction was synchronous when in fact it is async with
no way of knowing when the object has been destroyed.
As a result, until a better solution is found, sleep for 100ms to hopefully let enouth
time for the HAL destructor to return.
Bug: 112566489
Test: adb shell /data/nativetest64/VtsHalAudioV4_0TargetTest/VtsHalAudioV4_0TargetTest --gtest_filter=*OpenPrimaryDeviceUsingGetDevice
atest VtsHalAudioV4_0TargetTest
Change-Id: I0ec75c12007d39060232632708722df5bf0f99d7
Signed-off-by: Kevin Rocard <krocard@google.com>
A test was not checking for the Result::isOk() resulting
in an assert being triggered in HIDL code if the HAL crashed.
Test: (sleep 0.3; adb shell pkill audio) &
adb shell /data/nativetest64/VtsHalAudioV4_0TargetTest/VtsHalAudioV4_0TargetTest
# Test finishes in failure but does not crash
Signed-off-by: Kevin Rocard <krocard@google.com>
Change-Id: I97a6213fe82a5e9a6eb333dc1dc2476102610b58
For device supporting getCapturePosition,
VTS only allowed unprepared stream to return INVALID_STATE.
Now also allow for the stream to return 0 frames similarly to the other
non started states.
Test: vts-tradefed run commandAndExit vts --module VtsHalAudioV2_0Target
Bug: 110367728
Cherry-piked from: d01dc3edac9e92981e7ae419d0e7622f753acf94
Merged-In: Ibdf8df8cb8809e98c40a50035371df6893fe4da4
Change-Id: Ibdf8df8cb8809e98c40a50035371df6893fe4da4
Signed-off-by: Kevin Rocard <krocard@google.com>
(cherry picked from commit 6c9c6e62c1)