Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0b7d7820 authored by Bastian Hecht's avatar Bastian Hecht Committed by Simon Horman
Browse files

ARM: shmobile: r8a7740: Migrate from INTC to GIC



With the added capabilty of the intc_irqpin driver to handle shared
external IRQs, all prerequisites are fulfilled and we are ready to
migrate completely to GIC. This includes the following steps:

- Kconfig:	select ARM_GIC and RENESAS_INTC_IRQPIN
- intc-r8a7740: Throw out all legacy INTC code and init the GIC. We need
  		to mask out all shared IRQs as it is needed by the
		shared intc_irqpin driver.
- setup-r8a7740: Add 4 irqpin devices to handle external IRQs and update
		all IRQ numbers to point to the GIC SPI.
- board-armadillo: Update all IRQ numbers to point to the GIC SPI.
- pfc-r8a7740:	Update all IRQ numbers of the GPIOs to point to the GIC
		SPI.

Signed-off-by: default avatarBastian Hecht <hechtb+renesas@gmail.com>
Acked-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: default avatarSimon Horman <horms+renesas@verge.net.au>
parent c91cf2fa
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -30,8 +30,10 @@ config ARCH_R8A73A4
config ARCH_R8A7740
	bool "R-Mobile A1 (R8A77400)"
	select ARCH_WANT_OPTIONAL_GPIOLIB
	select ARM_GIC
	select CPU_V7
	select SH_CLK_CPG
	select RENESAS_INTC_IRQPIN

config ARCH_R8A7778
	bool "R-Car M1 (R8A77780)"
+17 −18
Original line number Diff line number Diff line
@@ -145,7 +145,7 @@
 * see
 *	usbhsf_power_ctrl()
 */
#define IRQ7		evt2irq(0x02e0)
#define IRQ7		irq_pin(7)
#define USBCR1		IOMEM(0xe605810a)
#define USBH		0xC6700000
#define USBH_USBCTR	0x10834
@@ -330,7 +330,7 @@ static struct resource usbhsf_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	{
		.start	= evt2irq(0x0A20),
		.start	= gic_spi(51),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -363,7 +363,7 @@ static struct resource sh_eth_resources[] = {
		.end	= 0xe9a02000 - 1,
		.flags	= IORESOURCE_MEM,
	}, {
		.start	= evt2irq(0x0500),
		.start	= gic_spi(110),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -417,7 +417,7 @@ static struct resource lcdc0_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start	= intcs_evt2irq(0x580),
		.start	= gic_spi(177),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -452,7 +452,7 @@ static struct resource hdmi_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start	= evt2irq(0x1700),
		.start	= gic_spi(131),
		.flags	= IORESOURCE_IRQ,
	},
	[2] = {
@@ -514,7 +514,7 @@ static struct resource hdmi_lcdc_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start	= intcs_evt2irq(0x1780),
		.start	= gic_spi(178),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -574,7 +574,7 @@ static struct regulator_consumer_supply fixed3v3_power_consumers[] =
 * We can use IRQ31 as card detect irq,
 * but it needs chattering removal operation
 */
#define IRQ31	evt2irq(0x33E0)
#define IRQ31	irq_pin(31)
static struct sh_mobile_sdhi_info sdhi0_info = {
	.dma_slave_tx	= SHDMA_SLAVE_SDHI0_TX,
	.dma_slave_rx	= SHDMA_SLAVE_SDHI0_RX,
@@ -596,12 +596,12 @@ static struct resource sdhi0_resources[] = {
	 */
	{
		.name	= SH_MOBILE_SDHI_IRQ_SDCARD,
		.start	= evt2irq(0x0E20),
		.start	= gic_spi(118),
		.flags	= IORESOURCE_IRQ,
	},
	{
		.name	= SH_MOBILE_SDHI_IRQ_SDIO,
		.start	= evt2irq(0x0E40),
		.start	= gic_spi(119),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -633,15 +633,15 @@ static struct resource sdhi1_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start	= evt2irq(0x0E80),
		.start	= gic_spi(121),
		.flags	= IORESOURCE_IRQ,
	},
	[2] = {
		.start	= evt2irq(0x0EA0),
		.start	= gic_spi(122),
		.flags	= IORESOURCE_IRQ,
	},
	[3] = {
		.start	= evt2irq(0x0EC0),
		.start	= gic_spi(123),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -674,12 +674,12 @@ static struct resource sh_mmcif_resources[] = {
	},
	[1] = {
		/* MMC ERR */
		.start	= evt2irq(0x1AC0),
		.start	= gic_spi(56),
		.flags	= IORESOURCE_IRQ,
	},
	[2] = {
		/* MMC NOR */
		.start	= evt2irq(0x1AE0),
		.start	= gic_spi(57),
		.flags	= IORESOURCE_IRQ,
	},
};
@@ -756,7 +756,7 @@ static struct resource ceu0_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start  = intcs_evt2irq(0x0500),
		.start  = gic_spi(160),
		.flags  = IORESOURCE_IRQ,
	},
	[2] = {
@@ -798,7 +798,7 @@ static struct resource fsi_resources[] = {
		.flags	= IORESOURCE_MEM,
	},
	[1] = {
		.start  = evt2irq(0x1840),
		.start  = gic_spi(9),
		.flags  = IORESOURCE_IRQ,
	},
};
@@ -881,7 +881,7 @@ static struct platform_device i2c_gpio_device = {
static struct i2c_board_info i2c0_devices[] = {
	{
		I2C_BOARD_INFO("st1232-ts", 0x55),
		.irq = evt2irq(0x0340),
		.irq = irq_pin(10),
	},
	{
		I2C_BOARD_INFO("wm8978", 0x1a),
@@ -1207,7 +1207,6 @@ DT_MACHINE_START(ARMADILLO800EVA_DT, "armadillo800eva")
	.map_io		= r8a7740_map_io,
	.init_early	= eva_add_early_devices,
	.init_irq	= r8a7740_init_irq,
	.handle_irq	= shmobile_handle_irq_intc,
	.init_machine	= eva_init,
	.init_late	= shmobile_init_late,
	.init_time	= eva_earlytimer_init,
+30 −611

File changed.

Preview size limit exceeded, changes collapsed.

+158 −34

File changed.

Preview size limit exceeded, changes collapsed.

+32 −32

File changed.

Preview size limit exceeded, changes collapsed.