Commit Graph

47422 Commits

Author SHA1 Message Date
Yifan Hong
19d015a45e fcm_exclude: mark bluetooth.audio@1 as deprecated.
It never shows up in any matrices. Only bluetooth.audio@2
and beyond are accepted.

Test: TH
Bug: 255383566
Change-Id: I110b73b2ed610d86aa351216fe46d9f803f8c3cf
2023-08-08 13:32:19 -07:00
Yifan Hong
a3975a563f matrices: Add gnss.* to fcm_exclude.
They aren't top level interfaces.

Test: TH
Bug: 255383566
Change-Id: I8265f531880d1dcff1bf7edfd035a25f9e2a4d70
2023-08-08 13:32:12 -07:00
Yifan Hong
68ed69dd7c fcm_exclude: Aidl HALs contains versions.
ShouldCheckMissingAidlHalsInFcm now accepts arguments of
the format android.hardware.foo@1.

Test: TH
Bug: 255383566
Change-Id: I891f749190a8db8725ec1e05b190e73ab4468254
2023-08-08 13:32:11 -07:00
David Drysdale
955fb9e5fc Merge "KeyMint: use a smaller invalid IMEI value" into main 2023-08-08 10:16:23 +00:00
Treehugger Robot
ff1f1f3494 Merge "audio: Implement the major functionality of the primary CF HAL" into main 2023-08-08 07:56:05 +00:00
Treehugger Robot
41243dc213 Merge "audio: Ensure proper priority and scheduler for service threads" into main 2023-08-08 02:19:23 +00:00
Mikhail Naganov
4bf6899cc7 audio: Ensure proper priority and scheduler for service threads
Change audio worker threads priority to ..._URGENT_AUDIO to match
the coupled thread in the audio flinger.

Set SCHED_FIFO scheduler for FAST threads (also to match AF fast
mixer/capture threads). In order to enable that, grand SYS_NICE
capability to the HAL service process and provide "getTid"
function in the StreamWorker class. For testing, add a "FAST"
output to the "stub" module in the HAL configuration.

Bug: 286914845
Test: atest libaudioaidlcommon_test
Test: atest VtsHalAudioCoreTargetTest
Test: adb shell ps -A -T -o PID,TID,NI,PCY,PRI,RTPRIO,SCHED,CMD
      for the HAL service process during VTS test. For regular
      "reader"/"writer" threads should see 'NI 19, PRI 38',
      for FAST "writer" should see 'NI -19, PRI 43, RTPRIO 3, SCH 1'
Change-Id: Iab7e21ebc139ff11cf9b7f4a1645960db8dadd43
2023-08-07 18:15:19 -07:00
Treehugger Robot
203ca985ce Merge "Update version for audiocontrol" into main 2023-08-07 22:59:39 +00:00
Mikhail Naganov
cf824f65c8 audio: Implement the major functionality of the primary CF HAL
Core HAL changes:

1. Add StreamPrimary implemented via StreamAlsa.

2. Align the configuration with the HIDL HAL.

3. Fix position retrieval vs. standby call.

4. Fix sleeps in StreamAlsa.

VTS changes:

1. Use several bursts for stream I/O test scenarios that check
   observable position increase. This is because the position may
   not be available until a couple of transfers have been made.

2. Do not require position increase for the scenarios that do
   not make several bursts. As specified above, the position may
   not have been increased for the ALSA case. Whereas, using
   multiple bursts in all scenarios will increase test time, and
   make the state machine transitions graph more complicated.

3. Hook up the test config file to shut down audioserver during
   VTS tests, fix the test config file.

Bug: 286914845
Test: atest VtsHalAudioCoreTargetTest
Test: compare APM dumps for AIDL vs. HIDL
Change-Id: I85271564c664fa40008d60e82b32eaa66a99c68f
2023-08-07 13:38:50 -07:00
David Drysdale
0215cb3d3e KeyMint: use a smaller invalid IMEI value
The invalid value used for the second IMEI attestation test is
potentially wrong in two ways:
- It doesn't match the provisioned value.
- It's not a valid IMEI, not least because it is longer than 16 bytes.

Make the test value shorter so the second failure doesn't apply and
the test can reliably expect CANNOT_ATTEST_IDS.

Bug: 292959871
Test: VtsAidlKeyMintTargetTest
Change-Id: If8c6b9e08b48e6caf5c767578e1ac43964214619
2023-08-07 11:53:46 +01:00
kuanyuhuang
25b4819e08 BT: add LOW_LATENCY mode if low latency allowed
LatencyMode is not updatable after audio session started.
Currently, if low latency is allowed, audio session should have
LOW_LATENCY latency mode.
Create a workaround to add LOW_LATENCY when low_latency_allowed_ set to
ture at ReportLowLatencyModeAllowedChanged.

