Commit graph

331 commits

Author SHA1 Message Date
Treehugger Robot
67d8a557e8 Merge "[Bluetooth apex] Use new apex name" am: 2412da0826 am: a326b313f7
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2192236

Change-Id: I892c3da23abe265c7ccaf414439ab48ed548a4f7
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-25 03:49:17 +00:00
William Escande
2591c3d0cf [Bluetooth apex] Use new apex name
The Bluetooth apex name is now called com.android.btservices

Bug: 243054261
Test: Build
Change-Id: Ib63646722cbef948b5198fc5f2a9b5ac2ca52ae3
2022-08-22 11:27:58 -07:00
jiabin
315925d83b [automerge] Fix array out of bound in audioTransportToHal. 2p: f16c6d3a57 2p: 0d43585645 am: 3074154353
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19214732

Change-Id: Id833d761f83192c1f6fe912318bde91bb7d42761
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-11 23:27:13 +00:00
jiabin
3074154353 [automerge] Fix array out of bound in audioTransportToHal. 2p: f16c6d3a57 2p: 0d43585645
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19214732

Bug: 237288416
Bug: 237717857
Change-Id: I65135fa57c7ba449ad856ef5b4081c3580fb4c6f
Merged-In: I1fcfa29d7841a1cb73bafb1ea92f3b1630992ae9
2022-07-07 23:25:08 +00:00
jiabin
f16c6d3a57 Fix array out of bound in audioTransportToHal.
The number of audio profile and extra audio descriptor must not be
greater than the maximum value.

Bug: 237288416
Bug: 237717857
Test: repo step in bug
Test: atest android.hardware.audio.common@7.0-util_tests
Change-Id: I1fcfa29d7841a1cb73bafb1ea92f3b1630992ae9
Merged-In: I1fcfa29d7841a1cb73bafb1ea92f3b1630992ae9
(cherry picked from commit 0ee75ca925)
2022-07-07 23:24:30 +00:00
Sadaf Ebrahimi
d10fba30be Merge "Track libxml2 API changes." am: 3096c58650 am: d21a771983
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2089706

Change-Id: I4bca5b13916b65bfd1681c5d9929daa606a33d6b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-05-12 00:54:52 +00:00
Elliott Hughes
2aa03ce7bd Track libxml2 API changes.
This function is now deprecated upstream, and their advice is to just
not call it; xmlCleanupParser() will do this stuff anyway.

Test: treehugger
Change-Id: I38a80d1f77c1beb2c1c8088a9e0df3bb0cbd9496
2022-05-10 14:20:21 -07:00
Treehugger Robot
45759188e9 Merge "Disable FilterTest/1#FilterOutNonVendorTags on HWASan." am: e19d685e2f am: 3aded47933
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2076912

Change-Id: Id1d2f0cc9b92673b530a7e97200f381d251dd13f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-29 18:06:27 +00:00
Florian Mayer
40a4639e51 Disable FilterTest/1#FilterOutNonVendorTags on HWASan.
Bug: 230535046
Change-Id: I0f1d4ff10b98fe5311a3db785560b658133ed551
2022-04-26 17:37:35 -07:00
William Escande
d9d513fd47 Clear apex.go entries for bluetooth libs
Test: Build + TH + boot phone & use bluetooth
Bug: 216433795
Change-Id: Ib1f9fee90006c73e5726a208e6cba8647967f5f4
2022-03-02 20:27:06 +01:00
Chih-hung Hsieh
34593d4e2a Merge "Add timed out test files to tidy_timeout_srcs" am: ff54f73b4f am: fa83970b3a am: 581616e658
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1992232

Change-Id: I2eac13fe3b5ab0b4f15d6ceadf376e5e74124a81
2022-02-24 01:32:09 +00:00
Chih-Hung Hsieh
ad1bf31b78 Add timed out test files to tidy_timeout_srcs
* Timed out runs do not show any warning messages.
* These test files cannot finish clang-tidy runs with
  the following settings:
    TIDY_TIMEOUT=90
    WITH_TIDY=1
    CLANG_ANALYZER_CHECKS=1
* When TIDY_TIMEOUT is set, in Android continuous builds,
  tidy_timeout_srcs files will not be compiled by clang-tidy.
  When developers build locally without TIDY_TIMEOUT,
  tidy_timeout_srcs files will be compiled.
* Some of these test modules may be split into smaller ones,
  or disable some time consuming checks, and then
  enable clang-tidy to run within limited time.

