summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarsinga Rao Chella <nrchella@codeaurora.org>2015-01-22 09:41:37 -0800
committerArne Coucheron <arco68@gmail.com>2019-09-28 00:23:56 +0200
commit86c1e6caa6b0040afe1c71553b646346c5e4bed3 (patch)
tree7807729b1c8d03f979f6d52e8002043b23ae61de
parenta1ee938b2a43427836970a226fa4beb4711c716b (diff)
downloadhardware_qcom_audio-86c1e6caa6b0040afe1c71553b646346c5e4bed3.tar.gz
hardware_qcom_audio-86c1e6caa6b0040afe1c71553b646346c5e4bed3.tar.bz2
hardware_qcom_audio-86c1e6caa6b0040afe1c71553b646346c5e4bed3.zip
hal: Fix routing issue for voip use case
During device switch, all the use cases on a shared backend will be derouted before disabling the current device and rerouted after enabling the new sound device. Rerouting of voip use cases was not taken care properly which is fixed now. Change-Id: I394c0d34fe36d42ce615414ea0524a58c10a5f79
-rw-r--r--hal/audio_hw.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index 010a3252..87a34246 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -398,8 +398,7 @@ static int enable_audio_route_for_voice_usecases(struct audio_device *adev,
specified usecase to new snd devices */
list_for_each(node, &adev->usecase_list) {
usecase = node_to_item(node, struct audio_usecase, list);
- if ((usecase->type == VOICE_CALL || usecase->type == VOIP_CALL) &&
- (usecase != uc_info))
+ if ((usecase->type == VOICE_CALL) && (usecase != uc_info))
enable_audio_route(adev, usecase);
}
return 0;
@@ -659,7 +658,7 @@ static void check_usecases_codec_backend(struct audio_device *adev,
/* Update the out_snd_device only before enabling the audio route */
if (switch_device[usecase->id] ) {
usecase->out_snd_device = snd_device;
- if (usecase->type != VOICE_CALL && usecase->type != VOIP_CALL)
+ if (usecase->type != VOICE_CALL)
enable_audio_route(adev, usecase);
}
}
@@ -727,7 +726,7 @@ static void check_and_route_capture_usecases(struct audio_device *adev,
/* Update the in_snd_device only before enabling the audio route */
if (switch_device[usecase->id] ) {
usecase->in_snd_device = snd_device;
- if (usecase->type != VOICE_CALL && usecase->type != VOIP_CALL)
+ if (usecase->type != VOICE_CALL)
enable_audio_route(adev, usecase);
}
}