hal: Modify A2DP output routing post releaseAudioPatch

HAL routes A2DP stream to speaker on releaseAudioPatch
from APM until the stream is put to standby from framework.
APM may releaseAudioPatch for an output where A2DP is
suspended and SCO is active leading to HAL switching all
streams to speaker. Fix this behavior by routing streams
to speaker only if both SCO and A2DP are not active.

Change-Id: Ib61b3477847656f978d81999bcb9f66d8b5d21d5
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index 41a3d5d..0c7532b 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -4205,7 +4205,8 @@
          */
         if ((out->devices & AUDIO_DEVICE_OUT_ALL_A2DP) &&
                 (val == AUDIO_DEVICE_NONE) &&
-                !audio_extn_a2dp_source_is_ready()) {
+                !audio_extn_a2dp_source_is_ready() &&
+                !adev->bt_sco_on) {
                 val = AUDIO_DEVICE_OUT_SPEAKER;
         }
         /*