Merge "configs: lahaina: update sva mic mixer paths"
diff --git a/configs/atoll/audio_policy_configuration.xml b/configs/atoll/audio_policy_configuration.xml
index 5ef3a70..60537d3 100755
--- a/configs/atoll/audio_policy_configuration.xml
+++ b/configs/atoll/audio_policy_configuration.xml
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/bengal/audio_policy_configuration.xml b/configs/bengal/audio_policy_configuration.xml
index 007bba5..8e2c1ee 100644
--- a/configs/bengal/audio_policy_configuration.xml
+++ b/configs/bengal/audio_policy_configuration.xml
@@ -153,7 +153,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/kona/audio_policy_configuration.xml b/configs/kona/audio_policy_configuration.xml
index 556c5b3..6853fe8 100644
--- a/configs/kona/audio_policy_configuration.xml
+++ b/configs/kona/audio_policy_configuration.xml
@@ -152,7 +152,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/lahaina/audio_policy_configuration.xml b/configs/lahaina/audio_policy_configuration.xml
index 3f9b799..f469c65 100644
--- a/configs/lahaina/audio_policy_configuration.xml
+++ b/configs/lahaina/audio_policy_configuration.xml
@@ -157,7 +157,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
@@ -430,18 +430,18 @@
</module>
<!-- Remote Submix Audio HAL -->
- <xi:include href="/vendor/etc/audio/sku_lahaina/r_submix_audio_policy_configuration.xml"/>
+ <xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/>
<!-- Bluetooth Audio HAL for hearing aid -->
- <xi:include href="/vendor/etc/audio/sku_lahaina/bluetooth_qti_hearing_aid_audio_policy_configuration.xml"/>
+ <xi:include href="/vendor/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml"/>
</modules>
<!-- End of Modules section -->
<!-- Volume section -->
- <xi:include href="/vendor/etc/audio/sku_lahaina/audio_policy_volumes.xml"/>
- <xi:include href="/vendor/etc/audio/sku_lahaina/default_volume_tables.xml"/>
+ <xi:include href="/vendor/etc/audio_policy_volumes.xml"/>
+ <xi:include href="/vendor/etc/default_volume_tables.xml"/>
<!-- End of Volume section -->
diff --git a/configs/lahaina/lahaina.mk b/configs/lahaina/lahaina.mk
index 09b52f3..7b1a483 100644
--- a/configs/lahaina/lahaina.mk
+++ b/configs/lahaina/lahaina.mk
@@ -147,47 +147,6 @@
$(TOPDIR)vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_audio_policy_configuration.xml \
$(TOPDIR)vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_hearing_aid_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml
-#TODO: Delete xml's from obsolete paths
-# Audio configuration xml's related to Lahaina
-QCV_FAMILY_SKUS := lahaina
-DEVICE_SKU := lahaina
-
-PRODUCT_COPY_FILES += \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_io_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_io_policy.conf \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_effects.conf \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_effects.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_effects.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/sound_trigger_platform_info.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_platform_info.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_platform_info_qrd.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_platform_info_qrd.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_platform_info_intcodec.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_platform_info_intcodec.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/sound_trigger_mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/sound_trigger_mixer_paths.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/sound_trigger_mixer_paths_qrd.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/sound_trigger_mixer_paths_qrd.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/sound_trigger_mixer_paths_cdp.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/sound_trigger_mixer_paths_cdp.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/mixer_paths.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/mixer_paths_qrd.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/mixer_paths_qrd.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/mixer_paths_cdp.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/mixer_paths_cdp.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_configs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_configs.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_configs_stock.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_configs_stock.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/lahaina/audio_tuning_mixer.txt:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_tuning_mixer.txt
-
-# Audio configuration xml's common to Lahaina family
-PRODUCT_COPY_FILES += \
-$(foreach DEVICE_SKU, $(QCV_FAMILY_SKUS), \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/common/media_codecs_vendor_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/media_codecs_vendor_audio.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/common/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_policy_configuration.xml \
- frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/a2dp_audio_policy_configuration.xml \
- frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/audio_policy_volumes.xml \
- frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/default_volume_tables.xml \
- frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/r_submix_audio_policy_configuration.xml \
- frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/usb_audio_policy_configuration.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/bluetooth_qti_audio_policy_configuration.xml \
- vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_hearing_aid_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/sku_$(DEVICE_SKU)/bluetooth_qti_hearing_aid_audio_policy_configuration.xml)
-
-# Audio permission xml's common to Lahaina family
-PRODUCT_COPY_FILES += \
- frameworks/native/data/etc/android.hardware.audio.pro.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.pro.xml \
- frameworks/native/data/etc/android.hardware.audio.low_latency.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.audio.low_latency.xml
-
# Reduce client buffer size for fast audio output tracks
PRODUCT_PROPERTY_OVERRIDES += \
af.fast_track_multiplier=1
@@ -225,10 +184,11 @@
persist.audio.fluence.voicerec=false\
persist.audio.fluence.speaker=true
-##speaker protection v3 switch and ADSP AFE API version
+##speaker protection v4 switch and ADSP AFE API version
PRODUCT_PROPERTY_OVERRIDES += \
-persist.vendor.audio.spv3.enable=true\
-persist.vendor.audio.avs.afe_api_version=2
+persist.vendor.audio.speaker.prot.enable=true\
+persist.vendor.audio.spv4.enable=true\
+persist.vendor.audio.avs.afe_api_version=9
#disable tunnel encoding
PRODUCT_PROPERTY_OVERRIDES += \
@@ -441,7 +401,8 @@
vendor.audio.feature.vbat.enable=true \
vendor.audio.feature.wsa.enable=false \
vendor.audio.feature.audiozoom.enable=false \
-vendor.audio.feature.snd_mon.enable=true
+vendor.audio.feature.snd_mon.enable=true \
+vendor.audio.feature.power_mode.enable=true
# for HIDL related packages
PRODUCT_PACKAGES += \
diff --git a/configs/lahaina/mixer_paths.xml b/configs/lahaina/mixer_paths.xml
index 85fca5f..dbbfdf1 100644
--- a/configs/lahaina/mixer_paths.xml
+++ b/configs/lahaina/mixer_paths.xml
@@ -1771,7 +1771,7 @@
<ctl name="MultiMedia17 Mixer SLIM_7_TX" value="1" />
</path>
- <path name="audio-record-compress bt-sco-wb">
+ <path name="audio-record-compress2 bt-sco-wb">
<path name="audio-record-compress2 bt-sco" />
</path>
@@ -2887,10 +2887,16 @@
</path>
<path name="speaker-dmic-broadside">
<ctl name="TX_CDC_DMA_TX_3 Channels" value="Two" />
- <ctl name="TX_AIF1_CAP Mixer DEC1" value="1" />
- <ctl name="TX DMIC MUX1" value="DMIC4" />
<ctl name="TX_AIF1_CAP Mixer DEC2" value="1" />
- <ctl name="TX DMIC MUX2" value="DMIC1" />
+ <ctl name="TX DEC1 MUX" value="SWR_MIC" />
+ <ctl name="TX SMIC MUX1" value="SWR_MIC3" />
+ <ctl name="TX_AIF1_CAP Mixer DEC1" value="1" />
+ <ctl name="TX DEC2 MUX" value="SWR_MIC" />
+ <ctl name="TX SMIC MUX2" value="SWR_MIC0" />
+ <ctl name="SWR_MIC3 SWR_DMIC_MIXER Switch" value="1" />
+ <ctl name="SWR_MIC3 HIFI PortMap" value="SWRM_TX1_CH4" />
+ <ctl name="SWR_MIC0 SWR_DMIC_MIXER Switch" value="1" />
+ <ctl name="SWR_MIC0 HIFI PortMap" value="SWRM_TX1_CH1" />
</path>
<path name="dmic-broadside">
diff --git a/configs/lahaina/mixer_paths_cdp.xml b/configs/lahaina/mixer_paths_cdp.xml
index 51ea04a..f8e09ad 100644
--- a/configs/lahaina/mixer_paths_cdp.xml
+++ b/configs/lahaina/mixer_paths_cdp.xml
@@ -1643,7 +1643,7 @@
<ctl name="MultiMedia17 Mixer SLIM_7_TX" value="1" />
</path>
- <path name="audio-record-compress bt-sco-wb">
+ <path name="audio-record-compress2 bt-sco-wb">
<path name="audio-record-compress2 bt-sco" />
</path>
diff --git a/configs/lahaina/mixer_paths_qrd.xml b/configs/lahaina/mixer_paths_qrd.xml
index c953d75..e80ae22 100644
--- a/configs/lahaina/mixer_paths_qrd.xml
+++ b/configs/lahaina/mixer_paths_qrd.xml
@@ -1770,7 +1770,7 @@
<ctl name="MultiMedia17 Mixer SLIM_7_TX" value="1" />
</path>
- <path name="audio-record-compress bt-sco-wb">
+ <path name="audio-record-compress2 bt-sco-wb">
<path name="audio-record-compress2 bt-sco" />
</path>
diff --git a/configs/lito/audio_platform_info.xml b/configs/lito/audio_platform_info.xml
index 79d307e..dbdb29f 100644
--- a/configs/lito/audio_platform_info.xml
+++ b/configs/lito/audio_platform_info.xml
@@ -46,6 +46,7 @@
<device name="SND_DEVICE_IN_USB_HEADSET_HEX_MIC_AEC" acdb_id="162"/>
<device name="SND_DEVICE_IN_UNPROCESSED_USB_HEADSET_HEX_MIC" acdb_id="162"/>
<device name="SND_DEVICE_IN_VOCE_RECOG_USB_HEADSET_HEX_MIC" acdb_id="162"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" acdb_id="11"/>
</acdb_ids>
<module_ids>
@@ -239,6 +240,7 @@
<device name="SND_DEVICE_IN_SPEAKER_QMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_THREE_MIC" interface="TX_CDC_DMA_TX_3"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_FLUENCE_PRO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
diff --git a/configs/lito/audio_platform_info_intcodec.xml b/configs/lito/audio_platform_info_intcodec.xml
index 4abcd98..45d8bcb 100644
--- a/configs/lito/audio_platform_info_intcodec.xml
+++ b/configs/lito/audio_platform_info_intcodec.xml
@@ -106,6 +106,7 @@
<device name="SND_DEVICE_IN_UNPROCESSED_QUAD_MIC" acdb_id="146"/>
<device name="SND_DEVICE_IN_UNPROCESSED_HEADSET_MIC" acdb_id="147"/>
<device name="SND_DEVICE_IN_HANDSET_GENERIC_QMIC" acdb_id="191"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" acdb_id="11"/>
</acdb_ids>
<backend_names>
<device name="SND_DEVICE_OUT_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
@@ -227,6 +228,7 @@
<device name="SND_DEVICE_IN_SPEAKER_QMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_THREE_MIC" interface="TX_CDC_DMA_TX_3"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_FLUENCE_PRO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
diff --git a/configs/lito/audio_platform_info_lagoon_qrd.xml b/configs/lito/audio_platform_info_lagoon_qrd.xml
index b98ac83..cf53e0e 100644
--- a/configs/lito/audio_platform_info_lagoon_qrd.xml
+++ b/configs/lito/audio_platform_info_lagoon_qrd.xml
@@ -80,7 +80,7 @@
<param key="hifi_filter" value="false"/>
<param key="native_audio_mode" value="multiple_mix_dsp"/>
<param key="hfp_pcm_dev_id" value="39"/>
- <param key="input_mic_max_count" value="4"/>
+ <param key="input_mic_max_count" value="3"/>
</config_params>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="14"/>
@@ -230,6 +230,7 @@
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
+ <device name="SND_DEVICE_IN_VOICE_SPEAKER_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_STEREO_MIC" interface="TX_CDC_DMA_TX_3"/>
diff --git a/configs/lito/audio_platform_info_qrd.xml b/configs/lito/audio_platform_info_qrd.xml
index 4aa782c..afcafd9 100644
--- a/configs/lito/audio_platform_info_qrd.xml
+++ b/configs/lito/audio_platform_info_qrd.xml
@@ -80,7 +80,7 @@
<param key="hifi_filter" value="false"/>
<param key="native_audio_mode" value="multiple_mix_dsp"/>
<param key="hfp_pcm_dev_id" value="39"/>
- <param key="input_mic_max_count" value="4"/>
+ <param key="input_mic_max_count" value="3"/>
</config_params>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
@@ -105,6 +105,7 @@
<device name="SND_DEVICE_IN_UNPROCESSED_QUAD_MIC" acdb_id="146"/>
<device name="SND_DEVICE_IN_UNPROCESSED_HEADSET_MIC" acdb_id="147"/>
<device name="SND_DEVICE_IN_HANDSET_GENERIC_QMIC" acdb_id="191"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" acdb_id="11"/>
</acdb_ids>
<backend_names>
<device name="SND_DEVICE_OUT_HEADPHONES" backend="headphones" interface="RX_CDC_DMA_RX_0"/>
@@ -218,11 +219,13 @@
<device name="SND_DEVICE_IN_SPEAKER_QMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_SPEAKER_QMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_THREE_MIC" interface="TX_CDC_DMA_TX_3"/>
+ <device name="SND_DEVICE_IN_VOICE_HEARING_AID" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_FLUENCE_PRO" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_NS" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_HANDSET_TMIC_AEC_NS" interface="TX_CDC_DMA_TX_3"/>
+ <device name="SND_DEVICE_IN_VOICE_SPEAKER_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_VOICE_REC_TMIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_MIC" interface="TX_CDC_DMA_TX_3"/>
<device name="SND_DEVICE_IN_UNPROCESSED_STEREO_MIC" interface="TX_CDC_DMA_TX_3"/>
diff --git a/configs/lito/audio_policy_configuration.xml b/configs/lito/audio_policy_configuration.xml
index 63bf298..e04dac3 100644
--- a/configs/lito/audio_policy_configuration.xml
+++ b/configs/lito/audio_policy_configuration.xml
@@ -153,7 +153,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
@@ -428,6 +428,9 @@
<!-- Remote Submix Audio HAL -->
<xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/>
+ <!-- Bluetooth Audio HAL for hearing aid -->
+ <xi:include href="/vendor/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml"/>
+
</modules>
<!-- End of Modules section -->
diff --git a/configs/lito/lito.mk b/configs/lito/lito.mk
index ce6bf00..43228d0 100644
--- a/configs/lito/lito.mk
+++ b/configs/lito/lito.mk
@@ -224,7 +224,8 @@
$(TOPDIR)frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
$(TOPDIR)frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
$(TOPDIR)frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml \
- $(TOPDIR)vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_audio_policy_configuration.xml
+ $(TOPDIR)vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_audio_policy_configuration.xml \
+ $(TOPDIR)vendor/qcom/opensource/audio-hal/primary-hal/configs/common/bluetooth_qti_hearing_aid_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml
# Low latency audio buffer size in frames
PRODUCT_PROPERTY_OVERRIDES += \
diff --git a/configs/lito/mixer_paths.xml b/configs/lito/mixer_paths.xml
index 5d88a94..41e78f5 100644
--- a/configs/lito/mixer_paths.xml
+++ b/configs/lito/mixer_paths.xml
@@ -2363,6 +2363,11 @@
<ctl name="VoiceMMode1_Tx Mixer PROXY_TX_MMode1" value="1" />
</path>
+ <path name="voicemmode1-call hearing-aid">
+ <ctl name="PROXY_RX_Voice Mixer VoiceMMode1" value="1" />
+ <ctl name="VoiceMMode1_Tx Mixer TX_CDC_DMA_TX_3_MMode1" value="1" />
+ </path>
+
<path name="voicemmode1-call headphones">
<ctl name="RX_CDC_DMA_RX_0_Voice Mixer VoiceMMode1" value="1" />
<ctl name="VoiceMMode1_Tx Mixer TX_CDC_DMA_TX_3_MMode1" value="1" />
@@ -2427,6 +2432,11 @@
<ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
</path>
+ <path name="voicemmode2-call hearing-aid">
+ <ctl name="PROXY_RX_Voice Mixer VoiceMMode2" value="1" />
+ <ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
+ </path>
+
<path name="voicemmode2-call headphones">
<ctl name="RX_CDC_DMA_RX_0_Voice Mixer VoiceMMode2" value="1" />
<ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
@@ -3064,6 +3074,10 @@
<path name="dmic-endfire" />
</path>
+ <path name="hearing-aid-mic">
+ <path name="voice-speaker-mic"/>
+ </path>
+
<path name="handset-stereo-dmic-ef-liquid">
<path name="handset-dmic-endfire" />
</path>
diff --git a/configs/lito/mixer_paths_lagoonqrd.xml b/configs/lito/mixer_paths_lagoonqrd.xml
index fc6325f..0c5dd7e 100644
--- a/configs/lito/mixer_paths_lagoonqrd.xml
+++ b/configs/lito/mixer_paths_lagoonqrd.xml
@@ -3510,7 +3510,7 @@
</path>
<path name="speaker-tmic">
- <path name="three-tmic" />
+ <path name="three-mic" />
</path>
<path name="voice-speaker-tmic">
diff --git a/configs/lito/mixer_paths_qrd.xml b/configs/lito/mixer_paths_qrd.xml
index b2daf27..d225ff7 100644
--- a/configs/lito/mixer_paths_qrd.xml
+++ b/configs/lito/mixer_paths_qrd.xml
@@ -2370,6 +2370,11 @@
<ctl name="VoiceMMode1_Tx Mixer TX_CDC_DMA_TX_3_MMode1" value="1" />
</path>
+ <path name="voicemmode1-call hearing-aid">
+ <ctl name="PROXY_RX_Voice Mixer VoiceMMode1" value="1" />
+ <ctl name="VoiceMMode1_Tx Mixer TX_CDC_DMA_TX_3_MMode1" value="1" />
+ </path>
+
<path name="voicemmode1-call handset">
<ctl name="RX_CDC_DMA_RX_0_Voice Mixer VoiceMMode1" value="1" />
<ctl name="VoiceMMode1_Tx Mixer TX_CDC_DMA_TX_3_MMode1" value="1" />
@@ -2444,6 +2449,11 @@
<ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
</path>
+ <path name="voicemmode2-call hearing-aid">
+ <ctl name="PROXY_RX_Voice Mixer VoiceMMode2" value="1" />
+ <ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
+ </path>
+
<path name="voicemmode2-call handset">
<ctl name="RX_CDC_DMA_RX_0_Voice Mixer VoiceMMode2" value="1" />
<ctl name="VoiceMMode2_Tx Mixer TX_CDC_DMA_TX_3_MMode2" value="1" />
@@ -3479,6 +3489,10 @@
<path name="dmic-endfire" />
</path>
+ <path name="hearing-aid-mic">
+ <path name="voice-speaker-mic"/>
+ </path>
+
<path name="voice-rec-dmic-ef-fluence">
<path name="dmic-endfire" />
</path>
diff --git a/configs/msm8953/audio_policy_configuration.xml b/configs/msm8953/audio_policy_configuration.xml
index 9f6e7dc..4e78004 100644
--- a/configs/msm8953/audio_policy_configuration.xml
+++ b/configs/msm8953/audio_policy_configuration.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!-- Copyright (c) 2016-2017, The Linux Foundation. All rights reserved
+<!-- Copyright (c) 2016-2017, 2020 The Linux Foundation. All rights reserved
Not a Contribution.
-->
<!-- Copyright (C) 2015 The Android Open Source Project
@@ -134,7 +134,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink" maxOpenCount="2" maxActiveCount="2">
diff --git a/configs/msm8953/msm8953.mk b/configs/msm8953/msm8953.mk
index 9262e4a..ab7c855 100644
--- a/configs/msm8953/msm8953.mk
+++ b/configs/msm8953/msm8953.mk
@@ -93,7 +93,6 @@
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/sound_trigger_mixer_paths_wcd9330.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9330.xml \
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/sound_trigger_mixer_paths_wcd9335.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9335.xml \
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_platform_info.xml \
-vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/audio_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info.xml \
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/audio_platform_info_intcodec.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_intcodec.xml \
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/audio_platform_info_tashalite.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_tashalite.xml \
vendor/qcom/opensource/audio-hal/primary-hal/configs/msm8953/audio_platform_info_sku3_tasha.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_sku3_tasha.xml \
diff --git a/configs/msmnile/audio_policy_configuration.xml b/configs/msmnile/audio_policy_configuration.xml
index 486fd32..7a8a230 100644
--- a/configs/msmnile/audio_policy_configuration.xml
+++ b/configs/msmnile/audio_policy_configuration.xml
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/msmnile_au/audio_policy_configuration.xml b/configs/msmnile_au/audio_policy_configuration.xml
index 852d4d0..9df9d5e 100644
--- a/configs/msmnile_au/audio_policy_configuration.xml
+++ b/configs/msmnile_au/audio_policy_configuration.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!-- Copyright (c) 2016-2019, The Linux Foundation. All rights reserved
+<!-- Copyright (c) 2016-2020, The Linux Foundation. All rights reserved
Not a Contribution.
-->
<!-- Copyright (C) 2015 The Android Open Source Project
@@ -195,7 +195,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/msmsteppe/audio_policy_configuration.xml b/configs/msmsteppe/audio_policy_configuration.xml
index b9110a0..953dc4a 100644
--- a/configs/msmsteppe/audio_policy_configuration.xml
+++ b/configs/msmsteppe/audio_policy_configuration.xml
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink">
diff --git a/configs/msmsteppe_au/audio_policy_configuration.xml b/configs/msmsteppe_au/audio_policy_configuration.xml
index d575c61..7229118 100644
--- a/configs/msmsteppe_au/audio_policy_configuration.xml
+++ b/configs/msmsteppe_au/audio_policy_configuration.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!-- Copyright (c) 2016-2019, The Linux Foundation. All rights reserved
+<!-- Copyright (c) 2016-2020, The Linux Foundation. All rights reserved
Not a Contribution.
-->
<!-- Copyright (C) 2015 The Android Open Source Project
@@ -195,7 +195,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink" maxOpenCount="2" maxActiveCount="2">
diff --git a/configs/sdm660/sdm660.mk b/configs/sdm660/sdm660.mk
index c5a410e..6e0d066 100644
--- a/configs/sdm660/sdm660.mk
+++ b/configs/sdm660/sdm660.mk
@@ -68,6 +68,14 @@
AUDIO_FEATURE_ENABLED_GEF_SUPPORT := true
AUDIO_FEATURE_ENABLED_RAS := true
AUDIO_FEATURE_ENABLED_SND_MONITOR := true
+AUDIO_FEATURE_ENABLED_SVA_MULTI_STAGE := true
+
+ifeq ($(TARGET_KERNEL_VERSION), 4.4)
+ AUDIO_FEATURE_ENABLED_DLKM := false
+else
+ AUDIO_FEATURE_ENABLED_DLKM := true
+endif
+
##AUDIO_FEATURE_FLAGS
#Audio Specific device overlays
diff --git a/configs/sdm710/audio_policy_configuration.xml b/configs/sdm710/audio_policy_configuration.xml
index 561ab14..c411b03 100644
--- a/configs/sdm710/audio_policy_configuration.xml
+++ b/configs/sdm710/audio_policy_configuration.xml
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="incall_music_uplink" role="source"
flags="AUDIO_OUTPUT_FLAG_INCALL_MUSIC">
diff --git a/configs/sdm845/audio_policy_configuration.xml b/configs/sdm845/audio_policy_configuration.xml
index f6a842c..5ece1f8 100644
--- a/configs/sdm845/audio_policy_configuration.xml
+++ b/configs/sdm845/audio_policy_configuration.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!-- Copyright (c) 2016-2019, The Linux Foundation. All rights reserved
+<!-- Copyright (c) 2016-2020, The Linux Foundation. All rights reserved
Not a Contribution.
-->
<!-- Copyright (C) 2015 The Android Open Source Project
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
diff --git a/configs/trinket/audio_policy_configuration.xml b/configs/trinket/audio_policy_configuration.xml
index a949520..ecf84d3 100644
--- a/configs/trinket/audio_policy_configuration.xml
+++ b/configs/trinket/audio_policy_configuration.xml
@@ -159,7 +159,7 @@
<mixPort name="voip_rx" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT|AUDIO_OUTPUT_FLAG_VOIP_RX">
<profile name="" format="AUDIO_FORMAT_PCM_16_BIT"
- samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO"/>
+ samplingRates="8000,16000,32000,48000" channelMasks="AUDIO_CHANNEL_OUT_MONO,AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="primary input" role="sink">
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index 979781e..0cd849a 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -1291,6 +1291,31 @@
snd_device = usecase->in_snd_device;
else
snd_device = usecase->out_snd_device;
+
+ /* disable island and power mode on supported device for voice call */
+ if (usecase->type == VOICE_CALL) {
+ if (usecase->in_snd_device != SND_DEVICE_NONE) {
+ if (platform_get_island_cfg_on_device(adev->platform, usecase->in_snd_device) &&
+ platform_get_power_mode_on_device(adev->platform, usecase->in_snd_device)) {
+ platform_set_island_cfg_on_device(adev, usecase->in_snd_device, false);
+ platform_set_power_mode_on_device(adev, usecase->in_snd_device, false);
+ platform_reset_island_power_status(adev->platform, usecase->in_snd_device);
+ ALOGD("%s: disable island cfg and power mode in voice tx path",
+ __func__);
+ }
+ }
+ if (usecase->out_snd_device != SND_DEVICE_NONE) {
+ if (platform_get_island_cfg_on_device(adev->platform, usecase->out_snd_device) &&
+ platform_get_power_mode_on_device(adev->platform, usecase->out_snd_device)) {
+ platform_set_island_cfg_on_device(adev, usecase->out_snd_device, false);
+ platform_set_power_mode_on_device(adev, usecase->out_snd_device, false);
+ platform_reset_island_power_status(adev->platform, usecase->out_snd_device);
+ ALOGD("%s: disable island cfg and power mode in voice rx path",
+ __func__);
+ }
+ }
+ }
+
// we shouldn't truncate mixer_path
ALOGW_IF(strlcpy(mixer_path, use_case_table[usecase->id], sizeof(mixer_path))
>= sizeof(mixer_path), "%s: truncation on mixer path", __func__);
@@ -1385,6 +1410,14 @@
} else {
ALOGD("%s: snd_device(%d: %s)", __func__, snd_device, device_name);
+ /* enable island and power mode on supported device */
+ if (platform_get_island_cfg_on_device(adev->platform, snd_device) &&
+ platform_get_power_mode_on_device(adev->platform, snd_device)) {
+ platform_set_island_cfg_on_device(adev, snd_device, true);
+ platform_set_power_mode_on_device(adev, snd_device, true);
+ ALOGD("%s: enable island cfg and power mode on: %s",
+ __func__, device_name);
+ }
if ((SND_DEVICE_OUT_BT_A2DP == snd_device) &&
(audio_extn_a2dp_start_playback() < 0)) {
@@ -1707,6 +1740,20 @@
force_routing = true;
force_restart_session = true;
}
+
+ /*
+ * Island cfg and power mode config needs to set before AFE port start.
+ * Set force routing in case of voice device was enable before.
+ */
+ if (uc_info->type == VOICE_CALL &&
+ voice_extn_is_voice_power_mode_supported() &&
+ platform_check_and_update_island_power_status(adev->platform,
+ uc_info,
+ snd_device)) {
+ force_routing = true;
+ ALOGD("%s:becf: force routing %d for power mode supported device",
+ __func__, force_routing);
+ }
ALOGD("%s:becf: force routing %d", __func__, force_routing);
/* Disable all the usecases on the shared backend other than the
@@ -1851,6 +1898,22 @@
*/
if (uc_info->type == PCM_CAPTURE)
backend_check_cond = is_codec_backend_in_device_type(&uc_info->device_list);
+
+ /*
+ * Island cfg and power mode config needs to set before AFE port start.
+ * Set force routing in case of voice device was enable before.
+ */
+
+ if (uc_info->type == VOICE_CALL &&
+ voice_extn_is_voice_power_mode_supported() &&
+ platform_check_and_update_island_power_status(adev->platform,
+ uc_info,
+ snd_device)) {
+ force_routing = true;
+ ALOGD("%s:becf: force routing %d for power mode supported device",
+ __func__, force_routing);
+ }
+
/*
* This function is to make sure that all the active capture usecases
* are always routed to the same input sound device.
@@ -4305,28 +4368,34 @@
static uint64_t get_actual_pcm_frames_rendered(struct stream_out *out, struct timespec *timestamp)
{
uint64_t actual_frames_rendered = 0;
- size_t kernel_buffer_size = out->compr_config.fragment_size * out->compr_config.fragments;
+ uint64_t written_frames = 0;
+ uint64_t kernel_frames = 0;
+ uint64_t dsp_frames = 0;
+ uint64_t signed_frames = 0;
+ size_t kernel_buffer_size = 0;
/* This adjustment accounts for buffering after app processor.
* It is based on estimated DSP latency per use case, rather than exact.
*/
pthread_mutex_lock(&adev->lock);
- int64_t platform_latency = platform_render_latency(out->dev, out->usecase) *
- out->sample_rate / 1000000LL;
+ dsp_frames = platform_render_latency(out->dev, out->usecase) *
+ out->sample_rate / 1000000LL;
pthread_mutex_unlock(&adev->lock);
pthread_mutex_lock(&out->position_query_lock);
+ written_frames = out->written /
+ (audio_bytes_per_sample(out->hal_ip_format) * popcount(out->channel_mask));
+
/* not querying actual state of buffering in kernel as it would involve an ioctl call
* which then needs protection, this causes delay in TS query for pcm_offload usecase
* hence only estimate.
*/
- uint64_t signed_frames = 0;
- if (out->written >= kernel_buffer_size)
- signed_frames = out->written - kernel_buffer_size;
+ kernel_buffer_size = out->compr_config.fragment_size * out->compr_config.fragments;
+ kernel_frames = kernel_buffer_size /
+ (audio_bytes_per_sample(out->hal_op_format) * popcount(out->channel_mask));
- signed_frames = signed_frames / (audio_bytes_per_sample(out->format) * popcount(out->channel_mask));
- if (signed_frames >= platform_latency)
- signed_frames = signed_frames - platform_latency;
+ if (written_frames >= (kernel_frames + dsp_frames))
+ signed_frames = written_frames - kernel_frames - dsp_frames;
if (signed_frames > 0) {
actual_frames_rendered = signed_frames;
@@ -4337,11 +4406,8 @@
}
pthread_mutex_unlock(&out->position_query_lock);
- ALOGVV("%s signed frames %lld out_written %lld kernel_buffer_size %d"
- "bytes/sample %zu channel count %d", __func__, signed_frames,
- (long long int)out->written, (int)kernel_buffer_size,
- audio_bytes_per_sample(out->compr_config.codec->format),
- popcount(out->channel_mask));
+ ALOGVV("%s signed frames %lld written frames %lld kernel frames %lld dsp frames %lld",
+ __func__, signed_frames, written_frames, kernel_frames, dsp_frames);
return actual_frames_rendered;
}
@@ -7765,7 +7831,7 @@
if (out->sample_rate == 8000 || out->sample_rate == 16000 ||
out->sample_rate == 32000 || out->sample_rate == 48000) {
out->channel_mask = audio_extn_utils_is_vendor_enhanced_fwk() ?
- AUDIO_CHANNEL_OUT_MONO : AUDIO_CHANNEL_OUT_STEREO;
+ config->channel_mask : AUDIO_CHANNEL_OUT_STEREO;
out->usecase = USECASE_AUDIO_PLAYBACK_VOIP;
out->format = AUDIO_FORMAT_PCM_16_BIT;
out->volume_l = INVALID_OUT_VOLUME;
diff --git a/hal/msm8974/platform.c b/hal/msm8974/platform.c
index a80c5f8..cb43dfb 100644
--- a/hal/msm8974/platform.c
+++ b/hal/msm8974/platform.c
@@ -386,6 +386,8 @@
bool is_multiple_sample_rate_combo_supported;
struct listnode custom_mtmx_params_list;
struct listnode custom_mtmx_in_params_list;
+ struct power_mode_cfg power_mode_cfg[SND_DEVICE_MAX];
+ struct island_cfg island_cfg[SND_DEVICE_MAX];
};
struct spkr_device_chmap {
@@ -2226,6 +2228,11 @@
operator_specific_device_table[dev] = NULL;
external_specific_device_table[dev] = NULL;
snd_device_delay_ms[dev] = 0;
+ /* Init island cfg and power mode */
+ my_data->island_cfg[dev].mixer_ctl = NULL;
+ my_data->power_mode_cfg[dev].mixer_ctl = NULL;
+ my_data->island_cfg[dev].enable = false;
+ my_data->power_mode_cfg[dev].enable = false;
}
for (dev = 0; dev < SND_DEVICE_MAX; dev++) {
backend_bit_width_table[dev] = CODEC_BACKEND_DEFAULT_BIT_WIDTH;
@@ -9028,6 +9035,154 @@
return backend_idx;
}
+bool platform_get_power_mode_on_device(void *platform, snd_device_t snd_device) {
+ struct platform_data *my_data = (struct platform_data *)platform;
+
+ ALOGD("%s:power mode status on snd_device = (%s %d)", __func__,
+ platform_get_snd_device_name(snd_device),
+ my_data->power_mode_cfg[snd_device].enable);
+ return my_data->power_mode_cfg[snd_device].enable;
+
+}
+
+bool platform_get_island_cfg_on_device(void *platform, snd_device_t snd_device) {
+ struct platform_data *my_data = (struct platform_data *)platform;
+
+ ALOGD("%s:island cfg status on snd_device = (%s %d)", __func__,
+ platform_get_snd_device_name(snd_device),
+ my_data->island_cfg[snd_device].enable);
+ return my_data->island_cfg[snd_device].enable;
+}
+
+int platform_set_power_mode_on_device(struct audio_device* adev,
+ snd_device_t snd_device,
+ bool enable)
+{
+ int ret = 0;
+ struct mixer_ctl *ctl;
+ struct platform_data *my_data = (struct platform_data *)adev->platform;
+
+ ctl = mixer_get_ctl_by_name(adev->mixer,
+ my_data->power_mode_cfg[snd_device].mixer_ctl);
+
+ if (ctl) {
+ ALOGD("%s:set power mode to %s",
+ __func__, (enable == true) ? "true" : "false");
+ mixer_ctl_set_value(ctl, 0, (int)enable);
+ } else {
+ ALOGE("%s:Could not get ctl for power mode mixer", __func__);
+ ret = -EINVAL;
+ goto error;
+ }
+ return ret;
+
+error:
+ my_data->power_mode_cfg[snd_device].enable = false;
+ my_data->power_mode_cfg[snd_device].mixer_ctl = NULL;
+ return ret;
+}
+
+int platform_set_island_cfg_on_device(struct audio_device* adev,
+ snd_device_t snd_device,
+ bool enable)
+{
+ int ret = 0;
+ struct mixer_ctl *ctl;
+ struct platform_data *my_data = (struct platform_data *)adev->platform;
+
+ ctl = mixer_get_ctl_by_name(adev->mixer,
+ my_data->island_cfg[snd_device].mixer_ctl);
+
+ if (ctl) {
+ ALOGD("%s:set island cfg to %s",
+ __func__, (enable == true) ? "true" : "false");
+ mixer_ctl_set_value(ctl, 0, (int)enable);
+ } else {
+ ALOGE("%s:Could not get ctl for island cfg mixer", __func__);
+ return -EINVAL;
+ goto error;
+ }
+ return ret;
+
+error:
+ my_data->island_cfg[snd_device].enable = false;
+ my_data->island_cfg[snd_device].mixer_ctl = NULL;
+ return ret;
+}
+
+char * platform_update_power_mode_mixer_ctrl(snd_device_t snd_device)
+{
+ char mixer_ctl[MIXER_PATH_MAX_LENGTH];
+ char *power_mode_mixer_ctrl = NULL;
+ char * be_itf = hw_interface_table[snd_device];
+
+ if (be_itf != NULL) {
+ snprintf(mixer_ctl, sizeof(mixer_ctl),
+ "%s Power Mode", be_itf);
+ power_mode_mixer_ctrl = strdup(mixer_ctl);
+ ALOGD("%s: power mode mixer ctrl %s\n",
+ __func__, power_mode_mixer_ctrl);
+ }
+
+ return power_mode_mixer_ctrl;
+}
+
+char * platform_update_island_cfg_mixer_ctrl(snd_device_t snd_device)
+{
+ char mixer_ctl[MIXER_PATH_MAX_LENGTH];
+ char *island_cfg_mixer_ctrl = NULL;
+ char * be_itf = hw_interface_table[snd_device];
+
+ if (be_itf != NULL) {
+ snprintf(mixer_ctl, sizeof(mixer_ctl),
+ "%s Island Config", be_itf);
+ island_cfg_mixer_ctrl = strdup(mixer_ctl);
+ ALOGD("%s: island cfg mixer ctrl %s\n",
+ __func__, island_cfg_mixer_ctrl);
+ }
+
+ return island_cfg_mixer_ctrl;
+}
+
+bool platform_check_and_update_island_power_status(void *platform,
+ struct audio_usecase* usecase,
+ snd_device_t snd_device)
+{
+ bool ret = false;
+ struct platform_data *my_data = (struct platform_data *)platform;
+
+ if (compare_device_type(&usecase->device_list, AUDIO_DEVICE_OUT_EARPIECE) ||
+ compare_device_type(&usecase->device_list, AUDIO_DEVICE_OUT_WIRED_HEADSET) ||
+ compare_device_type(&usecase->device_list, AUDIO_DEVICE_OUT_WIRED_HEADPHONE)) {
+ if (snd_device >= SND_DEVICE_MIN && snd_device < SND_DEVICE_MAX) {
+ /* update island and power mode in current device */
+ my_data->island_cfg[snd_device].mixer_ctl =
+ platform_update_island_cfg_mixer_ctrl(snd_device);
+ my_data->power_mode_cfg[snd_device].mixer_ctl =
+ platform_update_power_mode_mixer_ctrl(snd_device);
+ if (my_data->island_cfg[snd_device].mixer_ctl != NULL &&
+ my_data->power_mode_cfg[snd_device].mixer_ctl != NULL) {
+ /* enable island and power mode in current device */
+ my_data->island_cfg[snd_device].enable = true;
+ my_data->power_mode_cfg[snd_device].enable = true;
+ ret = true;
+ }
+ }
+ }
+
+ return ret;
+}
+
+void platform_reset_island_power_status(void *platform, snd_device_t snd_device)
+{
+ struct platform_data *my_data = (struct platform_data *)platform;
+
+ my_data->island_cfg[snd_device].mixer_ctl = NULL;
+ my_data->power_mode_cfg[snd_device].mixer_ctl = NULL;
+ my_data->island_cfg[snd_device].enable = false;
+ my_data->power_mode_cfg[snd_device].enable = false;
+}
+
/*
* configures afe with bit width and Sample Rate
*/
diff --git a/hal/platform_api.h b/hal/platform_api.h
index 9a50946..c3efd3c 100644
--- a/hal/platform_api.h
+++ b/hal/platform_api.h
@@ -423,5 +423,14 @@
void platform_set_audio_source_delay(audio_source_t audio_source, int delay_ms);
int platform_get_audio_source_index(const char *audio_source_name);
-
+bool platform_check_and_update_island_power_status(void *platform,
+ struct audio_usecase* usecase,
+ snd_device_t snd_device);
+bool platform_get_power_mode_on_device(void *platform, snd_device_t snd_device);
+bool platform_get_island_cfg_on_device(void *platform, snd_device_t snd_device);
+int platform_set_power_mode_on_device(struct audio_device* adev, snd_device_t snd_device,
+ bool enable);
+int platform_set_island_cfg_on_device(struct audio_device* adev, snd_device_t snd_device,
+ bool enable);
+void platform_reset_island_power_status(void *platform, snd_device_t snd_device);
#endif // AUDIO_PLATFORM_API_H
diff --git a/hal/voice.h b/hal/voice.h
index 94782b8..1f0978a 100644
--- a/hal/voice.h
+++ b/hal/voice.h
@@ -63,6 +63,16 @@
bool in_call;
};
+struct power_mode_cfg {
+ bool enable;
+ char *mixer_ctl;
+};
+
+struct island_cfg {
+ bool enable;
+ char *mixer_ctl;
+};
+
enum {
INCALL_REC_NONE = -1,
INCALL_REC_UPLINK,
diff --git a/hal/voice_extn/voice_extn.c b/hal/voice_extn/voice_extn.c
index c2e419a..1882f11 100644
--- a/hal/voice_extn/voice_extn.c
+++ b/hal/voice_extn/voice_extn.c
@@ -88,6 +88,7 @@
static bool voice_extn_dynamic_ecns_feature_enabled = false;
static bool voice_extn_incall_music_enabled = false;
static bool voice_extn_multi_session_enabled = false;
+static bool voice_extn_power_mode_enabled = false;
int voice_extn_is_call_state_active(struct audio_device *adev, bool *is_call_active);
@@ -456,6 +457,18 @@
return voice_extn_multi_session_enabled;
}
+void voice_power_mode_feature_init(bool is_feature_enabled)
+{
+ voice_extn_power_mode_enabled = is_feature_enabled;
+ ALOGV("%s:: ---- Feature POWER MODE is %s ----", __func__,
+ is_feature_enabled ? "ENABLED" : "NOT ENABLED");
+}
+
+bool voice_extn_is_voice_power_mode_supported()
+{
+ return voice_extn_power_mode_enabled;
+}
+
void voice_extn_feature_init()
{
// Register feature function here
@@ -472,6 +485,9 @@
multi_voice_session_feature_init(
property_get_bool("vendor.audio.feature.multi_voice_session.enable",
false));
+ voice_power_mode_feature_init(
+ property_get_bool("vendor.audio.feature.power_mode.enable",
+ false));
}
void voice_extn_init(struct audio_device *adev)
diff --git a/hal/voice_extn/voice_extn.h b/hal/voice_extn/voice_extn.h
index b2aab7e..09d5414 100644
--- a/hal/voice_extn/voice_extn.h
+++ b/hal/voice_extn/voice_extn.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013-2014, 2016-2019, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2013-2014, 2016-2020, The Linux Foundation. All rights reserved.
* Not a contribution.
*
* Copyright (C) 2013 The Android Open Source Project
@@ -86,6 +86,8 @@
bool voice_extn_is_compress_voip_supported();
void multi_voice_session_feature_init(bool is_feature_enabled);
bool voice_extn_is_multi_session_supported();
+void voice_power_mode_feature_init(bool is_feature_enabled);
+bool voice_extn_is_voice_power_mode_supported();
#endif //VOICE_EXTN_H
diff --git a/post_proc/Android.mk b/post_proc/Android.mk
index 785470b..6f0be47 100644
--- a/post_proc/Android.mk
+++ b/post_proc/Android.mk
@@ -23,6 +23,10 @@
LOCAL_CFLAGS += -DAFE_PROXY_ENABLED
endif
+ifeq ($(strip $(AUDIO_FEATURE_ENABLED_GKI)),true)
+ LOCAL_CFLAGS += -DAUDIO_GKI_ENABLED
+endif
+
LOCAL_SRC_FILES:= \
bundle.c \
equalizer.c \
diff --git a/post_proc/effect_api.c b/post_proc/effect_api.c
index a07de20..93f2329 100644
--- a/post_proc/effect_api.c
+++ b/post_proc/effect_api.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013-2015, 2019 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2013-2015, 2019-2020 The Linux Foundation. All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -175,6 +175,19 @@
bassboost->mode = mode;
}
+static inline long get_config_set_param()
+{
+ long config_param = 0;
+
+#ifdef AUDIO_GKI_ENABLED
+ config_param = AUDIO_EFFECTS_CONFIG_SET;
+#else
+ config_param = CONFIG_SET;
+#endif
+
+ return config_param;
+}
+
static int bassboost_send_params(eff_mode_t mode, void *ctl,
struct bass_boost_params *bassboost,
unsigned param_send_flags)
@@ -188,7 +201,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_BASSBOOST_ENABLE_FLAG) {
*p_param_values++ = BASS_BOOST_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = BASS_BOOST_ENABLE_PARAM_LEN;
*p_param_values++ = bassboost->enable_flag;
@@ -196,7 +209,7 @@
}
if (param_send_flags & OFFLOAD_SEND_BASSBOOST_STRENGTH) {
*p_param_values++ = BASS_BOOST_STRENGTH;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = BASS_BOOST_STRENGTH_PARAM_LEN;
*p_param_values++ = bassboost->strength;
@@ -204,7 +217,7 @@
}
if (param_send_flags & OFFLOAD_SEND_BASSBOOST_MODE) {
*p_param_values++ = BASS_BOOST_MODE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = BASS_BOOST_MODE_PARAM_LEN;
*p_param_values++ = bassboost->mode;
@@ -275,7 +288,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_PBE_ENABLE_FLAG) {
*p_param_values++ = PBE_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = PBE_ENABLE_PARAM_LEN;
*p_param_values++ = pbe->enable_flag;
@@ -283,7 +296,7 @@
}
if (param_send_flags & OFFLOAD_SEND_PBE_CONFIG) {
*p_param_values++ = PBE_CONFIG;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = pbe->cfg_len;
*p_param_values++ = pbe->config.real_bass_mix;
@@ -414,7 +427,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_VIRTUALIZER_ENABLE_FLAG) {
*p_param_values++ = VIRTUALIZER_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = VIRTUALIZER_ENABLE_PARAM_LEN;
*p_param_values++ = virtualizer->enable_flag;
@@ -422,7 +435,7 @@
}
if (param_send_flags & OFFLOAD_SEND_VIRTUALIZER_STRENGTH) {
*p_param_values++ = VIRTUALIZER_STRENGTH;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = VIRTUALIZER_STRENGTH_PARAM_LEN;
*p_param_values++ = virtualizer->strength;
@@ -430,7 +443,7 @@
}
if (param_send_flags & OFFLOAD_SEND_VIRTUALIZER_OUT_TYPE) {
*p_param_values++ = VIRTUALIZER_OUT_TYPE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = VIRTUALIZER_OUT_TYPE_PARAM_LEN;
*p_param_values++ = virtualizer->out_type;
@@ -438,7 +451,7 @@
}
if (param_send_flags & OFFLOAD_SEND_VIRTUALIZER_GAIN_ADJUST) {
*p_param_values++ = VIRTUALIZER_GAIN_ADJUST;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = VIRTUALIZER_GAIN_ADJUST_PARAM_LEN;
*p_param_values++ = virtualizer->gain_adjust;
@@ -540,7 +553,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_EQ_ENABLE_FLAG) {
*p_param_values++ = EQ_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = EQ_ENABLE_PARAM_LEN;
*p_param_values++ = eq->enable_flag;
@@ -548,7 +561,7 @@
}
if (param_send_flags & OFFLOAD_SEND_EQ_PRESET) {
*p_param_values++ = EQ_CONFIG;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = EQ_CONFIG_PARAM_LEN;
*p_param_values++ = eq->config.eq_pregain;
@@ -559,7 +572,7 @@
}
if (param_send_flags & OFFLOAD_SEND_EQ_BANDS_LEVEL) {
*p_param_values++ = EQ_CONFIG;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = EQ_CONFIG_PARAM_LEN +
eq->config.num_bands * EQ_CONFIG_PER_BAND_PARAM_LEN;
@@ -724,7 +737,7 @@
if (param_send_flags & OFFLOAD_SEND_REVERB_ENABLE_FLAG) {
*p_param_values++ = REVERB_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_ENABLE_PARAM_LEN;
*p_param_values++ = reverb->enable_flag;
@@ -732,7 +745,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_MODE) {
*p_param_values++ = REVERB_MODE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_MODE_PARAM_LEN;
*p_param_values++ = reverb->mode;
@@ -740,7 +753,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_PRESET) {
*p_param_values++ = REVERB_PRESET;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_PRESET_PARAM_LEN;
*p_param_values++ = reverb->preset;
@@ -748,7 +761,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_WET_MIX) {
*p_param_values++ = REVERB_WET_MIX;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_WET_MIX_PARAM_LEN;
*p_param_values++ = reverb->wet_mix;
@@ -756,7 +769,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_GAIN_ADJUST) {
*p_param_values++ = REVERB_GAIN_ADJUST;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_GAIN_ADJUST_PARAM_LEN;
*p_param_values++ = reverb->gain_adjust;
@@ -764,7 +777,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_ROOM_LEVEL) {
*p_param_values++ = REVERB_ROOM_LEVEL;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_ROOM_LEVEL_PARAM_LEN;
*p_param_values++ = reverb->room_level;
@@ -772,7 +785,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_ROOM_HF_LEVEL) {
*p_param_values++ = REVERB_ROOM_HF_LEVEL;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_ROOM_HF_LEVEL_PARAM_LEN;
*p_param_values++ = reverb->room_hf_level;
@@ -780,7 +793,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_DECAY_TIME) {
*p_param_values++ = REVERB_DECAY_TIME;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_DECAY_TIME_PARAM_LEN;
*p_param_values++ = reverb->decay_time;
@@ -788,7 +801,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_DECAY_HF_RATIO) {
*p_param_values++ = REVERB_DECAY_HF_RATIO;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_DECAY_HF_RATIO_PARAM_LEN;
*p_param_values++ = reverb->decay_hf_ratio;
@@ -796,7 +809,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_REFLECTIONS_LEVEL) {
*p_param_values++ = REVERB_REFLECTIONS_LEVEL;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_REFLECTIONS_LEVEL_PARAM_LEN;
*p_param_values++ = reverb->reflections_level;
@@ -804,7 +817,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_REFLECTIONS_DELAY) {
*p_param_values++ = REVERB_REFLECTIONS_DELAY;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_REFLECTIONS_DELAY_PARAM_LEN;
*p_param_values++ = reverb->reflections_delay;
@@ -812,7 +825,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_LEVEL) {
*p_param_values++ = REVERB_LEVEL;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_LEVEL_PARAM_LEN;
*p_param_values++ = reverb->level;
@@ -820,7 +833,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_DELAY) {
*p_param_values++ = REVERB_DELAY;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_DELAY_PARAM_LEN;
*p_param_values++ = reverb->delay;
@@ -828,7 +841,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_DIFFUSION) {
*p_param_values++ = REVERB_DIFFUSION;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_DIFFUSION_PARAM_LEN;
*p_param_values++ = reverb->diffusion;
@@ -836,7 +849,7 @@
}
if (param_send_flags & OFFLOAD_SEND_REVERB_DENSITY) {
*p_param_values++ = REVERB_DENSITY;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = REVERB_DENSITY_PARAM_LEN;
*p_param_values++ = reverb->density;
@@ -903,7 +916,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_SOFT_VOLUME_ENABLE_FLAG) {
*p_param_values++ = SOFT_VOLUME_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME_ENABLE_PARAM_LEN;
*p_param_values++ = vol.enable_flag;
@@ -911,7 +924,7 @@
}
if (param_send_flags & OFFLOAD_SEND_SOFT_VOLUME_GAIN_MASTER) {
*p_param_values++ = SOFT_VOLUME_GAIN_MASTER;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME_GAIN_MASTER_PARAM_LEN;
*p_param_values++ = vol.master_gain;
@@ -919,7 +932,7 @@
}
if (param_send_flags & OFFLOAD_SEND_SOFT_VOLUME_GAIN_2CH) {
*p_param_values++ = SOFT_VOLUME_GAIN_2CH;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME_GAIN_2CH_PARAM_LEN;
*p_param_values++ = vol.left_gain;
@@ -968,7 +981,7 @@
*p_param_values++ = 0; /* num of commands*/
if (param_send_flags & OFFLOAD_SEND_TRANSITION_SOFT_VOLUME_ENABLE_FLAG) {
*p_param_values++ = SOFT_VOLUME2_ENABLE;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME2_ENABLE_PARAM_LEN;
*p_param_values++ = vol.enable_flag;
@@ -976,7 +989,7 @@
}
if (param_send_flags & OFFLOAD_SEND_TRANSITION_SOFT_VOLUME_GAIN_MASTER) {
*p_param_values++ = SOFT_VOLUME2_GAIN_MASTER;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME2_GAIN_MASTER_PARAM_LEN;
*p_param_values++ = vol.master_gain;
@@ -984,7 +997,7 @@
}
if (param_send_flags & OFFLOAD_SEND_TRANSITION_SOFT_VOLUME_GAIN_2CH) {
*p_param_values++ = SOFT_VOLUME2_GAIN_2CH;
- *p_param_values++ = CONFIG_SET;
+ *p_param_values++ = get_config_set_param();
*p_param_values++ = 0; /* start offset if param size if greater than 128 */
*p_param_values++ = SOFT_VOLUME2_GAIN_2CH_PARAM_LEN;
*p_param_values++ = vol.left_gain;