msm: pm2: Call appropriate irq functions for 7k and 8625 targets
There is a difference between the 7k & 8625 targets interrupt
controllers. 7k & 8625 targets uses the VIC & QGIC controllers
respectively. Power driver uses these conrtoller API's to take
a decision while entering into low power modes. This change
provides a generic implementation wihtout worrying about the
interrupt controller being used on the target.
Change-Id: Ib50cb19dc84333a969fc5287381f7703b64042ed
Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org>
diff --git a/arch/arm/mach-msm/devices-msm7x27.c b/arch/arm/mach-msm/devices-msm7x27.c
index 26f246d..3008fe9 100644
--- a/arch/arm/mach-msm/devices-msm7x27.c
+++ b/arch/arm/mach-msm/devices-msm7x27.c
@@ -35,6 +35,8 @@
#include <mach/msm_hsusb.h>
#include <mach/usbdiag.h>
#include <mach/rpc_hsusb.h>
+#include "irq.h"
+#include "pm.h"
static struct resource resources_uart1[] = {
{
@@ -415,6 +417,21 @@
},
};
+static struct msm_pm_irq_calls msm7x27_pm_irq_calls = {
+ .irq_pending = msm_irq_pending,
+ .idle_sleep_allowed = msm_irq_idle_sleep_allowed,
+ .enter_sleep1 = msm_irq_enter_sleep1,
+ .enter_sleep2 = msm_irq_enter_sleep2,
+ .exit_sleep1 = msm_irq_exit_sleep1,
+ .exit_sleep2 = msm_irq_exit_sleep2,
+ .exit_sleep3 = msm_irq_exit_sleep3,
+};
+
+void msm_pm_register_irqs(void)
+{
+ msm_pm_set_irq_extns(&msm7x27_pm_irq_calls);
+}
+
#define MSM_SDC1_BASE 0xA0400000
#define MSM_SDC2_BASE 0xA0500000
#define MSM_SDC3_BASE 0xA0600000