ASoC: Fix WSA enumeration failure

In SDM450, WSA reset pin is shared for both WSA left
and right speakers. When reset pin toggled, both devices
enumerate and can be filled in any order in SWRM_DEV list.
But get_logical_address loops only once for first slave
addition and fails if the device entry is present at second
in SWRM_DEV list. Update logic of get_logical_address to
loop through max devices possible.

CRs-Fixed: 2196399
Change-Id: Ie31cea5a9b22e09a3c5c01e177cd1b78e8d2f28d
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
diff --git a/soc/swr-wcd-ctrl.h b/soc/swr-wcd-ctrl.h
index 52a60a3..fcf0652 100644
--- a/soc/swr-wcd-ctrl.h
+++ b/soc/swr-wcd-ctrl.h
@@ -1,4 +1,4 @@
-/* Copyright (c) 2015-2017, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2015-2018, The Linux Foundation. All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 and
@@ -23,6 +23,8 @@
 
 #define SWR_MSTR_PORT_LEN	8 /* Number of master ports */
 
+#define SWR_MAX_SLAVE_DEVICES 11
+
 #define SWRM_VERSION_1_0 0x01010000
 #define SWRM_VERSION_1_2 0x01030000
 #define SWRM_VERSION_1_3 0x01040000
@@ -94,6 +96,7 @@
 			void *data), void *swr_handle, int type);
 	int irq;
 	int version;
+	u32 num_dev;
 	int num_enum_slaves;
 	int slave_status;
 	struct swr_mstr_port *mstr_port;