sm7250-common: Switch to AOSP BT Stack

Signed-off-by: Sandeep-FED <sandymankara11@gmail.com>
This commit is contained in:
Akshay Kakatkar
2022-02-12 03:38:10 +00:00
committed by Sandeep P S
parent c13e9f282a
commit 8450fb0f17
8 changed files with 18 additions and 138 deletions

View File

@@ -98,8 +98,9 @@ BOARD_SUPPORTS_SOUND_TRIGGER := true
BOARD_USES_ALSA_AUDIO := true BOARD_USES_ALSA_AUDIO := true
USE_CUSTOM_AUDIO_POLICY := 1 USE_CUSTOM_AUDIO_POLICY := 1
# Bluetooth # Camera
TARGET_USE_QTI_BT_STACK := true TARGET_USES_QTI_CAMERA_DEVICE := true
USE_DEVICE_SPECIFIC_CAMERA := true
# Display # Display
TARGET_USES_COLOR_METADATA := true TARGET_USES_COLOR_METADATA := true

View File

@@ -259,21 +259,6 @@
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT" <profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/> samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort> </devicePort>
<devicePort tagName="BT A2DP Out" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT A2DP Headphones" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="BT A2DP Speaker" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER" role="sink"
encodedFormats="AUDIO_FORMAT_SBC AUDIO_FORMAT_AAC AUDIO_FORMAT_APTX AUDIO_FORMAT_APTX_HD AUDIO_FORMAT_LDAC AUDIO_FORMAT_CELT AUDIO_FORMAT_APTX_ADAPTIVE AUDIO_FORMAT_APTX_TWSP">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
<devicePort tagName="USB Device Out" type="AUDIO_DEVICE_OUT_USB_DEVICE" role="sink"> <devicePort tagName="USB Device Out" type="AUDIO_DEVICE_OUT_USB_DEVICE" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT" <profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000,64000,88200,96000,128000,176400,192000" channelMasks="dynamic"/> samplingRates="44100,48000,64000,88200,96000,128000,176400,192000" channelMasks="dynamic"/>
@@ -360,12 +345,6 @@
sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,BT SCO Headset Mic"/> sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,BT SCO Headset Mic"/>
<route type="mix" sink="mmap_no_irq_in" <route type="mix" sink="mmap_no_irq_in"
sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,USB Device In,USB Headset In"/> sources="Built-In Mic,Built-In Back Mic,Wired Headset Mic,USB Device In,USB Headset In"/>
<route type="mix" sink="BT A2DP Out"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT A2DP Headphones"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="BT A2DP Speaker"
sources="primary output,deep_buffer,direct_pcm,compressed_offload,voip_rx"/>
<route type="mix" sink="hifi_input" sources="USB Device In,USB Headset In" /> <route type="mix" sink="hifi_input" sources="USB Device In,USB Headset In" />
<route type="mix" sink="fast input" <route type="mix" sink="fast input"
sources="Built-In Mic,Built-In Back Mic,BT SCO Headset Mic,USB Device In,USB Headset In,Wired Headset Mic"/> sources="Built-In Mic,Built-In Back Mic,BT SCO Headset Mic,USB Device In,USB Headset In,Wired Headset Mic"/>
@@ -375,53 +354,17 @@
</module> </module>
<!-- A2DP Audio HAL --> <!-- A2DP Input Audio HAL -->
<module name="a2dp" halVersion="2.0"> <xi:include href="/vendor/etc/a2dp_audio_policy_configuration.xml"/>
<mixPorts>
<mixPort name="a2dp input" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000" channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</mixPort>
</mixPorts>
<devicePorts>
<devicePort tagName="BT A2DP In" type="AUDIO_DEVICE_IN_BLUETOOTH_A2DP" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100,48000" channelMasks="AUDIO_CHANNEL_IN_MONO,AUDIO_CHANNEL_IN_STEREO"/>
</devicePort>
</devicePorts>
<routes>
<route type="mix" sink="a2dp input"
sources="BT A2DP In"/>
</routes>
</module>
<!-- Usb Audio HAL --> <!-- Usb Audio HAL -->
<module name="usb" halVersion="2.0"> <xi:include href="/vendor/etc/usb_audio_policy_configuration.xml"/>
<mixPorts>
<mixPort name="usb_accessory output" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
</mixPorts>
<devicePorts>
<devicePort tagName="USB Host Out" type="AUDIO_DEVICE_OUT_USB_ACCESSORY" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</devicePort>
</devicePorts>
<routes>
<route type="mix" sink="USB Host Out"
sources="usb_accessory output"/>
</routes>
</module>
<!-- Remote Submix Audio HAL --> <!-- Remote Submix Audio HAL -->
<xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/> <xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/>
<!-- Bluetooth Audio HAL for hearing aid --> <!-- Bluetooth Audio HAL -->
<xi:include href="/vendor/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml"/> <xi:include href="/vendor/etc/bluetooth_audio_policy_configuration.xml"/>
</modules> </modules>
<!-- End of Modules section --> <!-- End of Modules section -->

