Commit Graph

1320 Commits

Author SHA1 Message Date
Mikhail Naganov
41b467bf5a audio: Remove InputStreamTest#getCapturePosition test am: f38d908d43
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2457548

Change-Id: I5f2cfa9afb5894b4110794b931f95f956e056c56
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-02-25 02:39:36 +00:00
Mikhail Naganov
f38d908d43 audio: Remove InputStreamTest#getCapturePosition test
The test was created based on assumptions and the current
HAL behavior. There is no actual requirement in the HIDL
interface for a stream to have a zero capture position
prior to start. In fact, some streams may be created by
the HAL "pre-loaded" with data if audio has already been
captured by the DSP and needs to be passed to the framework.

Bug: 270478574
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Ied6a71b73bff403365dd85fe6a212cfa4a5b284d
(cherry picked from commit afe90852d4)
2023-02-24 20:58:42 +00:00
Mikhail Naganov
b7e3b73036 audio VTS: Use the right device type in PcmOnlyConfigInputStreamTest am: 6de19308ab
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2367469

Change-Id: I29438dd0a094d52305d4466367400cd4d5e03b46
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-01-25 18:45:07 +00:00
Mikhail Naganov
ea87c8a518 audio VTS: Use 'IN_DEFAULT' device type for telephony am: 715b8ec2c5
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2322475

Change-Id: I547417d56c07c267e328d9ac0483aafbb1801788
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-01-25 18:43:26 +00:00
Mikhail Naganov
6de19308ab audio VTS: Use the right device type in PcmOnlyConfigInputStreamTest
The fix in https://r.android.com/2322475 modifies the device
address, which becomes 'IN_DEFAULT' for the telephony case.
As a result, tests that verify capture position were not
skipped, and they do fail on certain platforms when there is
no active telephone call. The fix is to use the initial device
type which was passed to the test as a parameter, not the adjusted
one.

Bug: 263305254
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Ied7134a1bd97e70dcc2400e0827810f9d71a6438
(cherry picked from commit 7029707e34)
2022-12-22 03:39:18 +00:00
Samip Garg
fe5e2ec823 Snap tm-dev to android13-tests-dev
Bug:259849956

Merge ab/9299233

Merged-In: I33a86ec62662ba4738c70c15b77ece0135da7d29
Change-Id: Ib7c38d7cefaed90da0caf0a970568149531b0cbe
2022-12-08 18:08:11 +00:00
Mikhail Naganov
715b8ec2c5 audio VTS: Use 'IN_DEFAULT' device type for telephony
This undoes the change which had happened unintentionally in
https://cs.android.com/android/_/android/platform/hardware/ \
interfaces/+/1e703f182e2fcbb9123bf661d81d22a04d0e1f8d

The device type passed to 'openInputStream' for telephony
devices should be 'AUDIO_DEVICE_IN_DEFAULT'

Bug: 259636577
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Ic8f4367961346b87087c885a3cdaccab3c1407c9
(cherry picked from commit d72b42d769)
2022-11-30 17:15:34 +00:00
Mikhail Naganov
5f5827a171 audio: Fix HAL reply handling in CompressedOffloadOutputStreamTest
Increase data position based on the HAL consumption of data,
on the production by the test.

Bug: 254806348
Test: atest VtsHalAudioV7_1TargetTest:CompressedOffloadOutputStream/CompressedOffloadOutputStreamTest
Change-Id: I33a86ec62662ba4738c70c15b77ece0135da7d29
(cherry picked from commit bae409f6c6)
2022-11-09 19:36:58 +00:00
Mikhail Naganov
0919b1abcd Sync audio_policy_engine_configuration.xsd with the SDK am: 7ac8751b9f
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2225420

Change-Id: Id136e4b17cb083dd13aa67ed4d6e25dd3a4b3877
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-09-23 00:01:25 +00:00
Mikhail Naganov
7ac8751b9f Sync audio_policy_engine_configuration.xsd with the SDK
The audio_policy_engine_configuration.xsd schema was missing
four values for the usage enum. This was causing the VTS
test to fail. These usages must be specified in the audio
policy engine configuration file, otherwise a GTS test fails.

Bug: 245303963
Bug: 246231268
Bug: 246901091
Test: atest VtsHalAudioPolicyV1_0TargetTest
Change-Id: I0161ddb33e52cbca9b425c0cbb4f32f320c43af4
(cherry picked from commit 1cbe492d59)
Merged-In: I0161ddb33e52cbca9b425c0cbb4f32f320c43af4
2022-09-21 22:02:16 +00:00
TreeHugger Robot
5c5c78aa51 Merge changes I26fd4fd2,Iaadf6e9b,I7d42f8a7,I0482376e into stage-aosp-tm-ts-dev am: 744c329227
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19345935

