Commit Graph

47321 Commits

Author SHA1 Message Date
Mikhail Naganov
00a7a24e0a Merge "audio: Allow Module subclasses to customize Configuration" into main 2023-07-14 23:46:52 +00:00
Treehugger Robot
00e273d023 Merge "compatibility_matrices: Only allow core HALs for system FCMs." into main 2023-07-14 21:21:23 +00:00
Peter Yoon
918a6a5ce9 audio: Allow Module subclasses to customize Configuration
When a vendor HAL reuses libaudioserviceexampleimpl,
a subclass of Module cannot change Configuration.

This change adds virtual method Module::initializeConfig(),
then a vendor HAL can override it to load custom Configuration.

Test: atest VtsHalAudioCoreTargetTest
Change-Id: I63fa8d70f3c4e13c8938070ee5431ebefd36bb58
2023-07-15 05:50:27 +09:00
Mikhail Naganov
f0ad731bb9 Merge changes I392933f8,I5e4da0c3,I2134b15e into main
* changes:
  audio: Add optional 'DriverInterface::getPosition' method.
  audio: Create ModulePrimary and ModuleStub
  audio: Move tinyALSA-specific code to Module/StreamAlsa
2023-07-13 20:10:10 +00:00
Yifan Hong
7066d3369a Merge "compatibility_matrices: add vintf_compatibility_matrix.core_hals." into main 2023-07-13 19:29:48 +00:00
Mikhail Naganov
704aec434e audio: Add optional 'DriverInterface::getPosition' method.
This is a method which can be optionally implemented
by a stream in case it can provide more exact position,
for example by taking into account data in intermediate
buffers.

Implemented this method for StreamAlsa and StreamRemoteSubmix.

Bug: 264712385
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I392933f8f6b22d784726925199db00dcb0313648
2023-07-13 11:25:47 -07:00
Mikhail Naganov
521fc49fba audio: Create ModulePrimary and ModuleStub
Make 'Module' more abstract by moving stream creation
methods to more concrete 'ModulePrimary' and 'ModuleStub'.
'ModulePrimary' is now closer to the CF primary module:
it was stripped off USB devices from its configuration,
these got moved to 'ModuleUsb', and got rid of BT A2DP
and LE interfaces, these will be on 'ModuleBluetooth'.
Note that 'ModulePrimary' still uses stub streams, this
will be changed in subsequent patches.

'ModuleStub' is what 'Module' used to be, just a module
for improving test coverage. It includes simulation of
offload streams and dummy BT objects.

Bug: 264712385
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I5e4da0c32c00d65688f2eda78b2c79594e4e4671
2023-07-13 11:25:23 -07:00
Mikhail Naganov
c337a8799b audio: Move tinyALSA-specific code to Module/StreamAlsa
Extract code interacting with tinyALSA which is not
specific to USB into "abstract" module and stream
implementations ModuleAlsa and StreamAlsa. Also, move
utility code which does not need module or stream
context into Utils.

This facilitates implementation of the CF core HAL which
also uses tinyALSA, allowing to share common code.

Bug: 264712385
Test: atest VtsHalAudioCoreTargetTest

Change-Id: I2134b15e970c78e8a48b254e15199b8207a8ab34
2023-07-13 11:24:52 -07:00
David Drysdale
332dd07dec [automerger skipped] Allow extra ID attestation error codes am: 3f6ab601b9 -s ours
am skip reason: Merged-In I6ea5bd7ee19b3b172330117bfde1b16745debba7 with SHA-1 c68dc93788 is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2646973

Change-Id: I490eda48828baaaf006e5cf16add9a9f5bbd2e58
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-13 06:48:01 +00:00
Mikhail Naganov
01fa9e8874 Merge "vts: getParameters only if parameters are supported" into main 2023-07-12 15:27:31 +00:00
David Drysdale
3f6ab601b9 Allow extra ID attestation error codes
When deliberately testing invalid ID attestation, use the helper
function (which checks the error return code is correct) in one more
place.

Test: VtsAidlKeyMintTargetTest
Bug: 286733800
Change-Id: I6ea5bd7ee19b3b172330117bfde1b16745debba7
(cherry-picked from commit c68dc93788)
Merged-In: I6ea5bd7ee19b3b172330117bfde1b16745debba7
2023-07-12 13:58:41 +00:00
liuxiangjun
e1cf296b9c [automerger skipped] Return INVALID_ ARGUMENTS is the expected result am: 7ddd478150 -s ours
am skip reason: Merged-In I873d51e089b27aa0cc0dc9f5f25fd8ffaa4d8f40 with SHA-1 eddc6dc0ad is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2648141

