summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMisael Lopez Cruz <misael.lopez@ti.com>2014-11-25 20:56:23 -0600
committerMisael Lopez Cruz <misael.lopez@ti.com>2014-11-26 03:06:17 -0600
commit722a512d3b92a94c46c856592ccc7015d2a6fd06 (patch)
tree756c408a044b98cd2ecb6b33ce39054a51763e8d
parent46e3e4351aeb553f196d992fbf4b3738392cd219 (diff)
downloadjacinto6evm-722a512d3b92a94c46c856592ccc7015d2a6fd06.tar.gz
audio: Legacy: Remove BT SCO workaround
WiLink 8 is now able to provide the PCM clocks until the voice call is completely terminated, so there is no risk of blocking read() and write() calls anymore. The workaround is no longer needed, so it is removed. Change-Id: Idb9c4d9dc9e2940c9ce6a9f49448a2fa9ad76ae2 Signed-off-by: Misael Lopez Cruz <misael.lopez@ti.com>
-rw-r--r--audio/legacy/audio_hw.c17
-rw-r--r--audio/mixer_paths.xml7
2 files changed, 1 insertions, 23 deletions
diff --git a/audio/legacy/audio_hw.c b/audio/legacy/audio_hw.c
index 6152035..fc81c03 100644
--- a/audio/legacy/audio_hw.c
+++ b/audio/legacy/audio_hw.c
@@ -565,9 +565,6 @@ static int enter_voice_call(struct j6_audio_device *adev)
ALOGI("enter_voice_call() entering bluetooth voice call");
- audio_route_apply_path(adev->route, "BT SCO Master");
- audio_route_update_mixer(adev->route);
-
/* Let the primary output switch to a dummy sink */
if (adev->out)
do_out_standby(adev->out);
@@ -580,7 +577,7 @@ static int enter_voice_call(struct j6_audio_device *adev)
ret = voice_stream_init(&voice->ul, adev->in_port, adev->bt_port, false);
if (ret) {
ALOGE("enter_voice_call() failed to init uplink %d", ret);
- goto err_ul_init;
+ return ret;
}
/* Downlink: BT (8kHz) -> HP/Spk (44.1kHz) */
@@ -620,9 +617,6 @@ static int enter_voice_call(struct j6_audio_device *adev)
voice_stream_exit(&voice->ul);
err_dl_init:
voice_stream_exit(&voice->dl);
- err_ul_init:
- audio_route_reset_path(adev->route, "BT SCO Master");
- audio_route_update_mixer(adev->route);
return ret;
}
@@ -638,15 +632,6 @@ static void leave_voice_call(struct j6_audio_device *adev)
adev->in_call = false;
- /*
- * The PCM ports used for Bluetooth are slaves and they can lose the
- * BCLK and FSYNC while still active. That leads to blocking read() and
- * write() calls, which is prevented by switching the clock source to
- * an internal one and explicitly stopping both ports for the new source
- * to take effect at kernel level
- */
- audio_route_reset_path(adev->route, "BT SCO Master");
- audio_route_update_mixer(adev->route);
if (ul->pcm_out)
pcm_stop(ul->pcm_out);
if (dl->pcm_in)
diff --git a/audio/mixer_paths.xml b/audio/mixer_paths.xml
index 09949fa..06419be 100644
--- a/audio/mixer_paths.xml
+++ b/audio/mixer_paths.xml
@@ -75,11 +75,4 @@
<ctl name="J3C Line Playback Switch" value="1" />
<ctl name="J3C PCM Playback Volume" value="127" />
-<!-- Bluetooth -->
-<ctl name="Bluetooth Mode" value="Slave" />
-
-<path name="BT SCO Master">
- <ctl name="Bluetooth Mode" value="Master" />
-</path>
-
</mixer>