Bug: 291760415
Bug: 294498919
Test: play low latency audio with supported headset and check
LOW_LATENCY mode can be selected

Change-Id: Ia324f0a368e47ae8b8056c190d8d1f4a2e09ecec
2023-08-07 05:05:52 +00:00
Terry Guan
b324444c8a Update version for audiocontrol
Bug: 255369346
Bug: 255383566
Test: atest vts_treble_vintf_vendor_test
Change-Id: I17000be75963e511d2a56583be0f619a3dee66f1
Merged-In: I17000be75963e511d2a56583be0f619a3dee66f1
Merged-In: Ic42e51b616782a2763eb80e1cad5ca776cc079d4
2023-08-04 16:50:58 -07:00
Yifan Hong
966a4f13a5 matrices: automotive.audiocontrol in 7.xml has max version
Updates version from 1 to 1-2 to reflect the fact
that version 2 is released in Android 13.

Test: TH
Bug: 255383566
Change-Id: I290aefb51fcc54d5e5a02f8c7da5876e86f61cd9
2023-08-04 16:47:29 -07:00
Yifan Hong
23847d4411 Merge "fcm_exclude: split HIDL and AIDL predicate." into main 2023-08-04 23:16:13 +00:00
Treehugger Robot
e8d695d9b2 Merge "audio: Make renamings suggested by reviewers" into main 2023-08-04 15:46:13 +00:00
Treehugger Robot
5a15a1c838 Merge "Remove authsecret HIDL entry in compat matrix." into main 2023-08-03 22:12:23 +00:00
Mikhail Naganov
459b7331e9 audio: Make renamings suggested by reviewers
Rename DriverInterface::getPosition -> refinePosition. This reflects
the fact that the driver may provide more precise position, however
this is an optional operation.

Rename StreamIn/Out::mContext -> mContextInstance. This is
to emphasize that StreamIn/Out actually own the context and they
hold the real context instance, not just a reference/pointer
to it, like other classes involved in the inheritance chain.

Bug: 286914845
Test: atest VtsHalAudioCoreTargetTest
Change-Id: Id7159f9bf3ee020dc7cf594ec35f5d59d23d7e31
2023-08-03 10:31:12 -07:00
Mikhail Naganov
09d45c473e Merge "audio: Address comments from an internal review" into main 2023-08-03 15:58:56 +00:00
Yu Shan
21d7b02a9a [RESTRICT AUTOMERGE] Pass property set error to subscribed clients.
Pass the async property set error generated by VehicleHardware layer
to subscribed clients.

Test: atest DefaultVehicleHalTest
Bug: 286384730
Bug: 292001021
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:6fe26625db72da7760014d0c71019fb3e847e2d3)
Merged-In: Iadd92e1c0c741ad6450a0508fe9e6301bdfe66c5
Change-Id: Iadd92e1c0c741ad6450a0508fe9e6301bdfe66c5
2023-08-02 22:03:41 +00:00
Devin Moore
aa8b667844 Remove authsecret HIDL entry in compat matrix.
This interface has been converted to AIDL.

Test: TH
Bug: 218588089
Change-Id: I091ff4acb38c42821e99f785404e922d7b71ffa2
Merged-In: I091ff4acb38c42821e99f785404e922d7b71ffa2
2023-08-02 20:02:33 +00:00
Mikhail Naganov
0faf339425 audio: Address comments from an internal review
Bug: 286914845
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I2f636c77f67fdd8eeac70dd304848bf7f76db4e5
2023-08-02 12:24:47 -07:00
Treehugger Robot
0bc307a5dd Merge "Audio r_submix : Handle the usecase when no data is available to read." into main 2023-08-02 18:51:53 +00:00
Treehugger Robot
4bfa2e1e6d Merge changes from topic "bluetoothmodule" into main
* changes:
  bluetooth: Add AudioSession/Control methods for AIDL track metadata
  bluetooth: Fix dependency on android.hardware.audio.common
2023-08-02 17:41:07 +00:00
Treehugger Robot
169be3476d Merge changes from topic "bluetoothmodule" into main
* changes:
  aosp aidl bluetooth parameter support
  aosp aidl bluetooth audio hal implementation