Change-Id: I7a01a50189e325e0d03d0c782fbd5c947e65c0dd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-12 02:38:14 +00:00
Treehugger Robot
7ebd917745 Merge "Fix audio/aidl/TEST_MAPPING" into main 2023-07-12 00:47:46 +00:00
Myles Watson
e023a39508 Merge "BluetoothAudio: Statically link HAL dependencies" into main 2023-07-12 00:20:53 +00:00
Mikhail Naganov
8460fa1ff5 Fix audio/aidl/TEST_MAPPING
A non-existent test module VtsHalAudioCoreConfigTargetTest
was added by accident. This is a test class, not a module.

Bug: 290793450
Test: atest com.android.tradefed.presubmit.TestMappingsValidation
Change-Id: Icc40ec7fb956dcb85342266540ce8f17240da36b
2023-07-11 16:56:59 -07:00
Myles Watson
44628f38d2 BluetoothAudio: Statically link HAL dependencies
Bug: 290666670
Bug: 289857524
Bug: 284091286
Bug: 289489060
Test: mma -j32
Change-Id: I2b3c32b133e208ec2cfb1b244ccb24ad249f22df
2023-07-11 16:08:27 -07:00
Zhanglong Xia
2f5e431e3f Merge "fix the Thread Network fuzz testing error" into main 2023-07-11 08:10:50 +00:00
Zhanglong Xia
086e138474 Merge "change the Thread Network HAL api from 'reset' to 'hardwareReset'" into main 2023-07-11 02:46:43 +00:00
Yifan Hong
42d17688d4 compatibility_matrices: Only allow core HALs for system FCMs.
For system FCMs (except device-specific
system FCM), only allow android.* and
mapper HALs.

Test: TH
Bug: 290408770
Change-Id: I4c3908911440a3c154200a6c7b338f92bd724a68
2023-07-10 17:48:37 -07:00
Yifan Hong
9fb9ff77b1 compatibility_matrices: add vintf_compatibility_matrix.core_hals.
Add core_hals attribute to the vintf_compatibility_matrix
rule. Its value is passed to assemble_vintf directly.

Test: TH
Bug: 290408770
Change-Id: Ie5e3363f0039f032033cbc2889b1bbbb0a5a56a7
2023-07-10 17:48:36 -07:00
Yifan Hong
9d0b975f6c Merge "compatibility_matrices: Add script to create the next." into main 2023-07-10 21:14:34 +00:00
Yifan Hong
ace13dee65 compatibility_matrices: Add script to create the next.
Add a `bump.py` script that does the following:
- Create a commit in kernel/configs with the new versions
- Copy the latest compatibility matrix to a new compatibility matrix
- Fix Android.bp and Android.mk

Prerequisite:
- libvintf/Level.h must contain the mapping for the next release.

Test: bump.py 9 10
Bug: 279809082

Change-Id: I4520a128b39f66a03f22d24218348f5fff92e9cd
2023-07-10 12:37:27 -07:00
Jaideep Sharma
b985903e16 vts: getParameters only if parameters are supported
1) Validate specific parameters before open call,
   send only if parameters are supported.
2) GetParameters only if parameters are in range.

Bug: 288510312
Test: run vts VtsHalNSTargetTest, VtsHalAECTargetTest

Change-Id: Idb20d819b3eb8a4ba56b4d50311c1aa7659f3616
2023-07-10 13:13:42 +05:30
Bao Do
00dede017f Add a config with test skipping for SDK < 33
Test: atest VtsHalBluetoothAudioTargetTest
Bug: 288598199
Change-Id: I563c8d50b186f2da2cf077dc3631808f8c2a9eee
2023-07-10 07:43:09 +00:00
Treehugger Robot
af52e698da Merge "health: Check return value of LinkedCallback::Make." into main 2023-07-07 20:54:25 +00:00
Treehugger Robot
d0cb2e73b2 Merge "Fix flaky recurrent timer test." into main 2023-07-07 20:32:25 +00:00
Yu Shan
bdba2b578d Fix flaky recurrent timer test.
Do not rely on sleep in tests, but wait for the events to happen
before timeout. Set the timeout to be large enough (5s) so that the
tests are more stable.