Change-Id: I2b54fab89ae38c8060fbec12c080304830a467fc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 23:21:35 +00:00
Mikhail Naganov
b9b5652fcc audio VTS: CompressedOffloadOutputStream to check the vendor API level am: 3f2e330990
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19340462

Change-Id: I85785803514d775f765e1ae4217a17591d7e4fb7
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 23:21:34 +00:00
Mikhail Naganov
96ddc8f20f audio VTS: add CompressedOffloadOutputStream test am: 56f1666feb
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19345352

Change-Id: Id24534dd0c3c977e1b775229734bcadb11a42ad5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 23:21:32 +00:00
Mikhail Naganov
a4c937fe91 audio VTS: Refactor test parameter generation for I/O streams am: 1e703f182e
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19340459

Change-Id: Iac28cf5830ddb01b3dc78d696c10d80bbd2d85c0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-08-02 23:21:30 +00:00
Mikhail Naganov
3b167a63b2 audio VTS: Update CompressedOffloadOutputStream implementation
Do not rely on blocking behavior of 'IStreamOut.write',
instead use stream callbacks. Measure the time between
write start and drain complete. This makes the test
working reliably across different chipsets.

Bug: 219767875
Test: atest VtsHalAudioV7_0TargetTest:CompressedOffloadOutputStream/CompressedOffloadOutputStreamTest
Test: atest VtsHalAudioV7_1TargetTest:CompressedOffloadOutputStream/CompressedOffloadOutputStreamTest
Change-Id: I26fd4fd26914ed2a0b3273f4ae5512a87f9cca2c
Merged-In: I26fd4fd26914ed2a0b3273f4ae5512a87f9cca2c
(cherry picked from commit a0a5d4a9f6)
2022-07-19 19:59:02 +00:00
Mikhail Naganov
3f2e330990 audio VTS: CompressedOffloadOutputStream to check the vendor API level
Update CompressedOffloadOutputStream to fail the test if
compressed offload mix port does not support gapless offload
for a new device launching on T+.

Bug: 219767875
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Iaadf6e9b9bb7340ccaf5bc26c45fda9654190510
Merged-In: Iaadf6e9b9bb7340ccaf5bc26c45fda9654190510
(cherry picked from commit 1bc0dc4ceb)
2022-07-19 19:58:06 +00:00
Mikhail Naganov
56f1666feb audio VTS: add CompressedOffloadOutputStream test
CompressedOffloadOutputStreamTest#Mp3FormatGaplessOffload verifies
that gapless offload is supported by compressed offload
mix ports.

Bug: 219767875
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: I7d42f8a714da2923b8775445ba301938ca90b885
Merged-In: I7d42f8a714da2923b8775445ba301938ca90b885
(cherry picked from commit 158a2ddb2f)
2022-07-19 19:56:59 +00:00
Mikhail Naganov
1e703f182e audio VTS: Refactor test parameter generation for I/O streams
Two changes that are necessary to test offloaded output:

1. Pass all mix port flags specified in the config to HAL when
   opening an output stream. Previously the generator was
   omitting the 'NON_BLOCKING' flag, however it is necessary
   for offloaded output to work. This also now passes
   the 'GAPLESS_OFFLOAD' flag to the stream opening call site.

2. Provide the DeviceAddress of the attached source/sink
   device to tests that use mix ports. Some tests were looking
   up the device address anyway. Also, HAL implementations
   seem to prefer to have the actual output device instead
   of 'DEFAULT' when opening offload streams.