Bug: 201099167
Test: make droid tidy-hardware-interfaces_subset
Change-Id: I1de28f1572fff368f67eab512fffec9f2e5c2a9b
2022-02-18 17:25:41 -08:00
Treehugger Robot
4f4c01be3a Merge "Audio: Load Bluetooth AIDL HAL" am: 9938caf08b am: ea8522964b am: c43c0bcbf8
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1942860

Change-Id: Ia88c5a97417146792a10632300939c943a28f001
2022-02-17 01:37:01 +00:00
Josh Wu
3f8f5997ad Audio: Load Bluetooth AIDL HAL
Test: m android.hardware.audio.service
Bug: 203490261
Change-Id: If518ed69331489bd9aeb2a0c58e17c2917e3c0cf
2022-02-16 12:01:59 -08:00
Jasmine Cha
b0a67561e6 audio: use binder threadpool am: d90c47420a am: 142ba0857b am: cc75285f2e
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1986309

Change-Id: I77d258201a43d69555e6ac4bbba2831674f40958
2022-02-16 05:44:50 +00:00
Jasmine Cha
d90c47420a audio: use binder threadpool
Support to communicate with other service with AIDL interface.

Bug: 215463744
Test: build pass

Signed-off-by: Jasmine Cha <chajasmine@google.com>
Change-Id: I13da2121623779b0ba21d29cf39c11abc7b96dd9
2022-02-16 10:07:57 +08:00
Mikhail Naganov
872beb16ee Make AUDIO_USAGE_NOTIFICATION_EVENT available to HALs am: a85cebb63e am: 783f8f14e2 am: 6ae5c189c2
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1983828

Change-Id: Ibb5768f2e6ad8d7d2eba6caece5f7a495d7d2bd6
2022-02-14 18:34:05 +00:00
Mikhail Naganov
a85cebb63e Make AUDIO_USAGE_NOTIFICATION_EVENT available to HALs
This aligns the list of usages between the framework
and HALs

Bug: 199193042
Test: atest android.hardware.audio@7.1-util_tests
Test: atest android.hardware.audio.common@7.1-util_tests
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: I4d7fdbacff87eebcbc8d68dd6ed8cefdd52aa84e
2022-02-12 00:03:49 +00:00
Mikhail Naganov
ec8ef38ad9 audio: Add android.hardware.audio[.common]@7.1-util modules
android.hardware.audio.common@7.1-util and
android.hardware.audio@7.1-util utilize the 7.1 XSD enums
conversion library and thus can work with the new
enum strings added in 7.1

Bug: 218504031
Test: atest VtsHalAudioV7_1TargetTest
Test: atest android.hardware.audio.common@7.0-util_tests
Test: atest android.hardware.audio.common@7.1-util_tests
Test: atest android.hardware.audio@7.0-util_tests
Test: atest android.hardware.audio@7.1-util_tests
Change-Id: Icc5a354cdc2e377a2a2424c28377bcb0ba05bf4e
(cherry picked from commit fa4a4f8da7)
Merged-In: Icc5a354cdc2e377a2a2424c28377bcb0ba05bf4e
2022-02-12 00:03:49 +00:00
Mikhail Naganov
fa4a4f8da7 audio: Add android.hardware.audio[.common]@7.1-util modules
android.hardware.audio.common@7.1-util and
android.hardware.audio@7.1-util utilize the 7.1 XSD enums
conversion library and thus can work with the new
enum strings added in 7.1

Bug: 218504031
Test: atest VtsHalAudioV7_1TargetTest
Test: atest android.hardware.audio.common@7.0-util_tests
Test: atest android.hardware.audio.common@7.1-util_tests
Test: atest android.hardware.audio@7.0-util_tests
Test: atest android.hardware.audio@7.1-util_tests
Change-Id: Icc5a354cdc2e377a2a2424c28377bcb0ba05bf4e
2022-02-09 00:26:44 +00:00
Eric Laurent
16894f0e06 audio: add new enums for 7.1 HAL
Add the following enums to 7.1 audio HAL:
- Spatial audio:
   spatializer output flag
   front wide channel masks

- Bluetooth LE
 broadcast audio device

Bug: 187446271
Test: m android.hardware.audio.common@7.1-enums
Change-Id: I9bfb937ece3a07a7844877de5f355ece1141f92d
(cherry picked from commit 5b8529a1da)
Merged-In: I9bfb937ece3a07a7844877de5f355ece1141f92d
2022-02-07 19:55:51 +00:00
Mikhail Naganov
563238913b Audio HAL V7.1: Update VTS
Mechanical updates from global greps. Updated test code
to use new methods from V7.1.

