platform: msm8952: add smd interrupt address for msmgold
Address for smd interrupts has changed in msmgold. Add function
to maintain backward compatibility and new address for msmgold.
Change-Id: I4e9bccd98b3a80dc8f1796629d70a2335c0f054f
diff --git a/platform/msm8952/include/platform/iomap.h b/platform/msm8952/include/platform/iomap.h
index a7453d7..8643113 100644
--- a/platform/msm8952/include/platform/iomap.h
+++ b/platform/msm8952/include/platform/iomap.h
@@ -56,7 +56,9 @@
#define APPS_APCS_QTMR_AC_BASE (APPS_SS_BASE + 0x00020000)
#define APPS_APCS_F0_QTMR_V1_BASE (APPS_SS_BASE + 0x00021000)
#define QTMR_BASE APPS_APCS_F0_QTMR_V1_BASE
-#define APCS_ALIAS0_IPC_INTERRUPT (APPS_SS_BASE + 0x00111008)
+#define APCS_ALIAS1_IPC_INTERRUPT_1 (APPS_SS_BASE + 0x00011008)
+#define APCS_ALIAS0_IPC_INTERRUPT_2 (APPS_SS_BASE + 0x00111008)
+#define APCS_ALIAS0_IPC_INTERRUPT platform_get_apcs_ipc_base()
#define PERIPH_SS_BASE 0x07800000
diff --git a/platform/msm8952/platform.c b/platform/msm8952/platform.c
index 6e6ef21..1851c22 100644
--- a/platform/msm8952/platform.c
+++ b/platform/msm8952/platform.c
@@ -269,6 +269,14 @@
return APP_REGION_SIZE_8952;
}
+uint32_t platform_get_apcs_ipc_base()
+{
+ if(platform_is_msmgold())
+ return APCS_ALIAS1_IPC_INTERRUPT_1;
+ else
+ return APCS_ALIAS0_IPC_INTERRUPT_2;
+}
+
uint32_t platform_is_msm8976_v_1_1()
{
uint32_t soc_ver = board_soc_version();