summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-prima2/irq.c
diff options
context:
space:
mode:
authorBarry Song <Baohua.Song@csr.com>2012-12-20 19:11:18 +0800
committerBarry Song <Barry.Song@csr.com>2013-01-22 19:39:14 +0800
commitf2a94192d953990c5c928f52dd4122a67f93b980 (patch)
tree77bf983dc45303a627cc342939c5eee3d00087c3 /arch/arm/mach-prima2/irq.c
parent598548facd3c55d1da230a2cc0e6026053b04594 (diff)
downloadblackbird-obmc-linux-f2a94192d953990c5c928f52dd4122a67f93b980.tar.gz
blackbird-obmc-linux-f2a94192d953990c5c928f52dd4122a67f93b980.zip
ARM: PRIMA2: irq: make prima2 irq can work even we enable GIC for Marco
in Marco, we will use GIC. this patch prepares the handle_irq for prima2 to avoid the compiling errors since we want only one defconfig and zImage for both prima2 and marco that means we will need handle_irq for both. Signed-off-by: Baohua Song <Baohua.Song@csr.com>
Diffstat (limited to 'arch/arm/mach-prima2/irq.c')
-rw-r--r--arch/arm/mach-prima2/irq.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/arch/arm/mach-prima2/irq.c b/arch/arm/mach-prima2/irq.c
index 7dee9176e77a..6c0f3e9c43fb 100644
--- a/arch/arm/mach-prima2/irq.c
+++ b/arch/arm/mach-prima2/irq.c
@@ -9,17 +9,19 @@
#include <linux/init.h>
#include <linux/io.h>
#include <linux/irq.h>
-#include <mach/hardware.h>
-#include <asm/mach/irq.h>
#include <linux/of.h>
#include <linux/of_address.h>
#include <linux/irqdomain.h>
#include <linux/syscore_ops.h>
+#include <asm/mach/irq.h>
+#include <asm/exception.h>
+#include <mach/hardware.h>
#define SIRFSOC_INT_RISC_MASK0 0x0018
#define SIRFSOC_INT_RISC_MASK1 0x001C
#define SIRFSOC_INT_RISC_LEVEL0 0x0020
#define SIRFSOC_INT_RISC_LEVEL1 0x0024
+#define SIRFSOC_INIT_IRQ_ID 0x0038
void __iomem *sirfsoc_intc_base;
@@ -52,6 +54,16 @@ static __init void sirfsoc_irq_init(void)
writel_relaxed(0, sirfsoc_intc_base + SIRFSOC_INT_RISC_MASK1);
}
+asmlinkage void __exception_irq_entry sirfsoc_handle_irq(struct pt_regs *regs)
+{
+ u32 irqstat, irqnr;
+
+ irqstat = readl_relaxed(sirfsoc_intc_base + SIRFSOC_INIT_IRQ_ID);
+ irqnr = irqstat & 0xff;
+
+ handle_IRQ(irqnr, regs);
+}
+
static struct of_device_id intc_ids[] = {
{ .compatible = "sirf,prima2-intc" },
{},
OpenPOWER on IntegriCloud