audiohal: Always load A2DP module locally
This makes legitimate unix socket interaction between A2DP
module and the Bluetooth stack.
Implemented by allowing both "local" and "hidl" interface
wrappers to co-exist for devices and streams. A "hybrid" device
factory is introduced to create an appropriate implementation
of a device depending on the requested module name.
Bug: 37640821
Test: Play Music over BT headset
Change-Id: I5592961dd5b56840418fb122680979d11a261b6c
diff --git a/media/libaudiohal/EffectHalHidl.cpp b/media/libaudiohal/EffectHalHidl.cpp
index 7d61443..b49b975 100644
--- a/media/libaudiohal/EffectHalHidl.cpp
+++ b/media/libaudiohal/EffectHalHidl.cpp
@@ -209,8 +209,8 @@
status_t EffectHalHidl::setProcessBuffers() {
Return<Result> ret = mEffect->setProcessBuffers(
- reinterpret_cast<EffectBufferHalHidl*>(mInBuffer.get())->hidlBuffer(),
- reinterpret_cast<EffectBufferHalHidl*>(mOutBuffer.get())->hidlBuffer());
+ static_cast<EffectBufferHalHidl*>(mInBuffer.get())->hidlBuffer(),
+ static_cast<EffectBufferHalHidl*>(mOutBuffer.get())->hidlBuffer());
if (ret.isOk() && ret == Result::OK) {
mBuffersChanged = false;
return OK;