Test: atest RecurrentTimerTest
Bug: 289759453
Change-Id: Iff271ca440426871ed3a798bab50b9532f9256f0
Merged-In: Iff271ca440426871ed3a798bab50b9532f9256f0
(cherry picked from commit 76d7fbf6a1)
2023-07-07 20:30:43 +00:00
Treehugger Robot
8328cbb343 Merge "Clarify null-termination of name field" into main 2023-07-07 18:35:22 +00:00
John Reck
735206b1a5 Clarify null-termination of name field
Test: make
Change-Id: I22e7c20074fe49bd533fc16c88a979447362d3f2
2023-07-07 12:11:00 -04:00
Mikhail Naganov
1b5dab3553 Merge "audio: Fix default surround sound config" into main 2023-07-07 15:42:07 +00:00
Zhanglong Xia
a6165dcccf change the Thread Network HAL api from 'reset' to 'hardwareReset'
This CL changes the API from 'reset' to 'hardwareReset' to make the
the definition of the API clearer. This CL also optimizes the Thread
Network HAL default implementation.

Bug: 289867661
Test: Run Thread stack on cuttlefish.
Change-Id: Id742453d9d7a0d369ac8f16905efdacfcfba1dbc
2023-07-07 11:22:57 +08:00
Yifan Hong
70197263f0 health: Check return value of LinkedCallback::Make.
If LinkedCallback::Make returns nullptr, do not put it
in Health::callback_. Otherwise, OnHealthInfoChanged
crashes later because the linked callback objects are
not null checked before accessing.

Test: android.hardware.health-service.aidl_fuzzer (with
  a special corpus)
Fixes: 289599278
Change-Id: I8bad41dbcfbefeb54744059baffd4eef1ae7ec42
2023-07-06 17:46:25 -07:00
Treehugger Robot
099240ae66 Merge "Allow face HAL to be updated via apex in U" into main 2023-07-06 22:06:52 +00:00
Mikhail Naganov
724b24f895 audio: Fix default surround sound config
Ensure that all formats returned by
AudioPolicyConfigXmlConverter::getDefaultSurroundSoundConfig
can be converted into legacy values.

Bug: 290116634
Test: atest audio_policy_config_xml_converter_tests
Change-Id: I3a46ea5ee4805f719c8977064c9d8d681a75cff2
2023-07-06 13:51:37 -07:00
Nataniel Borges
d74d81bf6e Merge changes from topic "revert-2649121-cm_vintf_workaround-PMVOGMKMBW"
* changes:
  Revert "Only allow cuttlefish to use FCM 9 HALs"
  Revert "Allow fingerprint HAL to be updated via apex in U"
2023-07-06 11:41:24 +00:00
Nataniel Borges
7202c60c3a Revert "Only allow cuttlefish to use FCM 9 HALs"
Revert submission 2649121-cm_vintf_workaround

Reason for revert: b/290154726

Reverted changes: /q/submissionid:2649121-cm_vintf_workaround

Change-Id: Ied04c3892a4a00ef75f92e1f89ba38cada2f8293
2023-07-06 10:08:24 +00:00
Nataniel Borges
e42c161bcd Revert "Allow fingerprint HAL to be updated via apex in U"
Revert submission 2649121-cm_vintf_workaround

Reason for revert: b/290154726

Reverted changes: /q/submissionid:2649121-cm_vintf_workaround

Change-Id: I39d65f3a675a3616401411076a4eade403917707
2023-07-06 10:08:24 +00:00
David Drysdale
c68dc93788 Allow extra ID attestation error codes
When deliberately testing invalid ID attestation, use the helper
function (which checks the error return code is correct) in one more
place.

Test: VtsAidlKeyMintTargetTest
Bug: 286733800
Change-Id: I6ea5bd7ee19b3b172330117bfde1b16745debba7
2023-07-06 10:23:55 +01:00
Jooyung Han
6942901f5c Allow face HAL to be updated via apex in U
Bug: 290142180
Test: m check-vintf-all (with -next- pixel targets)
Merged-In: Ia3b15f669219a0941498b90a76b42d5f2f5ac80b
Change-Id: Ia3b15f669219a0941498b90a76b42d5f2f5ac80b
(cherry picked from commit dcd2ae7c29)
2023-07-06 17:13:41 +09:00
Zhanglong Xia
7f7e8647fa fix the Thread Network fuzz testing error
The current fuzz testing comunicates with the Thread radio chip
simulation program `ot-rcp`. The 'ot-rcp' is not installed by all
devices, which causes the fuzz testing program is unable to find
the program '/vendor/bin/ot-rcp'.

