diff mbox series

WIP: Trying to align audio config with hikey for btaudio

Message ID 20200207010154.101101-1-john.stultz@linaro.org
State New
Headers show
Series WIP: Trying to align audio config with hikey for btaudio | expand

Commit Message

John Stultz Feb. 7, 2020, 1:01 a.m. UTC
So far doesn't work

Change-Id: Ic195d4a360fb2ef9d4bd68c14d2c213b6a28bc9e
Signed-off-by: John Stultz <john.stultz@linaro.org>

---
 audio/Android.mk                                      |  3 +--
 audio/audio_hw.c                                      |  2 +-
 etc/audio_policy_configuration.xml                    |  3 +++
 ...udio_policy_configuration_bluetooth_legacy_hal.xml |  3 ---
 manifest.xml                                          | 11 ++++++++++-
 5 files changed, 15 insertions(+), 7 deletions(-)

-- 
2.17.1
diff mbox series

Patch

diff --git a/audio/Android.mk b/audio/Android.mk
index afa804f..108985a 100644
--- a/audio/Android.mk
+++ b/audio/Android.mk
@@ -24,8 +24,7 @@  include $(CLEAR_VARS)
 
 LOCAL_HEADER_LIBRARIES += libhardware_headers
 LOCAL_MODULE := audio.primary.$(TARGET_BOARD_PLATFORM)
-LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib/hw
-LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64/hw
+LOCAL_MODULE_RELATIVE_PATH := hw
 LOCAL_VENDOR_MODULE := true
 
 LOCAL_SRC_FILES := audio_hw.c
diff --git a/audio/audio_hw.c b/audio/audio_hw.c
index d601ea8..689e112 100644
--- a/audio/audio_hw.c
+++ b/audio/audio_hw.c
@@ -52,7 +52,7 @@ 
 /* number of frames per short period (low latency) */
 #define PERIOD_SIZE (CODEC_BASE_FRAME_COUNT * PERIOD_MULTIPLIER)
 /* number of pseudo periods for low latency playback */
-#define PLAYBACK_PERIOD_COUNT 2
+#define PLAYBACK_PERIOD_COUNT 4
 #define PLAYBACK_PERIOD_START_THRESHOLD 2
 #define CODEC_SAMPLING_RATE 48000
 #define CHANNEL_STEREO 2
diff --git a/etc/audio_policy_configuration.xml b/etc/audio_policy_configuration.xml
index c94718e..114db1a 100644
--- a/etc/audio_policy_configuration.xml
+++ b/etc/audio_policy_configuration.xml
@@ -83,6 +83,9 @@ 
 
         </module>
 
+        <!-- A2dp Input Audio HAL -->
+        <xi:include href="a2dp_in_audio_policy_configuration.xml"/>
+
         <!-- Usb Audio HAL -->
         <xi:include href="usb_audio_policy_configuration.xml"/>
 
diff --git a/etc/audio_policy_configuration_bluetooth_legacy_hal.xml b/etc/audio_policy_configuration_bluetooth_legacy_hal.xml
index 2d2eca8..7bbcb34 100644
--- a/etc/audio_policy_configuration_bluetooth_legacy_hal.xml
+++ b/etc/audio_policy_configuration_bluetooth_legacy_hal.xml
@@ -86,9 +86,6 @@ 
         <!-- A2dp Audio HAL -->
         <xi:include href="a2dp_audio_policy_configuration.xml"/>
 
-        <!-- A2dp Input Audio HAL -->
-        <xi:include href="a2dp_in_audio_policy_configuration.xml"/>
-
         <!-- Usb Audio HAL -->
         <xi:include href="usb_audio_policy_configuration.xml"/>
 
diff --git a/manifest.xml b/manifest.xml
index 2342860..de4e622 100644
--- a/manifest.xml
+++ b/manifest.xml
@@ -63,7 +63,7 @@ 
     </hal>
     <hal format="hidl">
         <name>android.hardware.soundtrigger</name>
-        <transport>hwbinder</transport>
+        <transport arch="32">passthrough</transport>
         <version>2.0</version>
         <interface>
             <name>ISoundTriggerHw</name>
@@ -97,6 +97,15 @@ 
             <instance>default</instance>
         </interface>
     </hal>
+    <hal format="hidl">
+        <name>android.hardware.bluetooth.audio</name>
+        <transport>hwbinder</transport>
+        <version>2.0</version>
+        <interface>
+            <name>IBluetoothAudioProvidersFactory</name>
+            <instance>default</instance>
+        </interface>
+    </hal>
     <hal format="hidl">
         <name>android.hardware.wifi.supplicant</name>
         <transport>hwbinder</transport>