View File

@@ -1,38 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright (c) 2020 The Linux Foundation. All rights reserved.
Not a contribution.
-->
<!-- Copyright (C) 2018 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- Bluetooth Audio HAL Audio Policy Configuration file -->
<module name="bluetooth_qti" halVersion="2.0">
<mixPorts>
<!-- Hearing AIDs Audio Ports -->
<mixPort name="hearing aid output" role="source">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
samplingRates="24000,16000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
</mixPorts>
<devicePorts>
<!-- Hearing AIDs Audio Ports -->
<devicePort tagName="BT Hearing Aid Out" type="AUDIO_DEVICE_OUT_HEARING_AID" role="sink"/>
</devicePorts>
<routes>
<route type="mix" sink="BT Hearing Aid Out"
sources="hearing aid output"/>
</routes>
</module>

View File

@@ -165,12 +165,12 @@ PRODUCT_PACKAGES += \
PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/audio/audio_io_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_io_policy.conf \ $(LOCAL_PATH)/audio/audio_io_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_io_policy.conf \
$(LOCAL_PATH)/audio/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \ $(LOCAL_PATH)/audio/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml
$(LOCAL_PATH)/audio/bluetooth_qti_hearing_aid_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml
PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \
frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \ frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \
frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \ frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
frameworks/av/services/audiopolicy/config/bluetooth_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_audio_policy_configuration.xml \
frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \ frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \ frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml
@@ -227,8 +227,7 @@ PRODUCT_PACKAGES += \
# Component overrides # Component overrides
PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/configs/component-overrides.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sysconfig/component-overrides.xml \ $(LOCAL_PATH)/configs/component-overrides.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sysconfig/component-overrides.xml
$(LOCAL_PATH)/configs/component-overrides_qti.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/sysconfig/component-overrides.xml
# Display # Display
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \

View File

@@ -15,6 +15,8 @@
--> -->
<config> <config>
<component-override package="com.android.bluetooth" > <component-override package="com.android.bluetooth" >
<component class=".avrcpcontroller.AvrcpControllerService" enabled="true" />
<component class=".hid.HidDeviceService" enabled="true" />
<component class=".sap.SapService" enabled="true" /> <component class=".sap.SapService" enabled="true" />
</component-override> </component-override>
</config> </config>

View File

@@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2019 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<config>
<component-override package="com.android.bluetooth" >
<component class=".a2dpsink.A2dpSinkService" enabled="true" />
<component class=".avrcp.AvrcpTargetService" enabled="false" />
<component class=".avrcpcontroller.AvrcpControllerService" enabled="true" />
<component class=".ba.BATService" enabled="true" />
<component class=".hfpclient.HeadsetClientService" enabled="false" />
<component class=".hid.HidDeviceService" enabled="true" />
<component class=".hid.HidHostService" enabled="true" />
</component-override>
</config>

View File

