Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 373828
b: refs/heads/master
c: 8f5ec0a
h: refs/heads/master
v: v3
  • Loading branch information
Magnus Damm authored and Simon Horman committed Apr 2, 2013
1 parent c4f3880 commit 4a29197
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 55d9fab280e6e587d634d2ec2effe94eabe90e9c
refs/heads/master: 8f5ec0a57ef503e7609d763cadba55f12b9486ce
9 changes: 9 additions & 0 deletions trunk/arch/arm/boot/dts/r8a7790.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,13 @@
<1 11 0xf08>,
<1 10 0xf08>;
};

irqc0: interrupt-controller@e61c0000 {
compatible = "renesas,irqc";
#interrupt-cells = <2>;
interrupt-controller;
reg = <0xe61c0000 0x200>;
interrupt-parent = <&gic>;
interrupts = <0 0 4>, <0 1 4>, <0 2 4>, <0 3 4>;
};
};
1 change: 1 addition & 0 deletions trunk/arch/arm/mach-shmobile/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ config ARCH_R8A7790
select CPU_V7
select ARM_ARCH_TIMER
select SH_CLK_CPG
select RENESAS_IRQC

config ARCH_EMEV2
bool "Emma Mobile EV2"
Expand Down
21 changes: 21 additions & 0 deletions trunk/arch/arm/mach-shmobile/setup-r8a7790.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include <linux/kernel.h>
#include <linux/of_platform.h>
#include <linux/serial_sci.h>
#include <linux/platform_data/irq-renesas-irqc.h>
#include <mach/common.h>
#include <mach/irqs.h>
#include <mach/r8a7790.h>
Expand Down Expand Up @@ -74,6 +75,25 @@ static inline void r8a7790_register_scif(int idx)
sizeof(struct plat_sci_port));
}

static struct renesas_irqc_config irqc0_data = {
.irq_base = irq_pin(0), /* IRQ0 -> IRQ3 */
};

static struct resource irqc0_resources[] = {
DEFINE_RES_MEM(0xe61c0000, 0x200), /* IRQC Event Detector Block_0 */
DEFINE_RES_IRQ(gic_spi(0)), /* IRQ0 */
DEFINE_RES_IRQ(gic_spi(1)), /* IRQ1 */
DEFINE_RES_IRQ(gic_spi(2)), /* IRQ2 */
DEFINE_RES_IRQ(gic_spi(3)), /* IRQ3 */
};

#define r8a7790_register_irqc(idx) \
platform_device_register_resndata(&platform_bus, "renesas_irqc", \
idx, irqc##idx##_resources, \
ARRAY_SIZE(irqc##idx##_resources), \
&irqc##idx##_data, \
sizeof(struct renesas_irqc_config))

void __init r8a7790_add_standard_devices(void)
{
r8a7790_register_scif(SCIFA0);
Expand All @@ -84,6 +104,7 @@ void __init r8a7790_add_standard_devices(void)
r8a7790_register_scif(SCIFA2);
r8a7790_register_scif(SCIF0);
r8a7790_register_scif(SCIF1);
r8a7790_register_irqc(0);
}

#ifdef CONFIG_USE_OF
Expand Down

0 comments on commit 4a29197

Please sign in to comment.