Revert "audio: Fix incall device switch handling"
authorstenkinevgeniy <stenkinevgeniy@gmail.com>
Wed, 30 May 2018 15:43:14 +0000 (15:43 +0000)
committerJan Altensen <info@stricted.net>
Tue, 5 Feb 2019 19:11:30 +0000 (20:11 +0100)
This commit cause bug - no sound after end voice call when
using speaker. Sound come back after audioflinger send
standby and hal reenable speaker for new stream (usecase).

Reason - hal need reenable speaker (or other devices) for
other streams (usecases).

This reverts commit f33a728b205f7656ca6211a07e3dd69c623b75ca.

Change-Id: Icde4e83ab824008e931b681cdbb6e11d6a2a7aa5

audio/audio_hw.c

index 7bb02a0f812292ee24cdd6cc06972b6c21d07266..04955d6777e736cce5e984afc95c938db741d1bd 100644 (file)
@@ -1060,11 +1060,8 @@ static int select_devices(struct audio_device *adev,
         if (vc_usecase == NULL) {
             ALOGE("%s: Could not find the voice call usecase", __func__);
         } else {
-            ALOGV("%s: in call, reusing devices (rx: %s, tx: %s)", __func__,
-                  get_snd_device_display_name(vc_usecase->out_snd_device),
-                  get_snd_device_display_name(vc_usecase->in_snd_device));
-            usecase->devices = vc_usecase->devices;
-            return 0;
+            in_snd_device = vc_usecase->in_snd_device;
+            out_snd_device = vc_usecase->out_snd_device;
         }
     }