2023-08-02 17:41:07 +00:00
Ram Mohan
18f0d5121a aosp aidl bluetooth parameter support
Bug: 228804498
Test: atest VtsHalAudioCoreTargetTest
Change-Id: If1820018d5a6750eed0d0b486e15fc7c717aa11c
2023-08-02 21:42:01 +05:30
Mikhail Naganov
b03b5c4a06 aosp aidl bluetooth audio hal implementation
Bug: 228804498
Test: atest VtsHalAudioCoreTargetTest
Change-Id: Id5fb60fe53ead9f5d2e6ecbb9988a23835cf2509
2023-08-02 21:42:01 +05:30
François Gaffie
acd4a677f0 Audio: add system usage to audio policy engine schemas
Bug: 293917986
Test: m

Change-Id: I49a8d3cfeb45eddc95ad6ab4a33b0adf0585cde2
Signed-off-by: François Gaffie <francois.gaffie@renault.com>
2023-08-02 10:47:00 +02:00
Shraddha Basantwani
675cce24d6 Audio r_submix : Handle the usecase when no data is available to read.
Bug: 290116295
Test: atest VtsHalAudioCoreTargetTest
Change-Id: Ifd6706d593f890dd8ae148523a37177774c8ffd4
2023-08-02 05:19:24 +00:00
Yifan Hong
32f40c34ef fcm_exclude: split HIDL and AIDL predicate.
AIDL is going to have a new format in fcm_exclude:
android.hardware.foo@1. This cannot be excluded
properly when mixing with HIDL, so split.

Test: TH
Bug: 255383566
Change-Id: I3df9517f12b62f5112df307528d5c3deab12cfa0
2023-08-01 16:05:40 -07:00
Mikhail Naganov
d5f0d13ef0 bluetooth: Add AudioSession/Control methods for AIDL track metadata
Add overloads for UpdateSink/SourceMetadata that
accept android.hardware.audio.common.Sink/SourceMetadata types.
Move include of hardware/audio.h to BluetoothAudioSession.cpp.
This allows to use this code from "pure AIDL" modules.

Bug: 228804498
Test: m
Change-Id: Ib0b8c6d1c7db9b846a508d6d4001f67feb2111c6
2023-08-01 13:38:47 -07:00
Ram Mohan
f6497dd78c bluetooth: Fix dependency on android.hardware.audio.common
Make android.hardware.bluetooth.audio-V3 and
VtsHalBluetoothAudioTargetTest to depend on
android.hardware.audio.common-V2. This is needed so that
the audio HAL service can depend on
android.hardware.bluetooth.audio-V3.

Bug: 228804498
Test: m
Change-Id: Ic001e651de4cc6ef6920f1d6d80ab272c45aefe2
Merged-In: Ic001e651de4cc6ef6920f1d6d80ab272c45aefe2
2023-08-01 13:38:47 -07:00
Wonsik Kim
b93626c412 Merge changes from topic "cherrypicker-L17700000962261813:N11400001392188571" into main
* changes:
  Support mainline s/w codec
  AIDL BufferPool implementation (HIDL -> AIDL)
  AIDL bufferpool implementation (just copy from HIDL impl)
  bufferpool2: Support mainline s/w codec
  bufferpool2: add sync() method and etc
2023-08-01 19:33:08 +00:00
Sungtak Lee
4c7908859c Support mainline s/w codec
Bug: 254050250
Test: m
Merged-In: Id160730a334bf09b91115ada2706c89e6b80192a
Change-Id: Id160730a334bf09b91115ada2706c89e6b80192a
2023-08-01 19:32:52 +00:00
Sungtak Lee
8878a13271 AIDL BufferPool implementation (HIDL -> AIDL)
Bug: 254050250
Test: m
Merged-In: I0d7bae2c01bd480d1e99f4b39c4a9013a2828897
Change-Id: I0d7bae2c01bd480d1e99f4b39c4a9013a2828897
2023-08-01 19:32:45 +00:00
Sungtak Lee
97e1dfb99d AIDL bufferpool implementation (just copy from HIDL impl)
Bug: 254050250
Test: no impact to build
Merged-In: I48841189a8743dcd6533a9e61581e48f0f1717f1
Change-Id: I48841189a8743dcd6533a9e61581e48f0f1717f1
2023-08-01 19:32:34 +00:00
Sungtak Lee
e3d399b3ac bufferpool2: Support mainline s/w codec
Bug: 254050250
Test: m
Merged-In: Id602b1a84880546ee726f36c247fabd2e4f2127c
Change-Id: Id602b1a84880546ee726f36c247fabd2e4f2127c
2023-08-01 19:32:15 +00:00
Sungtak Lee
72b2b38c7f bufferpool2: add sync() method and etc
Add sync() method to IConnection interface.
Add existing connection flag to return parcelable of
IClientManager::registerSender().
Use plain integer for returning fetch result status.