Bug: 219767875
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Test: atest HalAudioV7_0GeneratorTest
Change-Id: I0482376ecc7d6964f45f508a80716ffab18044b4
Merged-In: I0482376ecc7d6964f45f508a80716ffab18044b4
(cherry picked from commit 713d2c5590)
2022-07-19 19:55:37 +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
Mikhail Naganov
ceae2a604e Update VtsHalAudioPolicyV1_0TargetTest to match XML changes
There was a proposal for a backward-compatible XML schema change
(https://android-review.googlesource.com/q/I1bf31c6bf6c57c9b79f0d5751601aa77780f1f80)
which had a mistake. Express the change correctly to match
the implementation.

Bug: 231929160
Test: atest VtsHalAudioPolicyV1_0TargetTest
Change-Id: Id581e290740a3c00ba3719a339c9bc47d730f35c
(cherry picked from commit 356bb458dc)
Merged-In: Id581e290740a3c00ba3719a339c9bc47d730f35c
2022-05-19 16:48:47 +00:00
Mikhail Naganov
afff851110 Update VtsHalAudioPolicyV1_0TargetTest to match XML changes
There was a proposal for a backward-compatible XML schema change
(https://android-review.googlesource.com/q/I1bf31c6bf6c57c9b79f0d5751601aa77780f1f80)
which had a mistake. Express the change correctly to match
the implementation.

Bug: 231929160
Test: atest VtsHalAudioPolicyV1_0TargetTest
Change-Id: Id581e290740a3c00ba3719a339c9bc47d730f35c
Merged-In: Id581e290740a3c00ba3719a339c9bc47d730f35c
(cherry picked from commit e01186e117)
2022-05-16 23:56:58 +00:00
Andy Hung
dc48405431 Merge "Effect: benchmark the effect process" into tm-dev 2022-05-06 19:14:19 +00:00
Mikhail Naganov
abc4ffe565 audio VTS: Fix handling of ULTRASOUND sources
When opening a stream on an ultrasound input
(AUDIO_INPUT_FLAG_ULTRASOUND), the source type
AUDIO_SOURCE_ULTRASOUND must be used.

Bug: 231275185
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Ib1fb5b8218eb0c52edf31789fa937c0a8b6c5082
Merged-In: Ib1fb5b8218eb0c52edf31789fa937c0a8b6c5082
(cherry picked from commit 1ce9d5488a)
2022-05-05 16:33:12 +00:00
Andy Hung
502f9d017a Effect: benchmark the effect process
Required for Spatializer tuning.

Test: adb shell dumpsys media.audio_flinger
Bug: 228862341
Change-Id: I59f3b35c9cdd1e45e9afc79cbf9aac30a5decd67
2022-05-04 13:14:55 -07:00
Mikhail Naganov
debaac6c18 VTSHalAudio: Increase test timeout for V6, V7.x to 10 minutes am: 3664aad2ac
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2072110

Change-Id: Ib8b4292b5d6238c08df39559f07ecf8c7aea9d20
Ignore-AOSP-First: this is an automerge
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-25 08:21:17 +00:00
Mikhail Naganov
83cf51eb33 VTSHalAudio: Increase test timeout for V6, V7.x to 10 minutes
TV devices can list a lot of configurations and have low
performing CPUs which causes the test to run for a significant
amount of time. From b/229824670 it seems that 10 minutes
should be enough.

Bug: 229824670
Test: atest VtsHalAudioV6_0TargetTest
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Id7fa8eaa98bf2437fd1f676b9e5a7290df260fbd
(cherry picked from commit 0b9b03eb71)
Merged-In: Id7fa8eaa98bf2437fd1f676b9e5a7290df260fbd
2022-04-23 01:11:16 +00:00
Mikhail Naganov
3664aad2ac VTSHalAudio: Increase test timeout for V6, V7.x to 10 minutes
TV devices can list a lot of configurations and have low
performing CPUs which causes the test to run for a significant
amount of time. From b/229824670 it seems that 10 minutes
should be enough.

Bug: 229824670
Test: atest VtsHalAudioV6_0TargetTest
Test: atest VtsHalAudioV7_0TargetTest
Change-Id: Id7fa8eaa98bf2437fd1f676b9e5a7290df260fbd
(cherry picked from commit 0b9b03eb71)
2022-04-22 01:04:23 +00:00
Jiyong Park
0c7505f89d V1 is the latest version of android.media.audio.common.types
As part of the AIDL API freeze for TM, the V1 of
android.media.autio.common.types was frozen. As a result,
unversioned reference to the interface now refers to the V2
of the interface, yet to be frozen. This causes ODR violation
where V1 and V2 of the interfaces are both used in the
platform.

To fix that, replaced the unversioned reference explicitly
with the reference to V1.
Bug: 225941299
Test: m
Change-Id: I8c57c730bebfe88b182d42a4bb8acea32ac4aee8
2022-04-18 18:34:32 +00:00
Mikhail Naganov
d6191e1899 audio: Require exact implementation version match am: 7c92256c1a am: 541eb4099c am: 5571021c52
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2058922

Change-Id: I230abccbbd62b6dbb3cafead89ddfea5ff050154
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-12 17:20:10 +00:00
Mikhail Naganov
7c92256c1a audio: Require exact implementation version match
Align the behavior of minor version mismatch with the behavior
of major version mismatch. For example, trying to run VTS test
intended for V7.0 on a device with V7.1 yields no results,
similar to what happens when running a V6.0 test on V7.0 device.
This is done to avoid test failures when the device uses
features added by V7.1 in the APM XML config.

Bug: 227150535
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: I8ad6595a221f0bc9aedea057f27a75c172954da5
2022-04-12 00:06:09 +00:00
Jiyong Park
703e97920e Freeze AIDL APIs for TM
Bug: 225941299
Test: m
Change-Id: Ie41cc0797710f813f92c65c387f247c7806d8394
2022-03-31 12:01:39 +09:00
Mikhail Naganov
c39d8bffb9 Merge "audio: Add OWNERS to aidl folder" am: f325a1756c am: 508ef6caa5 am: c39ae7b60b
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2025328

Change-Id: Idaf88f9cd251aaa053db4fa88b389518d94530bf
2022-03-15 01:40:45 +00:00
Mikhail Naganov
b62f1ebb19 audio: Add OWNERS to aidl folder
Bug: 205884982
Test: N/A
Change-Id: I9f49d2a9c670c7bbf45dd00d262eff6d445679ea
2022-03-14 22:10:48 +00: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
e6214078ba audio VTS: Fix HAL device management
Straighten out logic in DeviceManager for proper handling
of IPrimaryDevice and IDevice instances across all supported
HAL versions.

This fixes a recently introduced bug which was causing
the same HAL device to be opened twice in a row, and then closed
twice.

Bug: 218610286
Test: atest VtsHalAudioV7_0TargetTest
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: I415cbadae9d325ac63160e49e5e638906c8c63fd
(cherry picked from commit 285c0a041c)
Merged-In: I415cbadae9d325ac63160e49e5e638906c8c63fd
2022-02-12 00:35:19 +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
Carter Hsu
ff62b259f8 audio: add Ultrasound materials to 7.1
Bug: 200256985
Test: build pass
Signed-off-by: Carter Hsu <carterhsu@google.com>
Change-Id: I50ba1272c0b29e482532010f1aca0b6ec83e925c
(cherry picked from commit bb2fe3f4d5)
Merged-In: I50ba1272c0b29e482532010f1aca0b6ec83e925c
2022-02-11 23:16:53 +00:00
Mikhail Naganov
4a016add95 audio: Remove IStreamIn@7.1
This has turned out to be an empty interface. By removing
it we save about 100 kB in the interface code.

Bug: 217752112
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: I2522653600a254ddcf2c4eac8bed1df69ac11d3d
(cherry picked from commit 893ea21681)
Merged-In: I2522653600a254ddcf2c4eac8bed1df69ac11d3d
2022-02-10 17:45:31 +00:00
Mikhail Naganov
9307992466 audio: Add IDevice.setConnectedState_7_1 method
This is an updated version of IDevice.setConnectedState which
accepts a full AudioPort so that additional data like extra
audio descriptors can be passed to the audio HAL.

Bug: 211601178
Test: atest VtsHalAudioV7_1TargetTest
Change-Id: Id746caa32122dabfb83feb5b515bed7717bcb67c
(cherry picked from commit 533f78f411)
Merged-In: Id746caa32122dabfb83feb5b515bed7717bcb67c
2022-02-10 17:45:21 +00:00
Mikhail Naganov
22dc9b9aa4 audio: Add recommended mute duration attribute to APM XSD
Add 'recommendedMuteDurationMs' optional attribute to 'mixPort'
element. This attribute specifies customized mute duration while
switching device's audio path to avoid truncated sound at the
beginning.

The framework is already aware of this attribute, only need
to allow it in the XSD.

Bug: 183344508
Bug: 197823000
Test: m
CTS-Coverage-bug: 215647214
Change-Id: I3be36009d1b5db218c846efe96f078e858283992
(cherry picked from commit b6800fc715)
Merged-In: I3be36009d1b5db218c846efe96f078e858283992
2022-02-10 17:45:13 +00:00
Andy Hung
87edc66e1f Audio: Add memory leak checking for HAL
$ adb shell setprop libc.debug.malloc.program android.hardware.audio.service
$ adb shell setprop libc.debug.malloc.options backtrace=8
$ adb shell setenforce 0
$ adb shell pkill audioserver
$ adb shell dumpsys media.audio_flinger

Test: Check the audio flinger dumpsys as above.
Bug: 186054996
Bug: 187462632
Change-Id: I2e8db14b816cc4cd7e1420c538505bf71fa58c97
(cherry picked from commit 8f836b9499)
Merged-In: I2e8db14b816cc4cd7e1420c538505bf71fa58c97
2022-02-10 17:44:56 +00:00