hal: handle CLANG errors for Dolby

 - Update the BE IDs for headphone/headet
   as BE IDs are changed after indepdendent
   backend changes
 - Handle the CLANG errors for Dolby hal

Change-Id: Idcbbbdd0dfc769c46c2c23c32a0cd3143e6d9a83
diff --git a/hal/audio_extn/dolby.c b/hal/audio_extn/dolby.c
index f07c66a..b958bf6 100644
--- a/hal/audio_extn/dolby.c
+++ b/hal/audio_extn/dolby.c
@@ -484,9 +484,7 @@
 };
 
 int audio_extn_dap_hal_init(int snd_card) {
-    char c_dmid[128] = {0};
-    void *handle = NULL;
-    int i_dmid, ret = -EINVAL;
+    int ret = -EINVAL;
     dap_hal_device_be_id_map_t device_be_id_map;
 
     ALOGV("%s: opening DAP HAL lib\n", __func__);
@@ -532,9 +530,7 @@
 void audio_extn_dolby_ds2_set_endpoint(struct audio_device *adev) {
     struct listnode *node;
     struct audio_usecase *usecase;
-    struct mixer_ctl *ctl;
-    const char *mixer_ctl_name = "DS1 DAP Endpoint";
-    int endpoint = 0, ret;
+    int endpoint = 0;
     bool send = false;
 
     list_for_each(node, &adev->usecase_list) {
@@ -587,7 +583,7 @@
     return 0;
 }
 
-int audio_extn_dolby_set_dap_bypass(struct audio_device *adev, int state) {
+int audio_extn_dolby_set_dap_bypass(struct audio_device *adev __unused, int state) {
 
     ALOGV("%s: state %d", __func__, state);
     if (ds2extnmod.dap_hal_set_hw_info) {
@@ -599,12 +595,12 @@
     return 0;
 }
 
-void audio_extn_dolby_set_license(struct audio_device *adev)
+void audio_extn_dolby_set_license(struct audio_device *adev __unused)
 {
     int i_key=0;
     char c_key[128] = {0};
     char c_dmid[128] = {0};
-    int i_dmid, ret = -EINVAL;
+    int i_dmid;
     struct dolby_param_license dolby_license;
 
 #ifdef DOLBY_ACDB_LICENSE
@@ -631,7 +627,7 @@
 void audio_extn_ds2_set_parameters(struct audio_device *adev,
                                    struct str_parms *parms)
 {
-    int val, ret;
+    int ret;
     char value[32]={0};
 
     ret = str_parms_get_str(parms, AUDIO_PARAMETER_KEY_SND_CARD_STATUS, value,