Bug: 254050250
Merged-In: Ifebd4b16e9b8c37e074e7126f39264a18fed5de8
Change-Id: Ifebd4b16e9b8c37e074e7126f39264a18fed5de8
2023-08-01 19:31:27 +00:00
Treehugger Robot
4b64af21a0 Merge changes I385860db,I52fc5134,Icfcea3d6 into main
* changes:
  Freeze android.hardware.power.stats
  Freeze android.hardware.weaver
  Freeze android.hardware.bluetooth.audio
2023-08-01 18:09:44 +00:00
Shraddha Basantwani
2e460345a2 Audio r_submix : Replace usage of portId by device address
Use stream switcher to obtain device address for creation
of a remote submix stream.

Bug: 286914845
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I8dde3d59e488c9621dce78ffd5249254ecfc0b1a
2023-08-01 12:06:38 +00:00
Shraddha Basantwani
035beba203 Audio : Fix a few minor issues with stream switcher class
1. Constructor should forward variable arguments
2. mContext initialization was missing
3. Add nullptr check for addEffect and removeEffect methods

Bug: 264712385
Bug: 286914845
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I4037292bf497be186b26508bd16846886fa4fe55
2023-08-01 12:06:20 +00:00
Devin Moore
567ed4f159 Freeze android.hardware.power.stats
This was done in ag/22462586 internally which is too large to
cherry-pick. It's being applied to aosp to unblock some trunk stable
work.

This CL is generated with:
`m android.hardware.power.stats-freeze-api`

Test: m
Bug: 290265210
Change-Id: I385860dbd7e0d183e159353b2e2d0f8fb5b444eb
Merged-In: I832ab7a8b5445ba85e27bbcf5be64906bfa0e5be
2023-07-31 23:48:01 +00:00
Devin Moore
e4716e8230 Freeze android.hardware.weaver
This was done in ag/22462586 internally which is too large to
cherry-pick. It's being applied to aosp to unblock some trunk stable
work.

This CL is generated with:
`m android.hardware.weaver-freeze-api`

Test: m
Bug: 290265210
Change-Id: I52fc5134a97d749b826b2f9318839369502ac85a
Merged-In: I832ab7a8b5445ba85e27bbcf5be64906bfa0e5be
2023-07-31 23:47:54 +00:00
Devin Moore
dfcd3bda4b Freeze android.hardware.bluetooth.audio
This was done in ag/22462586 internally which is too large to
cherry-pick. It's being applied to aosp to unblock some trunk stable
work.

This CL is generated with:
`m android.hardware.bluetooth.audio-freeze-api`

Test: m
Bug: 290265210
Change-Id: Icfcea3d6971dd0b91cd320d9995b70bcb38a3750
Merged-In: I832ab7a8b5445ba85e27bbcf5be64906bfa0e5be
2023-07-31 23:46:41 +00:00
Hugo Drumond Jacob
28b2c1ad37 [automerger skipped] [DO NOT MERGE] Handle unavailable properties am: aeafec3db0 -s ours am: 373a052124 -s ours
am skip reason: subject contains skip directive

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

Change-Id: I3a400c1f5427cffca8e78ffebfa690d0a87cd42b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-28 13:27:45 +00:00
Hugo Drumond Jacob
373a052124 [automerger skipped] [DO NOT MERGE] Handle unavailable properties am: aeafec3db0 -s ours
am skip reason: subject contains skip directive

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

Change-Id: I850f4b7d589b051086d05d2d59f7dec9d2d86537
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-07-28 11:14:48 +00:00
Treehugger Robot
fb54986369 Merge "Vts VR test -= vr.h - IWYU" into main 2023-07-27 17:54:03 +00:00
Treehugger Robot
bfa8a13317 Merge "Enable Gyroscope sensor injection by AIDL flag" into main 2023-07-26 17:22:28 +00:00
Treehugger Robot
9e9c6feffa Merge "Enable Magnetometer sensor injection by AIDL flag" into main 2023-07-26 16:53:59 +00:00
Ryan Prichard
e5896f0fea Merge "Include <functional> for std::function and std::placeholders" into main 2023-07-25 20:17:01 +00:00
Hugo Drumond Jacob
aeafec3db0 [DO NOT MERGE] Handle unavailable properties
Accommodate the case in which `set()` for an unavailable property is
called as the VHAL may return OK or NOT_AVAILABLE.

Also, it may be the case that certain properties aren't available
while testing and thus, setting a value and getting it right after
might not always work.

Bug: 290882809
Change-Id: I7b7b3f144c4fbd786bf673a86fcac110ec8f79b5
2023-07-25 18:09:28 +00:00