Added missing checks for null pointers in
PcmOnlyConfig...StreamTest::releasePatchIfNeeded for V7.

Bug: 214426419
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Id3a99993bf2ee0c87d44f668d759f7c10db9a435
(cherry picked from commit 40fde0bc07)
Merged-In: Id3a99993bf2ee0c87d44f668d759f7c10db9a435
2022-02-05 00:44:59 +00:00
Mikhail Naganov
8140f5660a Audio HAL V7.1: Update the default implementation
Split versions of "common" and "core" types from
the version of the interfaces. "Common" and "core"
versions are set to 7.0.

Implemented new methods of V7.1 interfaces.

Bug: 214426419
Test: m android.hardware.audio@7.1-impl
Test: m android.hardware.audio@7.0-impl
Test: m android.hardware.audio.effect@7.0-impl
Test: m android.hardware.audio@6.0-impl
Change-Id: Ic4c44d4ac9bbfa7b62695866b9aa7473658390b2
(cherry picked from commit 7d01538eec)
Merged-In: Ic4c44d4ac9bbfa7b62695866b9aa7473658390b2
2022-02-05 00:44:17 +00:00
Mikhail Naganov
51a7e13849 Audio HAL V7.1: Interfaces & types
Introduced V7.1 of the core HAL. The only added methods of
the interfaces are those for creating objects implementing
the new version. HIDL types are from V7.0.

APM XSD is cloned for adding new enums. Provided the minor
update for the enums utility library.

CTS-Coverage-Bug: 215647214
Bug: 214426419
Test: m
Change-Id: I3caa2fda2fb5d7d8e8292e23fb2cf0e32e05c146
(cherry picked from commit a0cd944914)
Merged-In: I3caa2fda2fb5d7d8e8292e23fb2cf0e32e05c146
2022-02-05 00:43:27 +00:00
Eric Laurent
5b8529a1da audio: add new enums for 7.1 HAL
Add the following enums to 7.1 audio HAL:
- Spatial audio:
   spatializer output flag
   front wide channel masks

- Bluetooth LE
 broadcast audio device

Bug: 187446271
Test: m android.hardware.audio.common@7.1-enums
Change-Id: I9bfb937ece3a07a7844877de5f355ece1141f92d
2022-01-27 21:05:04 +01:00
Mikhail Naganov
40fde0bc07 Audio HAL V7.1: Update VTS
Mechanical updates from global greps. Updated test code
to use new methods from V7.1.

Added missing checks for null pointers in
PcmOnlyConfig...StreamTest::releasePatchIfNeeded for V7.

Bug: 214426419
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Id3a99993bf2ee0c87d44f668d759f7c10db9a435
2022-01-25 01:24:52 +00:00
Mikhail Naganov
7d01538eec Audio HAL V7.1: Update the default implementation
Split versions of "common" and "core" types from
the version of the interfaces. "Common" and "core"
versions are set to 7.0.

Implemented new methods of V7.1 interfaces.

Bug: 214426419
Test: m android.hardware.audio@7.1-impl
Test: m android.hardware.audio@7.0-impl
Test: m android.hardware.audio.effect@7.0-impl
Test: m android.hardware.audio@6.0-impl
Change-Id: Ic4c44d4ac9bbfa7b62695866b9aa7473658390b2
2022-01-25 01:24:52 +00:00
Mikhail Naganov
a0cd944914 Audio HAL V7.1: Interfaces & types
Introduced V7.1 of the core HAL. The only added methods of
the interfaces are those for creating objects implementing
the new version. HIDL types are from V7.0.

APM XSD is cloned for adding new enums. Provided the minor
update for the enums utility library.

CTS-Coverage-Bug: 215647214
Bug: 214426419
Test: m
Change-Id: I3caa2fda2fb5d7d8e8292e23fb2cf0e32e05c146
2022-01-25 01:24:52 +00:00
Carter Hsu
76fe18d229 Merge "audio: Support 64bit configuration on 32+64bit compatible OS" am: f665b8fa86 am: 66cfe34ef4 am: 0e98137981 am: e3d00ca753
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1891181

Change-Id: Ib2580f903900723f4408ed59b4d08a4cad488c56
2021-11-17 06:13:09 +00:00
Carter Hsu
150dded787 audio: Support 64bit configuration on 32+64bit compatible OS
The default value is 'prefer32', in order to run the hardware audio
service as 64 bit on a 32+64bit OS, please add the content below
into 'device.mk':

