Commit fea9fe83 authored by Marc Zyngier's avatar Marc Zyngier

ARM: imx: convert smp platforms to global gic_handle_irq()

Convert the SMP imx platforms to use the global gic_handle_irq()
function instead a private function.

Cc: Sascha Hauer <kernel@pengutronix.de>
Acked-by: default avatarShawn Guo <shawn.guo@linaro.org>
Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
parent 562e0027
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
# Common support # Common support
obj-y := clock.o time.o devices.o cpu.o system.o irq-common.o obj-y := clock.o time.o devices.o cpu.o system.o irq-common.o
obj-$(CONFIG_ARM_GIC) += gic.o
obj-$(CONFIG_MXC_TZIC) += tzic.o obj-$(CONFIG_MXC_TZIC) += tzic.o
obj-$(CONFIG_MXC_AVIC) += avic.o obj-$(CONFIG_MXC_AVIC) += avic.o
......
/*
* Copyright 2011 Freescale Semiconductor, Inc.
* Copyright 2011 Linaro Ltd.
*
* The code contained herein is licensed under the GNU General Public
* License. You may obtain a copy of the GNU General Public License
* Version 2 or later at the following locations:
*
* http://www.opensource.org/licenses/gpl-license.html
* http://www.gnu.org/copyleft/gpl.html
*/
#include <linux/io.h>
#include <asm/exception.h>
#include <asm/localtimer.h>
#include <asm/hardware/gic.h>
#ifdef CONFIG_SMP
#include <asm/smp.h>
#endif
asmlinkage void __exception_irq_entry mxc_gic_handle_irq(struct pt_regs *regs)
{
u32 irqstat, irqnr;
do {
irqstat = readl_relaxed(gic_cpu_base_addr + GIC_CPU_INTACK);
irqnr = irqstat & 0x3ff;
if (irqnr == 1023)
break;
if (irqnr > 15 && irqnr < 1021)
handle_IRQ(irqnr, regs);
#ifdef CONFIG_SMP
else {
writel_relaxed(irqstat, gic_cpu_base_addr +
GIC_CPU_EOI);
handle_IPI(irqnr, regs);
}
#endif
} while (1);
}
...@@ -90,7 +90,6 @@ extern void imx_print_silicon_rev(const char *cpu, int srev); ...@@ -90,7 +90,6 @@ extern void imx_print_silicon_rev(const char *cpu, int srev);
void avic_handle_irq(struct pt_regs *); void avic_handle_irq(struct pt_regs *);
void tzic_handle_irq(struct pt_regs *); void tzic_handle_irq(struct pt_regs *);
void mxc_gic_handle_irq(struct pt_regs *);
#define imx1_handle_irq avic_handle_irq #define imx1_handle_irq avic_handle_irq
#define imx21_handle_irq avic_handle_irq #define imx21_handle_irq avic_handle_irq
...@@ -101,7 +100,7 @@ void mxc_gic_handle_irq(struct pt_regs *); ...@@ -101,7 +100,7 @@ void mxc_gic_handle_irq(struct pt_regs *);
#define imx50_handle_irq tzic_handle_irq #define imx50_handle_irq tzic_handle_irq
#define imx51_handle_irq tzic_handle_irq #define imx51_handle_irq tzic_handle_irq
#define imx53_handle_irq tzic_handle_irq #define imx53_handle_irq tzic_handle_irq
#define imx6q_handle_irq mxc_gic_handle_irq #define imx6q_handle_irq gic_handle_irq
extern void imx_enable_cpu(int cpu, bool enable); extern void imx_enable_cpu(int cpu, bool enable);
extern void imx_set_cpu_jump(int cpu, void *jump_addr); extern void imx_set_cpu_jump(int cpu, void *jump_addr);
......
...@@ -9,19 +9,8 @@ ...@@ -9,19 +9,8 @@
* published by the Free Software Foundation. * published by the Free Software Foundation.
*/ */
/* Unused, we use CONFIG_MULTI_IRQ_HANDLER */
.macro disable_fiq .macro disable_fiq
.endm .endm
.macro get_irqnr_preamble, base, tmp
.endm
.macro arch_ret_to_user, tmp1, tmp2 .macro arch_ret_to_user, tmp1, tmp2
.endm .endm
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
.endm
.macro test_for_ipi, irqnr, irqstat, base, tmp
.endm
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment