aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-lpc32xx/irq.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-12-12 15:05:15 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2012-12-12 15:05:15 -0500
commitd027db132b395dabfac208e52a7e510e441bb9d2 (patch)
tree24b055b2385f9848e77e646ce475991d8675c3c4 /arch/arm/mach-lpc32xx/irq.c
parentd01e4afdbb65e030fd6f1f96c30a558e2eb0f279 (diff)
parent5faf7cbb848da827f6ea1458b5a1c26a44e7510a (diff)
Merge tag 'soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Pull ARM SoC updates from Olof Johansson: "This contains the bulk of new SoC development for this merge window. Two new platforms have been added, the sunxi platforms (Allwinner A1x SoCs) by Maxime Ripard, and a generic Broadcom platform for a new series of ARMv7 platforms from them, where the hope is that we can keep the platform code generic enough to have them all share one mach directory. The new Broadcom platform is contributed by Christian Daudt. Highbank has grown support for Calxeda's next generation of hardware, ECX-2000. clps711x has seen a lot of cleanup from Alexander Shiyan, and he's also taken on maintainership of the platform. Beyond this there has been a bunch of work from a number of people on converting more platforms to IRQ domains, pinctrl conversion, cleanup and general feature enablement across most of the active platforms." Fix up trivial conflicts as per Olof. * tag 'soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (174 commits) mfd: vexpress-sysreg: Remove LEDs code irqchip: irq-sunxi: Add terminating entry for sunxi_irq_dt_ids clocksource: sunxi_timer: Add terminating entry for sunxi_timer_dt_ids irq: versatile: delete dangling variable ARM: sunxi: add missing include for mdelay() ARM: EXYNOS: Avoid early use of of_machine_is_compatible() ARM: dts: add node for PL330 MDMA1 controller for exynos4 ARM: EXYNOS: Add support for secondary CPU bring-up on Exynos4412 ARM: EXYNOS: add UART3 to DEBUG_LL ports ARM: S3C24XX: Add clkdev entry for camif-upll clock ARM: SAMSUNG: Add s3c24xx/s3c64xx CAMIF GPIO setup helpers ARM: sunxi: Add missing sun4i.dtsi file pinctrl: samsung: Do not initialise statics to 0 ARM i.MX6: remove gate_mask from pllv3 ARM i.MX6: Fix ethernet PLL clocks ARM i.MX6: rename PLLs according to datasheet ARM i.MX6: Add pwm support ARM i.MX51: Add pwm support ARM i.MX53: Add pwm support ARM: mx5: Replace clk_register_clkdev with clock DT lookup ...
Diffstat (limited to 'arch/arm/mach-lpc32xx/irq.c')
-rw-r--r--arch/arm/mach-lpc32xx/irq.c23
1 files changed, 5 insertions, 18 deletions
diff --git a/arch/arm/mach-lpc32xx/irq.c b/arch/arm/mach-lpc32xx/irq.c
index 3c6332753358..9ecb8f9c4ef5 100644
--- a/arch/arm/mach-lpc32xx/irq.c
+++ b/arch/arm/mach-lpc32xx/irq.c
@@ -412,7 +412,6 @@ static const struct of_device_id mic_of_match[] __initconst = {
412void __init lpc32xx_init_irq(void) 412void __init lpc32xx_init_irq(void)
413{ 413{
414 unsigned int i; 414 unsigned int i;
415 int irq_base;
416 415
417 /* Setup MIC */ 416 /* Setup MIC */
418 __raw_writel(0, LPC32XX_INTC_MASK(LPC32XX_MIC_BASE)); 417 __raw_writel(0, LPC32XX_INTC_MASK(LPC32XX_MIC_BASE));
@@ -443,15 +442,6 @@ void __init lpc32xx_init_irq(void)
443 lpc32xx_set_default_mappings(SIC1_APR_DEFAULT, SIC1_ATR_DEFAULT, 32); 442 lpc32xx_set_default_mappings(SIC1_APR_DEFAULT, SIC1_ATR_DEFAULT, 32);
444 lpc32xx_set_default_mappings(SIC2_APR_DEFAULT, SIC2_ATR_DEFAULT, 64); 443 lpc32xx_set_default_mappings(SIC2_APR_DEFAULT, SIC2_ATR_DEFAULT, 64);
445 444
446 /* mask all interrupts except SUBIRQ */
447 __raw_writel(0, LPC32XX_INTC_MASK(LPC32XX_MIC_BASE));
448 __raw_writel(0, LPC32XX_INTC_MASK(LPC32XX_SIC1_BASE));
449 __raw_writel(0, LPC32XX_INTC_MASK(LPC32XX_SIC2_BASE));
450
451 /* MIC SUBIRQx interrupts will route handling to the chain handlers */
452 irq_set_chained_handler(IRQ_LPC32XX_SUB1IRQ, lpc32xx_sic1_handler);
453 irq_set_chained_handler(IRQ_LPC32XX_SUB2IRQ, lpc32xx_sic2_handler);
454
455 /* Initially disable all wake events */ 445 /* Initially disable all wake events */
456 __raw_writel(0, LPC32XX_CLKPWR_P01_ER); 446 __raw_writel(0, LPC32XX_CLKPWR_P01_ER);
457 __raw_writel(0, LPC32XX_CLKPWR_INT_ER); 447 __raw_writel(0, LPC32XX_CLKPWR_INT_ER);
@@ -475,16 +465,13 @@ void __init lpc32xx_init_irq(void)
475 465
476 of_irq_init(mic_of_match); 466 of_irq_init(mic_of_match);
477 467
478 irq_base = irq_alloc_descs(-1, 0, NR_IRQS, 0);
479 if (irq_base < 0) {
480 pr_warn("Cannot allocate irq_descs, assuming pre-allocated\n");
481 irq_base = 0;
482 }
483
484 lpc32xx_mic_domain = irq_domain_add_legacy(lpc32xx_mic_np, NR_IRQS, 468 lpc32xx_mic_domain = irq_domain_add_legacy(lpc32xx_mic_np, NR_IRQS,
485 irq_base, 0, 469 0, 0, &irq_domain_simple_ops,
486 &irq_domain_simple_ops,
487 NULL); 470 NULL);
488 if (!lpc32xx_mic_domain) 471 if (!lpc32xx_mic_domain)
489 panic("Unable to add MIC irq domain\n"); 472 panic("Unable to add MIC irq domain\n");
473
474 /* MIC SUBIRQx interrupts will route handling to the chain handlers */
475 irq_set_chained_handler(IRQ_LPC32XX_SUB1IRQ, lpc32xx_sic1_handler);
476 irq_set_chained_handler(IRQ_LPC32XX_SUB2IRQ, lpc32xx_sic2_handler);
490} 477}