hal: Add support for audio patches in HAL

Implement create_audio_patch and release_audio_patch
APIs for stream routing. Framework will
call these APIs instead of set_parameters to update
routing for a stream.
Increment HAL major version to 3.

Change-Id: Ife914f3277f2b3aa02e88e722d191c3f930e8095
diff --git a/hal/audio_extn/audio_extn.h b/hal/audio_extn/audio_extn.h
index c0e8cf4..986e24a 100644
--- a/hal/audio_extn/audio_extn.h
+++ b/hal/audio_extn/audio_extn.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2013-2019, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2013-2020, The Linux Foundation. All rights reserved.
  * Not a Contribution.
  *
  * Copyright (C) 2013 The Android Open Source Project
@@ -835,6 +835,8 @@
 int audio_extn_utils_get_vendor_enhanced_info();
 int audio_extn_utils_get_app_sample_rate_for_device(struct audio_device *adev,
                                     struct audio_usecase *usecase, int snd_device);
+int audio_extn_utils_hash_fn(void *key);
+bool audio_extn_utils_hash_eq(void *key1, void *key2);
 
 #ifdef DS2_DOLBY_DAP_ENABLED
 #define LIB_DS2_DAP_HAL "vendor/lib/libhwdaphal.so"
diff --git a/hal/audio_extn/utils.c b/hal/audio_extn/utils.c
index e729bfe..92887f0 100644
--- a/hal/audio_extn/utils.c
+++ b/hal/audio_extn/utils.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014-2019, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2014-2020, The Linux Foundation. All rights reserved.
  * Not a Contribution.
  *
  * Copyright (C) 2014 The Android Open Source Project
@@ -3140,3 +3140,13 @@
 
     return size;
 }
+
+int audio_extn_utils_hash_fn(void *key)
+{
+    return (int)key;
+}
+
+bool audio_extn_utils_hash_eq(void *key1, void *key2)
+{
+    return (key1 == key2);
+}