From 1103db258f1864b96565c3789bd91bd4ffadc7a7 Mon Sep 17 00:00:00 2001 From: Thierry Bultel Date: Thu, 27 Dec 2018 17:27:01 +0100 Subject: bluetooth: fixes the cleanup at SCO hangup A bug in bluez-alsa was preventing to perform the PCM close, it was leading to a crash. There is a fix for this already, in bluez-alsa (as a patch in meta-agl-devel: https://gerrit.automotivelinux.org/gerrit/#/c/19365), that allows to get rid of the current limitation (4a had to be restarted between 2 phone calls). Now that the fix is available, (even if it is still no mainlined), it is now safe to perform the PCM close, without having a a crash. Change-Id: I6654e8e5b308985c4b0842001bc11eef22724deb Signed-off-by: Thierry Bultel --- plugins/alsa/alsa-utils-bypath.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'plugins') diff --git a/plugins/alsa/alsa-utils-bypath.c b/plugins/alsa/alsa-utils-bypath.c index 49f89e4..3a8afb7 100644 --- a/plugins/alsa/alsa-utils-bypath.c +++ b/plugins/alsa/alsa-utils-bypath.c @@ -96,12 +96,6 @@ PUBLIC void AlsaPcmCtlDelete(SoftMixerT* mixer, void * arg) { if (!pcmCtl->closeAtDeletion) goto done; - // TODO REMOVE THIS ONCE THE BUG IN BLUEZ-ALSA IS CORRECTED. Else Closing it make SIGSEGV - if (pcmCtl->isPcmPlug) { - AFB_ApiDebug(mixer->api, "%s: Wont' close '%s' PCM, it uses is a plug", __func__, pcmCtl->cid.cardid); - goto done; - } - AFB_ApiDebug(mixer->api, "%s: Closing %s", __func__, pcmCtl->cid.cardid); error = snd_pcm_close(pcmCtl->handle); if (error) { -- cgit 1.2.3-korg