SOONG_CONFIG_NAMESPACES += android_hardware_audio
SOONG_CONFIG_android_hardware_audio += \
	run_64bit
SOONG_CONFIG_android_hardware_audio_run_64bit := true

Bug: 205240941
Test: build pass
Signed-off-by: Carter Hsu <carterhsu@google.com>
Change-Id: Ic7632a4f80298721512cd538ce93945b82a9981f
2021-11-16 00:44:36 +00:00
Treehugger Robot
16db22ab79 Merge "Fix the integration issue for HAL 2.2" am: c4718b793c am: 5e070c733a am: ee5538cb27 am: dda57e13d1
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1881111

Change-Id: Idb9763abf1aa5c846cff4c109f122c040bb2988a
2021-11-12 13:41:43 +00:00
Alice Kuo
95ba6a2181 Fix the integration issue for HAL 2.2
Bug: 150670922
Bug: 197297498
Test: A2DP & LE aduio stream works well with HIDL 2.1/2.2
Change-Id: I64113dd4a229874b2d17ae71d088abafd8197cfd
2021-11-09 22:56:30 +08:00
Keun young Park
ab35e0a3d0 Expose HIDL HALs to car framework apex
- all HALs also get //apex_available:platform as HAL should
  be available for platform

Bug: 192665266
Test: build
Change-Id: Ic6781447628761a8e8a9aa31e473dfc340af9989
2021-10-07 23:05:53 +00:00
Mikhail Naganov
420a5407cd audio: Fix handling of relative XML include paths in VTS
Pass "no fixup base dirs" flag to the XInclude processor
to avoid modifications of the top-level elements from
included XML files as a result of "fixup."

Added tests to ensure that all relevant XInclude scenarios
work.

Bug: 192619060
Test: atest -host android.hardware.audio.common.test.utility_tests
Change-Id: Id595c9fd30be378d76387ee55a8937e0bf28d1cd
Merged-In: Id595c9fd30be378d76387ee55a8937e0bf28d1cd
2021-07-08 17:29:23 +00:00
TreeHugger Robot
55ffc45878 Merge "audio: Fix handling of relative XML include paths in VTS" into sc-dev am: 3456ce6816 am: 569611f123
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/15193448

Change-Id: I0e71a9d93ff7153fa785f29e219f1b04421ddf8a
2021-07-08 16:58:22 +00:00
TreeHugger Robot
3456ce6816 Merge "audio: Fix handling of relative XML include paths in VTS" into sc-dev 2021-07-08 16:31:37 +00:00
Mikhail Naganov
13c6796528 audio: Fix handling of relative XML include paths in VTS
Pass "no fixup base dirs" flag to the XInclude processor
to avoid modifications of the top-level elements from
included XML files as a result of "fixup."

Added tests to ensure that all relevant XInclude scenarios
work.

Bug: 192619060
Test: atest -host android.hardware.audio.common.test.utility_tests
Change-Id: Id595c9fd30be378d76387ee55a8937e0bf28d1cd
2021-07-07 21:08:42 +00:00
TreeHugger Robot
f654cb4b80 Merge "Revert "audio: exclude the echo reference device in capture position test"" into sc-dev am: 8c5166b2f5 am: eb4b61958e
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/15223272

Change-Id: Id48b51227ea17fea5c7921fc0e4925075e22e110
2021-07-07 18:57:31 +00:00
Mikhail Naganov
dd0e20eba3 Revert "audio: exclude the echo reference device in capture position test"
This reverts commit b22f307ccf.

Reason for revert: As explained in b/192307382#comment12, the HAL must provide capture positions for the echo reference input regardless of whether there is any actual output.

This should not affect O6/R4 as according to b/192307382#comment10, the VTS tests pass w/o this patch after the HAL has been fixed.

Bug: 192307382
Change-Id: I224bd9de1dcb2e2c8dc138dbfd85f848378aea4f
Test: VtsHalAudioV7_0TargetTest --gtest_filter=*PcmOnlyConfigInputStreamTest*
2021-07-07 17:07:15 +00:00
Carter Hsu
f03a36610c Merge "audio: exclude the echo reference device in capture position test" into sc-dev am: 0700d79feb am: ebd33b28a3
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/15152137