@@ -23,7 +23,6 @@ persist.vendor.radio.atfwd.start=true
persist.vendor.btstack.enable.lpa=true persist.vendor.btstack.enable.lpa=true
persist.vendor.btstack.enable.twsplus=true persist.vendor.btstack.enable.twsplus=true
persist.vendor.bt.a2dp.hal.implementation=true persist.vendor.bt.a2dp.hal.implementation=true
ro.bluetooth.library_name=libbluetooth_qti.so
persist.vendor.btstack.enable.twsplussho=true persist.vendor.btstack.enable.twsplussho=true
# Blur # Blur

View File

@@ -24,7 +24,7 @@ vendor.audio.adm.buffering.ms=2
vendor.audio.dolby.ds2.enabled=false vendor.audio.dolby.ds2.enabled=false
vendor.audio.dolby.ds2.hardbypass=false vendor.audio.dolby.ds2.hardbypass=false
vendor.audio.enable.mirrorlink=false vendor.audio.enable.mirrorlink=false
vendor.audio.feature.a2dp_offload.enable=true vendor.audio.feature.a2dp_offload.enable=false
vendor.audio.feature.afe_proxy.enable=true vendor.audio.feature.afe_proxy.enable=true
vendor.audio.feature.anc_headset.enable=true vendor.audio.feature.anc_headset.enable=true
vendor.audio.feature.audiozoom.enable=false vendor.audio.feature.audiozoom.enable=false
@@ -89,10 +89,11 @@ vendor.audio_hal.period_size=192
# Bluetooth # Bluetooth
persist.bluetooth.a2dp_offload.cap=sbc-aac-aptx-aptxhd-ldac persist.bluetooth.a2dp_offload.cap=sbc-aac-aptx-aptxhd-ldac
persist.bluetooth.a2dp_offload.disabled=false persist.bluetooth.a2dp_offload.disabled=true
persist.bluetooth.btsnoopdefaultmode= persist.bluetooth.btsnoopdefaultmode=
persist.sys.fflag.override.settings_bluetooth_hearing_aid=true persist.sys.fflag.override.settings_bluetooth_hearing_aid=true
persist.vendor.bluetooth.bt.uart.log=1 persist.vendor.bluetooth.bt.uart.log=1
persist.vendor.bt.a2dp.aac_whitelist=false
persist.vendor.bt.a2dp.hal.implementation=true persist.vendor.bt.a2dp.hal.implementation=true
persist.vendor.bt.aac_frm_ctl.enabled=true persist.vendor.bt.aac_frm_ctl.enabled=true
persist.vendor.bt.aac_vbr_frm_ctl.enabled=true persist.vendor.bt.aac_vbr_frm_ctl.enabled=true
@@ -105,12 +106,11 @@ persist.vendor.qcom.bluetooth.a2dp_offload_cap=sbc-aptx-aptxtws-aptxhd-aac-ldac-
persist.vendor.qcom.bluetooth.aptxadaptiver2_1_support=false persist.vendor.qcom.bluetooth.aptxadaptiver2_1_support=false
persist.vendor.qcom.bluetooth.aac_vbr_ctl.enabled=true persist.vendor.qcom.bluetooth.aac_vbr_ctl.enabled=true
persist.vendor.qcom.bluetooth.aptxadaptiver2_1_support=false persist.vendor.qcom.bluetooth.aptxadaptiver2_1_support=false
persist.vendor.qcom.bluetooth.enable.splita2dp=true persist.vendor.qcom.bluetooth.enable.splita2dp=false
persist.vendor.qcom.bluetooth.scram.enabled=false persist.vendor.qcom.bluetooth.scram.enabled=false
persist.vendor.qcom.bluetooth.soc=cherokee persist.vendor.qcom.bluetooth.soc=cherokee
persist.vendor.qcom.bluetooth.twsp_state.enabled=false persist.vendor.qcom.bluetooth.twsp_state.enabled=false
ro.bluetooth.a2dp_offload.supported=true ro.bluetooth.a2dp_offload.supported=false
ro.bluetooth.library_name=libbluetooth_qti.so
ro.vendor.bluetooth.wipower=false ro.vendor.bluetooth.wipower=false
sys.fflag.override.settings_bluetooth_hearing_aid=true sys.fflag.override.settings_bluetooth_hearing_aid=true