ARM: shmobile: Introduce a Kconfig entry for R-Car Gen2
[firefly-linux-kernel-4.4.55.git] / arch / arm / mach-shmobile / Kconfig
index 3a6e3c20a86d898d91e2762fb88a39837d20910f..73d6d3d7e003e8d73e955b75c7ecec7acbf5fe09 100644 (file)
@@ -1,6 +1,21 @@
 config ARCH_SHMOBILE
        bool
 
+config ARCH_RCAR_GEN1
+       bool
+       select RENESAS_INTC_IRQPIN
+       select SYS_SUPPORTS_SH_TMU
+
+config ARCH_RCAR_GEN2
+       bool
+       select RENESAS_IRQC
+       select SYS_SUPPORTS_SH_CMT
+
+config ARCH_RMOBILE
+       bool
+       select SYS_SUPPORTS_SH_CMT
+       select SYS_SUPPORTS_SH_TMU
+
 menuconfig ARCH_SHMOBILE_MULTI
        bool "Renesas ARM SoCs" if ARCH_MULTI_V7
        depends on MMU
@@ -12,6 +27,7 @@ menuconfig ARCH_SHMOBILE_MULTI
        select NO_IOPORT_MAP
        select PINCTRL
        select ARCH_REQUIRE_GPIOLIB
+       select ARCH_HAS_OPP
 
 if ARCH_SHMOBILE_MULTI
 
@@ -25,15 +41,17 @@ config ARCH_R7S72100
        bool "RZ/A1H (R7S72100)"
        select SYS_SUPPORTS_SH_MTU2
 
+config ARCH_R8A7779
+       bool "R-Car H1 (R8A77790)"
+       select ARCH_RCAR_GEN1
+
 config ARCH_R8A7790
        bool "R-Car H2 (R8A77900)"
-       select RENESAS_IRQC
-       select SYS_SUPPORTS_SH_CMT
+       select ARCH_RCAR_GEN2
 
 config ARCH_R8A7791
        bool "R-Car M2 (R8A77910)"
-       select RENESAS_IRQC
-       select SYS_SUPPORTS_SH_CMT
+       select ARCH_RCAR_GEN2
 
 comment "Renesas ARM SoCs Board Type"
 
@@ -51,6 +69,11 @@ config MACH_LAGER
        depends on ARCH_R8A7790
        select MICREL_PHY if SH_ETH
 
+config MACH_MARZEN
+       bool "MARZEN board"
+       depends on ARCH_R8A7779
+       select REGULATOR_FIXED_VOLTAGE if REGULATOR
+
 comment "Renesas ARM SoCs System Configuration"
 endif
 
@@ -60,82 +83,76 @@ comment "Renesas ARM SoCs System Type"
 
 config ARCH_SH7372
        bool "SH-Mobile AP4 (SH7372)"
+       select ARCH_RMOBILE
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_CPU_SUSPEND if PM || CPU_IDLE
        select CPU_V7
        select SH_CLK_CPG
-       select SYS_SUPPORTS_SH_CMT
-       select SYS_SUPPORTS_SH_TMU
+       select SH_INTC
 
 config ARCH_SH73A0
        bool "SH-Mobile AG5 (R8A73A00)"
+       select ARCH_RMOBILE
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select I2C
        select SH_CLK_CPG
+       select SH_INTC
        select RENESAS_INTC_IRQPIN
-       select SYS_SUPPORTS_SH_CMT
-       select SYS_SUPPORTS_SH_TMU
 
 config ARCH_R8A73A4
        bool "R-Mobile APE6 (R8A73A40)"
+       select ARCH_RMOBILE
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select SH_CLK_CPG
        select RENESAS_IRQC
-       select SYS_SUPPORTS_SH_CMT
-       select SYS_SUPPORTS_SH_TMU
 
 config ARCH_R8A7740
        bool "R-Mobile A1 (R8A77400)"
+       select ARCH_RMOBILE
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select SH_CLK_CPG
        select RENESAS_INTC_IRQPIN
-       select SYS_SUPPORTS_SH_CMT
-       select SYS_SUPPORTS_SH_TMU
 
 config ARCH_R8A7778
        bool "R-Car M1A (R8A77781)"
+       select ARCH_RCAR_GEN1
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select CPU_V7
        select SH_CLK_CPG
        select ARM_GIC
-       select SYS_SUPPORTS_SH_TMU
-       select RENESAS_INTC_IRQPIN
 
 config ARCH_R8A7779
        bool "R-Car H1 (R8A77790)"
+       select ARCH_RCAR_GEN1
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select SH_CLK_CPG
-       select RENESAS_INTC_IRQPIN
-       select SYS_SUPPORTS_SH_TMU
 
 config ARCH_R8A7790
        bool "R-Car H2 (R8A77900)"
+       select ARCH_RCAR_GEN2
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select MIGHT_HAVE_PCI
        select SH_CLK_CPG
-       select RENESAS_IRQC
-       select SYS_SUPPORTS_SH_CMT
        select ARCH_DMA_ADDR_T_64BIT if ARM_LPAE
 
 config ARCH_R8A7791
        bool "R-Car M2 (R8A77910)"
+       select ARCH_RCAR_GEN2
        select ARCH_WANT_OPTIONAL_GPIOLIB
        select ARM_GIC
        select CPU_V7
        select MIGHT_HAVE_PCI
        select SH_CLK_CPG
-       select RENESAS_IRQC
-       select SYS_SUPPORTS_SH_CMT
        select ARCH_DMA_ADDR_T_64BIT if ARM_LPAE
 
 config ARCH_R7S72100
@@ -233,19 +250,6 @@ config MACH_MARZEN
        select REGULATOR_FIXED_VOLTAGE if REGULATOR
        select USE_OF
 
-config MACH_MARZEN_REFERENCE
-       bool "MARZEN board - Reference Device Tree Implementation"
-       depends on ARCH_R8A7779
-       select ARCH_REQUIRE_GPIOLIB
-       select REGULATOR_FIXED_VOLTAGE if REGULATOR
-       select USE_OF
-       ---help---
-          Use reference implementation of Marzen board support
-          which makes use of device tree at the expense
-          of not supporting a number of devices.
-
-          This is intended to aid developers
-
 config MACH_LAGER
        bool "Lager board"
        depends on ARCH_R8A7790