hal: Prevent de-routing in case the usecase doesn't share codec backend

During device selection for a usecase, other active usecases that share
the same codec backend are supposed to be switched to the new routing
device. Erroneously, during selection of the device for a capture usecase,
other active usecases are being de-routed irrespective of their backends
leading to unwarrented behavior e.g. voice call breakdown when a camcorder
usecase begins
Add a check to avoid disabling of usecases in above mentioned scenarios
if these do not share the same codec backend.

CRs-Fixed: 813744
Change-Id: Ic7a5b54155e70a55fd0b0b2d5ad7e380de564123
diff --git a/hal/audio_hw.c b/hal/audio_hw.c
index 528cbb9..799452b 100644
--- a/hal/audio_hw.c
+++ b/hal/audio_hw.c
@@ -546,7 +546,8 @@
         usecase = node_to_item(node, struct audio_usecase, list);
         if (usecase->type != PCM_PLAYBACK &&
                 usecase != uc_info &&
-                usecase->in_snd_device != snd_device) {
+                usecase->in_snd_device != snd_device &&
+                (usecase->devices & AUDIO_DEVICE_OUT_ALL_CODEC_BACKEND)) {
             ALOGV("%s: Usecase (%s) is active on (%s) - disabling ..",
                   __func__, use_case_table[usecase->id],
                   platform_get_snd_device_name(usecase->in_snd_device));