Add missing Cap Settings aidl (Part I)
Add the missing aidl to get the whole CAP
(Configurable AudioPolicy) configuration from AIDL AudioHAL.
This is a minimal change in the AIDL to start the new
version (V4) of android.media.audio.common.types.
Flag: EXEMPT HAL interface change
Bug: 307310023
Test: m
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:f46f7eaedec7bea9f17c66559610503d737c13f2)
Merged-In: Ia2b29836910a8da00d498cb5dc067469621b30fd
Change-Id: Ia2b29836910a8da00d498cb5dc067469621b30fd
diff --git a/media/Android.bp b/media/Android.bp
index d7a1eac..ef38612 100644
--- a/media/Android.bp
+++ b/media/Android.bp
@@ -135,12 +135,12 @@
// IMPORTANT: Update latest_android_media_audio_common_types every time
// you add the latest frozen version to versions_with_info
],
- frozen: true,
+ frozen: false,
}
// Note: This should always be one version ahead of the last frozen version
-latest_android_media_audio_common_types = "android.media.audio.common.types-V3"
+latest_android_media_audio_common_types = "android.media.audio.common.types-V4"
// Modules that depend on android.media.audio.common.types directly can include
// the following cc_defaults to avoid explicitly managing dependency versions
@@ -261,12 +261,12 @@
},
],
- frozen: true,
+ frozen: false,
}
// Note: This should always be one version ahead of the last frozen version
-latest_android_media_soundtrigger_types = "android.media.soundtrigger.types-V2"
+latest_android_media_soundtrigger_types = "android.media.soundtrigger.types-V3"
cc_defaults {
name: "latest_android_media_soundtrigger_types_cpp_shared",
diff --git a/media/aidl/android/media/audio/common/AudioHalProductStrategy.aidl b/media/aidl/android/media/audio/common/AudioHalProductStrategy.aidl
index 214b3d4..c3bc656 100644
--- a/media/aidl/android/media/audio/common/AudioHalProductStrategy.aidl
+++ b/media/aidl/android/media/audio/common/AudioHalProductStrategy.aidl
@@ -44,4 +44,15 @@
* This is the list of use cases that follow the same routing strategy.
*/
AudioHalAttributesGroup[] attributesGroups;
+ /**
+ * Name of the strategy. Nullable for backward compatibility. If null, id
+ * are assigned by the audio policy engine, ensuring uniqueness.
+ *
+ * With complete engine configuration AIDL migration, strategy ids are
+ * preallocated (from `VENDOR_STRATEGY_ID_START` to
+ * `VENDOR_STRATEGY_ID_START+39`). A human readable name must be
+ * defined uniquely (to make dump/debug easier) for all strategies and
+ * must not be null for any.
+ */
+ @nullable @utf8InCpp String name;
}
diff --git a/media/aidl_api/android.media.audio.common.types/current/android/media/audio/common/AudioHalProductStrategy.aidl b/media/aidl_api/android.media.audio.common.types/current/android/media/audio/common/AudioHalProductStrategy.aidl
index 9615961..1144574 100644
--- a/media/aidl_api/android.media.audio.common.types/current/android/media/audio/common/AudioHalProductStrategy.aidl
+++ b/media/aidl_api/android.media.audio.common.types/current/android/media/audio/common/AudioHalProductStrategy.aidl
@@ -37,5 +37,6 @@
parcelable AudioHalProductStrategy {
int id = android.media.audio.common.AudioProductStrategyType.SYS_RESERVED_NONE /* -1 */;
android.media.audio.common.AudioHalAttributesGroup[] attributesGroups;
+ @nullable @utf8InCpp String name;
const int VENDOR_STRATEGY_ID_START = 1000;
}