This commit enables the HAL to talk to the '/dev/null' to avoid
'/vendor/bin/ot-rcp' not being found.

Bug: 289627270
Test: Run the fuzz test on cuttlefish
Change-Id: If410d7d75abe05c7c2d2c82fa0450e925b9a48bb
2023-07-06 13:45:23 +08:00
liuxiangjun
7ddd478150 Return INVALID_ ARGUMENTS is the expected result
For devices not in LTE service, the vts test returns INVALID_ ARGUMENTS is an expected result

Bug:289756066

Test:
VtsHalRadioV1_5TargetTest  PerInstance/RadioHidlTest_v1_5#startNetworkScan/0_slot1
VtsHalRadioV1_5TargetTest  PerInstance/RadioHidlTest_v1_5#startNetworkScan/1_slot2

Change-Id: I873d51e089b27aa0cc0dc9f5f25fd8ffaa4d8f40
Signed-off-by: liuxiangjun <liuxiangjun3@xiaomi.com>
Merged-In: I873d51e089b27aa0cc0dc9f5f25fd8ffaa4d8f40
2023-07-06 05:16:22 +00:00
Treehugger Robot
97af8becd7 Merge "Return INVALID_ ARGUMENTS is the expected result" 2023-07-06 05:15:52 +00:00
liuxiangjun
eddc6dc0ad Return INVALID_ ARGUMENTS is the expected result
For devices not in LTE service, the vts test returns INVALID_ ARGUMENTS is an expected result

Bug:289756066

Test:
VtsHalRadioV1_5TargetTest  PerInstance/RadioHidlTest_v1_5#startNetworkScan/0_slot1
VtsHalRadioV1_5TargetTest  PerInstance/RadioHidlTest_v1_5#startNetworkScan/1_slot2

Change-Id: I873d51e089b27aa0cc0dc9f5f25fd8ffaa4d8f40
Signed-off-by: liuxiangjun <liuxiangjun3@xiaomi.com>
2023-07-06 02:10:44 +00:00
Treehugger Robot
9bf3a09289 [automerger skipped] Merge "[RESTRICT AUTOMERGE] Allow extra error code in device ID attestation" into android13-tests-dev am: b68968f638 -s ours
am skip reason: Merged-In Ic01c53cbe79f55c2d403a66acbfd04029395c287 with SHA-1 f42238c99f is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2646738

Change-Id: I62e1b282ae525a06fce08476d84b1b94f9677a42
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-06 00:57:24 +00:00
David Drysdale
914418c2d7 [automerger skipped] [RESTRICT AUTOMERGE] Allow extra error code in device ID attestation am: b18c757eda -s ours
am skip reason: Merged-In Ic01c53cbe79f55c2d403a66acbfd04029395c287 with SHA-1 f42238c99f is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2646738

Change-Id: I67be597bc289cb423fbc0e81016109804218ef23
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-06 00:57:21 +00:00
Gabriel Biren
3a7d2f3649 [automerger skipped] Merge "Add a new utility class wifi_hidl_test_utils_1_6 for the Wifi VTS tests." into android13-tests-dev am: 73e10b765f -s ours
am skip reason: Merged-In I2571876149fc14c8de02e1cec9934dd052cada5c with SHA-1 a2482fde1a is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2618209

Change-Id: I5fdf1dfe7ffed73f84e76961ccb01963b8082277
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-06 00:56:38 +00:00
Gabriel Biren
7f9e1ab4fd [automerger skipped] Add a new utility class wifi_hidl_test_utils_1_6 am: eadd5160d8 -s ours
am skip reason: Merged-In I2571876149fc14c8de02e1cec9934dd052cada5c with SHA-1 a2482fde1a is already in history

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2618209

Change-Id: I544bd5f4537f7c122a8962fe32a0abeea35fe9b5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-06 00:56:35 +00:00
Treehugger Robot
b68968f638 Merge "[RESTRICT AUTOMERGE] Allow extra error code in device ID attestation" into android13-tests-dev 2023-07-06 00:16:46 +00:00
Gabriel Biren
73e10b765f Merge "Add a new utility class wifi_hidl_test_utils_1_6 for the Wifi VTS tests." into android13-tests-dev 2023-07-06 00:16:22 +00:00
Treehugger Robot
8c45f4ab87 Merge changes from topic "cm_vintf_workaround"
* changes:
  Allow fingerprint HAL to be updated via apex in U
  Only allow cuttlefish to use FCM 9 HALs
2023-07-05 21:33:49 +00:00