summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteve Kondik <steve@cyngn.com>2016-09-27 02:48:22 -0700
committerRashed Abdel-Tawab <rashed@linux.com>2017-12-28 03:09:30 +0200
commitf163245b5fa04ea772c0dd650c0c72681d3cc34e (patch)
tree3707cbcd7d7491ec62afc2d2e8c632f4655bea15
parent1bd798111d447eed1a979805be3122e804560425 (diff)
downloadandroid_hardware_qcom_audio-f163245b5fa04ea772c0dd650c0c72681d3cc34e.tar.gz
android_hardware_qcom_audio-f163245b5fa04ea772c0dd650c0c72681d3cc34e.tar.bz2
android_hardware_qcom_audio-f163245b5fa04ea772c0dd650c0c72681d3cc34e.zip
hal: Don't try to record using 3-mic unless we mean it
* The check here isn't sufficient for the case where SSR is disabled. The original code stubs out the relevant functions to all return 0, which actually satisfies the condition. The result is that all audio is sent to oblivion. Change-Id: I6a7e9bea3597c31543ba5637813784e3730b7a33
-rw-r--r--hal/audio_hw.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index 6c04558b..77050bab 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -6409,6 +6409,7 @@ static int adev_open_input_stream(struct audio_hw_device *dev,
in->config.channels = channel_count;
in->config.rate = config->sample_rate;
in->sample_rate = config->sample_rate;
+#ifdef SSR_ENABLED
} else if (!audio_extn_check_and_set_multichannel_usecase(adev,
in, config, &channel_mask_updated)) {
if (channel_mask_updated == true) {
@@ -6418,6 +6419,7 @@ static int adev_open_input_stream(struct audio_hw_device *dev,
goto err_open;
}
ALOGD("%s: created surround sound session succesfully",__func__);
+#endif
} else if (audio_extn_compr_cap_enabled() &&
audio_extn_compr_cap_format_supported(config->format) &&
(in->dev->mode != AUDIO_MODE_IN_COMMUNICATION)) {