Change-Id: Ia68bf040aa3b1876f60e085e07b33c28e3e8c012
2021-07-01 09:56:37 +00:00
Carter Hsu
b22f307ccf audio: exclude the echo reference device in capture position test
Bug: 192307382
Test:
VtsHalAudioV7_0TargetTest --gtest_filter=*PcmOnlyConfigInputStreamTest*
Signed-off-by: Carter Hsu <carterhsu@google.com>
Change-Id: I4e38e093bc3be7ee54c0c7cce4d1181e260a23bb
2021-06-30 06:55:24 +00:00
Mikhail Naganov
9a88b5b110 audio: Ignore SIGPIPE in the default audio HAL wrapper
It could happen that a service process receives a SIGPIPE
while providing a dump due unexpected pipe closure on
the other side. This should not lead to a service
termination. Ignoring SIGPIPE is a normal practice for
system services.

Bug: 191123848
Test: adb shell kill -s 13 <pid-of-audio-hal>
Change-Id: I9c1d170b76aa27203206e8fd2ce2fc3f5431baac
2021-06-17 19:55:16 +00:00
Andy Hung
1f90e1fbf8 audio: Add device constants for HDMI EARC
Implementation check by grep -E -r  "HDMI_ARC|HDMI_EARC" .

Test: atest AudioDeviceInfoTest
Bug: 131385398
Bug: 151781316
Merged-In: Idfe27b468a9f09770a31b6b58d83de77bebc6c80
Change-Id: Idfe27b468a9f09770a31b6b58d83de77bebc6c80
2021-04-29 18:49:43 -07:00
Andy Hung
67047d5a03 Merge changes from topics "24ch Audio HAL", "360RA HAL" am: 2092162bc3 am: a3bba5eb95 am: 24b2eac13a
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1677774

Change-Id: I88962b3c79f6a9c056bb0aefb54094d817dba109
2021-04-17 03:54:58 +00:00
Andy Hung
3cc6843bd5 audio: Add AUDIO_CHANNEL_OUT_22POINT2 constant
24 channel configuration for immersive audio

See new value in system/media/audio/audio-hal-enums.h.
Define the same enum to HALv7 and update getChannelCount().

Test: atest android.hardware.audio.common@7.0-util_tests
Bug: 185530406
Change-Id: I8dc5e6c504049908fef157b11ffa043ecaeacaf9
2021-04-15 18:22:42 -07:00
Kei Murayama
91ef183cf7 audio: Add AUDIO_CHANNEL_OUT_13POINT_360RA constant
13ch audio constant for 360 Reality Audio.

The enum value is added in system/media/audio/audio-hal-enums.h.
 - Define the same enum to HALv7.
 - Set 13 for the layout from getChannelCount().

Bug: 185100731
Test: Use the value on audio hal and build.
Test: Use the value on audio_policy_configuration.xml and build.
Test: atest android.hardware.audio.common@7.0-util_tests
Change-Id: Ifa37f9be96a94c623e5d4164774c39d05efbbb8b
2021-04-15 17:49:25 -07:00
Andy Hung
4da4945039 audio: Add device constants for HDMI EARC
Implementation check by grep -E -r  "HDMI_ARC|HDMI_EARC" .

Test: atest AudioDeviceInfoTest
Bug: 131385398
Bug: 151781316
Change-Id: Idfe27b468a9f09770a31b6b58d83de77bebc6c80
2021-04-08 21:02:25 -07:00
jiabin
574a86fa36 Add AudioTransport to replace AudioProfile in AudioPort.
An AudioTransport contains AudioProfile or hardware descriptor to
describe the audio capabilities for an AudioPort and the encapsulation
type to represent the encapsualtion format that must be used when
sending the audio data with the format associated the AudioTransport to
Android.

The hardware descriptor will be used when the format is not recognized
by the platform.

Currently, the short audio descriptor is added as one of the hardware
descriptors. Short audio descriptor is reported from EDID for HDMI.

Bug: 131736540
Bug: 178619392
Test: atest android.hardware.audio.common@7.0-util_tests
Test: atest VtsHalAudioV7_0TargetTest
Change-Id: Ic5ed9ff9b694511fdd7e90cdcda2777bdfa74f65
2021-03-23 17:22:38 -07:00
Treehugger Robot
bbc243fd44 Merge "audio: Add VTS tests for reads and writes" 2021-03-22 08:40:25 +00:00
Mikhail Naganov
5a78d9c221 audio: Add VTS tests for reads and writes
Tests verify actual reading / writing from input and output
streams and the capture / presentation position reporting.
Tests use audio policy manager configuration.

Bug: 161253754
Test: atest VtsHalAudioV7_0TargetTest
Change-Id: I408f7ee8df8671b7496040fe5ddd8a380672c21d
2021-03-19 13:33:26 -07:00