audio: Add offload reconfiguration event to IBluetoothLe
Since BT LE can also have offloaded codecs, it might need
a reconfiguration event similar to the one that BT A2DP
receives.
Bug: 272658632
Test: atest VtsHalAudioCoreTargetTest
Change-Id: I04fb7c99f0457f87e1f4aaf7e77165317163387b
diff --git a/audio/aidl/default/Bluetooth.cpp b/audio/aidl/default/Bluetooth.cpp
index 8115e7b..c32b538 100644
--- a/audio/aidl/default/Bluetooth.cpp
+++ b/audio/aidl/default/Bluetooth.cpp
@@ -117,4 +117,17 @@
return ndk::ScopedAStatus::ok();
}
+ndk::ScopedAStatus BluetoothLe::supportsOffloadReconfiguration(bool* _aidl_return) {
+ *_aidl_return = true;
+ LOG(DEBUG) << __func__ << ": returning " << *_aidl_return;
+ return ndk::ScopedAStatus::ok();
+}
+
+ndk::ScopedAStatus BluetoothLe::reconfigureOffload(
+ const std::vector<::aidl::android::hardware::audio::core::VendorParameter>& in_parameters
+ __unused) {
+ LOG(DEBUG) << __func__ << ": " << ::android::internal::ToString(in_parameters);
+ return ndk::ScopedAStatus::ok();
+}
+
} // namespace aidl::android::hardware::audio::core
diff --git a/audio/aidl/default/include/core-impl/Bluetooth.h b/audio/aidl/default/include/core-impl/Bluetooth.h
index 1cd0355..10e9045 100644
--- a/audio/aidl/default/include/core-impl/Bluetooth.h
+++ b/audio/aidl/default/include/core-impl/Bluetooth.h
@@ -56,6 +56,10 @@
private:
ndk::ScopedAStatus isEnabled(bool* _aidl_return) override;
ndk::ScopedAStatus setEnabled(bool in_enabled) override;
+ ndk::ScopedAStatus supportsOffloadReconfiguration(bool* _aidl_return) override;
+ ndk::ScopedAStatus reconfigureOffload(
+ const std::vector<::aidl::android::hardware::audio::core::VendorParameter>&
+ in_parameters) override;
bool mEnabled = false;
};