Add RZ/G2[ME] SoC Identification/SYSC/RST support
cover Add RZ/G2[ME] SoC Identification/SYSC/RST support
This patch series aims to add SoC identification/SYSC/RST support for RZ/G2[ME] SoCs.
This patch series is based on linux-4.19.y-cip and all the patches in this series are cherry-picked from linux rc tree.
Biju Das (8):
dt-bindings: arm: Document RZ/G2M SoC DT bindings
soc: renesas: Identify RZ/G2M
arm64: Add Renesas R8A774A1 support
arm64: defconfig: enable R8A774A1 SoC
dt-bindings: power: Add r8a774a1 SYSC power domain definitions
soc: renesas: rcar-sysc: Add r8a774a1 support
soc: renesas: r8a774c0-sysc: Fix initialization order of 3DG-{A,B}
soc: renesas: rcar-rst: Add support for RZ/G2M
Fabrizio Castro (10):
dt-bindings: arm: Document RZ/G2E SoC DT bindings
dt-bindings: arm: Fix RZ/G2E part number
soc: renesas: Identify RZ/G2E
arm64: Add Renesas R8A774C0 support
arm64: defconfig: enable R8A774C0 SoC
dt-bindings: power: Add r8a774c0 SYSC power domain definitions
dt-bindings: power: rcar-sysc: Document r8a774c0 sysc
soc: renesas: rcar-sysc: Add r8a774c0 support
dt-bindings: reset: rcar-rst: Document r8a774c0 rst
soc: renesas: rcar-rst: Add support for RZ/G2E
Documentation/devicetree/bindings/arm/shmobile.txt | 4 ++ .../bindings/power/renesas,rcar-sysc.txt | 2 + .../devicetree/bindings/reset/renesas,rst.txt | 2 + arch/arm64/Kconfig.platforms | 12 +++++ arch/arm64/configs/defconfig | 2 + drivers/soc/renesas/Kconfig | 16 +++++-- drivers/soc/renesas/Makefile | 2 + drivers/soc/renesas/r8a774a1-sysc.c | 45 ++++++++++++++++++ drivers/soc/renesas/r8a774c0-sysc.c | 53 ++++++++++++++++++++++ drivers/soc/renesas/rcar-rst.c | 5 +- drivers/soc/renesas/rcar-sysc.c | 6 +++ drivers/soc/renesas/rcar-sysc.h | 2 + drivers/soc/renesas/renesas-soc.c | 35 +++++++++++--- include/dt-bindings/power/r8a774a1-sysc.h | 31 +++++++++++++ include/dt-bindings/power/r8a774c0-sysc.h | 25 ++++++++++ 15 files changed, 231 insertions(+), 11 deletions(-) create mode 100644 drivers/soc/renesas/r8a774a1-sysc.c create mode 100644 drivers/soc/renesas/r8a774c0-sysc.c create mode 100644 include/dt-bindings/power/r8a774a1-sysc.h create mode 100644 include/dt-bindings/power/r8a774c0-sysc.h
Signature · 1 line
2.7.4
PATCH 1/18 dt-bindings: arm: Document RZ/G2M SoC DT bindings
Add device tree bindings documentation for Renesas RZ/G2M (r8a774a1) SoC.
--- Documentation/devicetree/bindings/arm/shmobile.txt | 2 ++ 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/arm/shmobile.txt +2 -0
@@ -23,6 +23,8 @@ SoCs: compatible = "renesas,r8a7745" - RZ/G1C (R8A77470) compatible = "renesas,r8a77470" + - RZ/G2M (R8A774A1) + compatible = "renesas,r8a774a1" - R-Car M1A (R8A77781) compatible = "renesas,r8a7778" - R-Car H1 (R8A77790)
Signature · 1 line
2.7.4
PATCH 2/18 dt-bindings: arm: Document RZ/G2E SoC DT bindings
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Add device tree bindings documentation for Renesas RZ/G2E (r8a774c0) SoC.
--- Documentation/devicetree/bindings/arm/shmobile.txt | 2 ++ 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/arm/shmobile.txt +2 -0
@@ -25,6 +25,8 @@ SoCs: compatible = "renesas,r8a77470" - RZ/G2M (R8A774A1) compatible = "renesas,r8a774a1" + - RZ/G2E (RA8774C0) + compatible = "renesas,r8a774c0" - R-Car M1A (R8A77781) compatible = "renesas,r8a7778" - R-Car H1 (R8A77790)
Signature · 1 line
2.7.4
PATCH 3/18 dt-bindings: arm: Fix RZ/G2E part number
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Fix RZ/G2E part number from its description.
--- Documentation/devicetree/bindings/arm/shmobile.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Documentation/devicetree/bindings/arm/shmobile.txt +1 -1
@@ -25,7 +25,7 @@ SoCs: compatible = "renesas,r8a77470" - RZ/G2M (R8A774A1) compatible = "renesas,r8a774a1" - - RZ/G2E (RA8774C0) + - RZ/G2E (R8A774C0) compatible = "renesas,r8a774c0" - R-Car M1A (R8A77781) compatible = "renesas,r8a7778"
Signature · 1 line
2.7.4
PATCH 4/18 soc: renesas: Identify RZ/G2M
In reply to Biju DasThis patch adds support for identifying the RZ/G2M (r8a774a1) SoC. It corrects the original RZ/G SoC family name to RZ/G1 and also adds support for the new RZ/G2 SoC family.
--- drivers/soc/renesas/renesas-soc.c | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-)
drivers/soc/renesas/renesas-soc.c +20 -7
@@ -50,11 +50,16 @@ static const struct renesas_family fam_rza __initconst __maybe_unused = { .name = "RZ/A", }; -static const struct renesas_family fam_rzg__initconst __maybe_unused = { - .name ="RZ/G" , +static const struct renesas_family fam_rzg1__initconst __maybe_unused = { + .name ="RZ/G1" , .reg =0xff000044 ,/* PRR (Product Register) */ }; +static const struct renesas_family fam_rzg2__initconst __maybe_unused = { + .name ="RZ/G2" , + .reg =0xfff00044 ,/* PRR (Product Register) */ +}; +static const struct renesas_family fam_shmobile__initconst __maybe_unused = { .name ="SH-Mobile" , .reg =0xe600101c ,/* CCCR (Common Chip Code Register) */
@@ -81,30 +86,35 @@ static const struct renesas_soc soc_rmobile_a1 __initconst __maybe_unused = { };static const struct renesas_soc soc_rz_g1h__initconst __maybe_unused = { - .family = &fam_rzg, + .family = &fam_rzg1, .id =0x45 , };static const struct renesas_soc soc_rz_g1m__initconst __maybe_unused = { - .family = &fam_rzg, + .family = &fam_rzg1, .id =0x47 , };static const struct renesas_soc soc_rz_g1n__initconst __maybe_unused = { - .family = &fam_rzg, + .family = &fam_rzg1, .id =0x4b , };static const struct renesas_soc soc_rz_g1e__initconst __maybe_unused = { - .family = &fam_rzg, + .family = &fam_rzg1, .id =0x4c , };static const struct renesas_soc soc_rz_g1c__initconst __maybe_unused = { - .family = &fam_rzg, + .family = &fam_rzg1, .id =0x53 , }; +static const struct renesas_soc soc_rz_g2m__initconst __maybe_unused = { + .family = &fam_rzg2, + .id =0x52 , +}; +static const struct renesas_soc soc_rcar_m1a__initconst __maybe_unused = { .family = &fam_rcar_gen1, };
@@ -205,6 +215,9 @@ static const struct of_device_id renesas_socs[] __initconst = { #ifdef CONFIG_ARCH_R8A77470 { .compatible = "renesas,r8a77470", .data = &soc_rz_g1c }, #endif +#ifdef CONFIG_ARCH_R8A774A1 + { .compatible = "renesas,r8a774a1", .data = &soc_rz_g2m }, +#endif #ifdef CONFIG_ARCH_R8A7778 { .compatible = "renesas,r8a7778", .data = &soc_rcar_m1a }, #endif
Signature · 1 line
2.7.4
PATCH 5/18 soc: renesas: Identify RZ/G2E
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Add support for identifying the RZ/G2E (r8a774c0) SoC.
--- drivers/soc/renesas/renesas-soc.c | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/soc/renesas/renesas-soc.c +8 -0
@@ -115,6 +115,11 @@ static const struct renesas_soc soc_rz_g2m __initconst __maybe_unused = { .id = 0x52, }; +static const struct renesas_soc soc_rz_g2e__initconst __maybe_unused = { + .family = &fam_rzg2, + .id =0x57 , +}; +static const struct renesas_soc soc_rcar_m1a__initconst __maybe_unused = { .family = &fam_rcar_gen1, };
@@ -218,6 +223,9 @@ static const struct of_device_id renesas_socs[] __initconst = { #ifdef CONFIG_ARCH_R8A774A1 { .compatible = "renesas,r8a774a1", .data = &soc_rz_g2m }, #endif +#ifdef CONFIG_ARCH_R8A774C0 + { .compatible = "renesas,r8a774c0", .data = &soc_rz_g2e }, +#endif #ifdef CONFIG_ARCH_R8A7778 { .compatible = "renesas,r8a7778", .data = &soc_rcar_m1a }, #endif
Signature · 1 line
2.7.4
PATCH 6/18 arm64: Add Renesas R8A774A1 support
In reply to Biju DasAdd configuration option for the RZ/G2M (R8A774A1) SoC.
--- arch/arm64/Kconfig.platforms | 6 ++++++ 1 file changed, 6 insertions(+)
arch/arm64/Kconfig.platforms +6 -0
@@ -186,6 +186,12 @@ config ARCH_RENESAS help This enables support for the ARMv8 based Renesas SoCs. +config ARCH_R8A774A1 + bool "Renesas RZ/G2M SoC Platform" + depends on ARCH_RENESAS + help + This enables support for the Renesas RZ/G2M SoC. + config ARCH_R8A7795 bool "Renesas R-Car H3 SoC Platform" depends on ARCH_RENESAS
Signature · 1 line
2.7.4
PATCH 7/18 arm64: Add Renesas R8A774C0 support
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Add configuration option for the RZ/G2E (R8A774C0) SoC.
--- arch/arm64/Kconfig.platforms | 6 ++++++ 1 file changed, 6 insertions(+)
arch/arm64/Kconfig.platforms +6 -0
@@ -192,6 +192,12 @@ config ARCH_R8A774A1 help This enables support for the Renesas RZ/G2M SoC. +config ARCH_R8A774C0 + bool "Renesas RZ/G2E SoC Platform" + depends on ARCH_RENESAS + help + This enables support for the Renesas RZ/G2E SoC. + config ARCH_R8A7795 bool "Renesas R-Car H3 SoC Platform" depends on ARCH_RENESAS
Signature · 1 line
2.7.4
PATCH 8/18 arm64: defconfig: enable R8A774A1 SoC
In reply to Biju DasEnable the Renesas RZ/G2M (R8A774A1) SoC in the ARM64 defconfig.
--- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm64/configs/defconfig +1 -0
@@ -50,6 +50,7 @@ CONFIG_ARCH_ROCKCHIP=y CONFIG_ARCH_SEATTLE=y CONFIG_ARCH_SYNQUACER=y CONFIG_ARCH_RENESAS=y +CONFIG_ARCH_R8A774A1=y CONFIG_ARCH_R8A7795=y CONFIG_ARCH_R8A7796=y CONFIG_ARCH_R8A77965=y
Signature · 1 line
2.7.4
PATCH 9/18 arm64: defconfig: enable R8A774C0 SoC
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Enable the Renesas RZ/G2E (R8A774C0) SoC in the ARM64 defconfig.
--- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm64/configs/defconfig +1 -0
@@ -51,6 +51,7 @@ CONFIG_ARCH_SEATTLE=y CONFIG_ARCH_SYNQUACER=y CONFIG_ARCH_RENESAS=y CONFIG_ARCH_R8A774A1=y +CONFIG_ARCH_R8A774C0=y CONFIG_ARCH_R8A7795=y CONFIG_ARCH_R8A7796=y CONFIG_ARCH_R8A77965=y
Signature · 1 line
2.7.4
PATCH 10/18 dt-bindings: power: Add r8a774a1 SYSC power domain definitions
In reply to Biju DasThis patch adds power domain indices for RZ/G2M.
--- include/dt-bindings/power/r8a774a1-sysc.h | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 include/dt-bindings/power/r8a774a1-sysc.h
include/dt-bindings/power/r8a774a1-sysc.h new file +31 -0
@@ -0,0 +1,31 @@ +/* SPDX-License-Identifier: GPL-2.0 +* +* Copyright (C) 2018 Renesas Electronics Corp. +*/ +#ifndef __DT_BINDINGS_POWER_R8A774A1_SYSC_H__ +#define __DT_BINDINGS_POWER_R8A774A1_SYSC_H__ + +/* +* These power domain indices match the numbers of the interrupt bits +* representing the power areas in the various Interrupt Registers +* (e.g. SYSCISR, Interrupt Status Register) +*/ + +#define R8A774A1_PD_CA57_CPU0 0 +#define R8A774A1_PD_CA57_CPU1 1 +#define R8A774A1_PD_CA53_CPU0 5 +#define R8A774A1_PD_CA53_CPU1 6 +#define R8A774A1_PD_CA53_CPU2 7 +#define R8A774A1_PD_CA53_CPU3 8 +#define R8A774A1_PD_CA57_SCU 12 +#define R8A774A1_PD_A3VC 14 +#define R8A774A1_PD_3DG_A 17 +#define R8A774A1_PD_3DG_B 18 +#define R8A774A1_PD_CA53_SCU 21 +#define R8A774A1_PD_A2VC0 25 +#define R8A774A1_PD_A2VC1 26 + +/* Always-on power area */ +#define R8A774A1_PD_ALWAYS_ON 32 + +#endif /* __DT_BINDINGS_POWER_R8A774A1_SYSC_H__ */
Signature · 1 line
2.7.4
PATCH 11/18 dt-bindings: power: Add r8a774c0 SYSC power domain definitions
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
This patch adds power domain indices for RZ/G2E.
--- include/dt-bindings/power/r8a774c0-sysc.h | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 include/dt-bindings/power/r8a774c0-sysc.h
include/dt-bindings/power/r8a774c0-sysc.h new file +25 -0
@@ -0,0 +1,25 @@ +/* SPDX-License-Identifier: GPL-2.0 +* +* Copyright (C) 2018 Renesas Electronics Corp. +*/ +#ifndef __DT_BINDINGS_POWER_R8A774C0_SYSC_H__ +#define __DT_BINDINGS_POWER_R8A774C0_SYSC_H__ + +/* +* These power domain indices match the numbers of the interrupt bits +* representing the power areas in the various Interrupt Registers +* (e.g. SYSCISR, Interrupt Status Register) +*/ + +#define R8A774C0_PD_CA53_CPU0 5 +#define R8A774C0_PD_CA53_CPU1 6 +#define R8A774C0_PD_A3VC 14 +#define R8A774C0_PD_3DG_A 17 +#define R8A774C0_PD_3DG_B 18 +#define R8A774C0_PD_CA53_SCU 21 +#define R8A774C0_PD_A2VC1 26 + +/* Always-on power area */ +#define R8A774C0_PD_ALWAYS_ON 32 + +#endif /* __DT_BINDINGS_POWER_R8A774C0_SYSC_H__ */
Signature · 1 line
2.7.4
PATCH 12/18 soc: renesas: rcar-sysc: Add r8a774a1 support
In reply to Biju DasAdd support for RZ/G2M (R8A774A1) SoC power areas to the R-Car SYSC driver.
--- .../bindings/power/renesas,rcar-sysc.txt | 1 + drivers/soc/renesas/Kconfig | 5 +++ drivers/soc/renesas/Makefile | 1 + drivers/soc/renesas/r8a774a1-sysc.c | 45 ++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 ++ drivers/soc/renesas/rcar-sysc.h | 1 + 6 files changed, 56 insertions(+) create mode 100644 drivers/soc/renesas/r8a774a1-sysc.c
Documentation/devicetree/bindings/power/renesas,rcar-sysc.txt +1 -0
@@ -10,6 +10,7 @@ Required properties: - "renesas,r8a7743-sysc" (RZ/G1M) - "renesas,r8a7745-sysc" (RZ/G1E) - "renesas,r8a77470-sysc" (RZ/G1C) + - "renesas,r8a774a1-sysc" (RZ/G2M) - "renesas,r8a7779-sysc" (R-Car H1) - "renesas,r8a7790-sysc" (R-Car H2) - "renesas,r8a7791-sysc" (R-Car M2-W)
drivers/soc/renesas/Kconfig +5 -0
@@ -9,6 +9,7 @@ config SOC_RENESAS select SYSC_R8A7743 if ARCH_R8A7743 select SYSC_R8A7745 if ARCH_R8A7745 select SYSC_R8A77470 if ARCH_R8A77470 + select SYSC_R8A774A1 if ARCH_R8A774A1 select SYSC_R8A7779 if ARCH_R8A7779 select SYSC_R8A7790 if ARCH_R8A7790 select SYSC_R8A7791 if ARCH_R8A7791 || ARCH_R8A7793
@@ -37,6 +38,10 @@ config SYSC_R8A77470 bool "RZ/G1C System Controller support" if COMPILE_TEST select SYSC_RCAR +config SYSC_R8A774A1 + bool "RZ/G2M System Controller support" if COMPILE_TEST + select SYSC_RCAR + config SYSC_R8A7779 bool "R-Car H1 System Controller support" if COMPILE_TEST select SYSC_RCAR
drivers/soc/renesas/Makefile +1 -0
@@ -6,6 +6,7 @@ obj-$(CONFIG_SOC_RENESAS) += renesas-soc.o obj-$(CONFIG_SYSC_R8A7743) += r8a7743-sysc.o obj-$(CONFIG_SYSC_R8A7745) += r8a7745-sysc.o obj-$(CONFIG_SYSC_R8A77470) += r8a77470-sysc.o +obj-$(CONFIG_SYSC_R8A774A1) += r8a774a1-sysc.o obj-$(CONFIG_SYSC_R8A7779) += r8a7779-sysc.o obj-$(CONFIG_SYSC_R8A7790) += r8a7790-sysc.o obj-$(CONFIG_SYSC_R8A7791) += r8a7791-sysc.o
drivers/soc/renesas/r8a774a1-sysc.c new file +45 -0
45 lines not on this page · raw message
drivers/soc/renesas/rcar-sysc.c +3 -0
@@ -275,6 +275,9 @@ static const struct of_device_id rcar_sysc_matches[] __initconst = { #ifdef CONFIG_SYSC_R8A77470 { .compatible = "renesas,r8a77470-sysc", .data = &r8a77470_sysc_info }, #endif +#ifdef CONFIG_SYSC_R8A774A1 + { .compatible = "renesas,r8a774a1-sysc", .data = &r8a774a1_sysc_info }, +#endif #ifdef CONFIG_SYSC_R8A7779 { .compatible = "renesas,r8a7779-sysc", .data = &r8a7779_sysc_info }, #endif
drivers/soc/renesas/rcar-sysc.h +1 -0
@@ -52,6 +52,7 @@ struct rcar_sysc_info {extern const struct rcar_sysc_info r8a7743_sysc_info;extern const struct rcar_sysc_info r8a7745_sysc_info;extern const struct rcar_sysc_info r8a77470_sysc_info; +extern const struct rcar_sysc_info r8a774a1_sysc_info;extern const struct rcar_sysc_info r8a7779_sysc_info;extern const struct rcar_sysc_info r8a7790_sysc_info;extern const struct rcar_sysc_info r8a7791_sysc_info;
Signature · 1 line
2.7.4
PATCH 13/18 dt-bindings: power: rcar-sysc: Document r8a774c0 sysc
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Document bindings for the RZ/G2E (a.k.a. R8A774C0) system controller.
--- Documentation/devicetree/bindings/power/renesas,rcar-sysc.txt | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/power/renesas,rcar-sysc.txt +1 -0
@@ -11,6 +11,7 @@ Required properties: - "renesas,r8a7745-sysc" (RZ/G1E) - "renesas,r8a77470-sysc" (RZ/G1C) - "renesas,r8a774a1-sysc" (RZ/G2M) + - "renesas,r8a774c0-sysc" (RZ/G2E) - "renesas,r8a7779-sysc" (R-Car H1) - "renesas,r8a7790-sysc" (R-Car H2) - "renesas,r8a7791-sysc" (R-Car M2-W)
Signature · 1 line
2.7.4
PATCH 14/18 soc: renesas: rcar-sysc: Add r8a774c0 support
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Add support for the RZ/G2E (R8A774C0) SoC power areas to the R-Car SYSC driver.
--- drivers/soc/renesas/Kconfig | 5 +++ drivers/soc/renesas/Makefile | 1 + drivers/soc/renesas/r8a774c0-sysc.c | 68 +++++++++++++++++++++++++++++++++++++ drivers/soc/renesas/rcar-sysc.c | 3 ++ drivers/soc/renesas/rcar-sysc.h | 1 + 5 files changed, 78 insertions(+) create mode 100644 drivers/soc/renesas/r8a774c0-sysc.c
drivers/soc/renesas/Kconfig +5 -0
@@ -10,6 +10,7 @@ config SOC_RENESAS select SYSC_R8A7745 if ARCH_R8A7745 select SYSC_R8A77470 if ARCH_R8A77470 select SYSC_R8A774A1 if ARCH_R8A774A1 + select SYSC_R8A774C0 if ARCH_R8A774C0 select SYSC_R8A7779 if ARCH_R8A7779 select SYSC_R8A7790 if ARCH_R8A7790 select SYSC_R8A7791 if ARCH_R8A7791 || ARCH_R8A7793
@@ -42,6 +43,10 @@ config SYSC_R8A774A1 bool "RZ/G2M System Controller support" if COMPILE_TEST select SYSC_RCAR +config SYSC_R8A774C0 + bool "RZ/G2E System Controller support" if COMPILE_TEST + select SYSC_RCAR + config SYSC_R8A7779 bool "R-Car H1 System Controller support" if COMPILE_TEST select SYSC_RCAR
drivers/soc/renesas/Makefile +1 -0
@@ -7,6 +7,7 @@ obj-$(CONFIG_SYSC_R8A7743) += r8a7743-sysc.o obj-$(CONFIG_SYSC_R8A7745) += r8a7745-sysc.o obj-$(CONFIG_SYSC_R8A77470) += r8a77470-sysc.o obj-$(CONFIG_SYSC_R8A774A1) += r8a774a1-sysc.o +obj-$(CONFIG_SYSC_R8A774C0) += r8a774c0-sysc.o obj-$(CONFIG_SYSC_R8A7779) += r8a7779-sysc.o obj-$(CONFIG_SYSC_R8A7790) += r8a7790-sysc.o obj-$(CONFIG_SYSC_R8A7791) += r8a7791-sysc.o
drivers/soc/renesas/r8a774c0-sysc.c new file +68 -0
68 lines not on this page · raw message
drivers/soc/renesas/rcar-sysc.c +3 -0
@@ -278,6 +278,9 @@ static const struct of_device_id rcar_sysc_matches[] __initconst = { #ifdef CONFIG_SYSC_R8A774A1 { .compatible = "renesas,r8a774a1-sysc", .data = &r8a774a1_sysc_info }, #endif +#ifdef CONFIG_SYSC_R8A774C0 + { .compatible = "renesas,r8a774c0-sysc", .data = &r8a774c0_sysc_info }, +#endif #ifdef CONFIG_SYSC_R8A7779 { .compatible = "renesas,r8a7779-sysc", .data = &r8a7779_sysc_info }, #endif
drivers/soc/renesas/rcar-sysc.h +1 -0
@@ -53,6 +53,7 @@ extern const struct rcar_sysc_info r8a7743_sysc_info;extern const struct rcar_sysc_info r8a7745_sysc_info;extern const struct rcar_sysc_info r8a77470_sysc_info;extern const struct rcar_sysc_info r8a774a1_sysc_info; +extern const struct rcar_sysc_info r8a774c0_sysc_info;extern const struct rcar_sysc_info r8a7779_sysc_info;extern const struct rcar_sysc_info r8a7790_sysc_info;extern const struct rcar_sysc_info r8a7791_sysc_info;
Signature · 1 line
2.7.4
PATCH 15/18 soc: renesas: r8a774c0-sysc: Fix initialization order of 3DG-{A, B}
In reply to Biju DasThe workaround for the wrong hierarchy of the 3DG-{A,B} power domains on RZ/G2E ES1.0 corrected the parent domains. However, the 3DG-{A,B} power domains were still initialized and powered in the wrong order, causing 3DG operation to fail.
Fix this by changing the order in the table at runtime, when running on an affected SoC.
This work is based on the work done by Geert for R-Car E3.
--- drivers/soc/renesas/r8a774c0-sysc.c | 23 ++++------------------- 1 file changed, 4 insertions(+), 19 deletions(-)
drivers/soc/renesas/r8a774c0-sysc.c +4 -19
@@ -28,19 +28,6 @@ static struct rcar_sysc_area r8a774c0_areas[] __initdata = { { "3dg-b", 0x100, 1, R8A774C0_PD_3DG_B, R8A774C0_PD_3DG_A }, }; -static void __init rcar_sysc_fix_parent (struct rcar_sysc_area *areas, -unsigned int num_areas,u8 id, -int new_parent) -{ -unsigned int i; - -for (i =0 ; i < num_areas; i++) -if (areas[i].isr_bit == id) { - areas[i].parent = new_parent; -return ; - } -} -/* Fixups for RZ/G2E ES1.0 revision */ static const struct soc_device_attribute r8a774c0[]__initconst = { { .soc_id = "r8a774c0", .revision = "ES1.0" },
@@ -50,12 +37,10 @@ static const struct soc_device_attribute r8a774c0[] __initconst = {static int __init r8a774c0_sysc_init (void ) {if (soc_device_match (r8a774c0)) { -rcar_sysc_fix_parent (r8a774c0_areas, -ARRAY_SIZE (r8a774c0_areas), -R8A774C0_PD_3DG_A ,R8A774C0_PD_3DG_B ); -rcar_sysc_fix_parent (r8a774c0_areas, -ARRAY_SIZE (r8a774c0_areas), -R8A774C0_PD_3DG_B ,R8A774C0_PD_ALWAYS_ON ); +/* Fix incorrect 3DG hierarchy */ +swap (r8a774c0_areas[6 ], r8a774c0_areas[7 ]); + r8a774c0_areas[6 ].parent =R8A774C0_PD_ALWAYS_ON ; + r8a774c0_areas[7 ].parent =R8A774C0_PD_3DG_B ; }return 0 ;
Signature · 1 line
2.7.4
PATCH 15/18 soc: renesas: r8a774c0-sysc: Fix initialization order of 3DG-{A, B}
Quoted 11 lines · Biju Das
The workaround for the wrong hierarchy of the 3DG-{A,B} power domains on RZ/G2E ES1.0 corrected the parent domains. However, the 3DG-{A,B} power domains were still initialized and powered in the wrong order, causing 3DG operation to fail.
Fix this by changing the order in the table at runtime, when running on an affected SoC.
This work is based on the work done by Geert for R-Car E3.
Fixes f37d211c687588328 ("soc: renesas: rcar-sysc: Add r8a774c0 support")
I prefer directly including good commit (rather than including bad commit and then fixing it up). Let me try to fix it up.
Anyway, I merged this and the rest of the series.
Signature · 2 lines
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
PATCH 16/18 soc: renesas: rcar-rst: Add support for RZ/G2M
In reply to Biju Das--- Documentation/devicetree/bindings/reset/renesas,rst.txt | 1 + drivers/soc/renesas/Kconfig | 6 +++--- drivers/soc/renesas/rcar-rst.c | 4 +++- 3 files changed, 7 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/reset/renesas,rst.txt +1 -0
@@ -18,6 +18,7 @@ Required properties: - "renesas,r8a7743-rst" (RZ/G1M) - "renesas,r8a7745-rst" (RZ/G1E) - "renesas,r8a77470-rst" (RZ/G1C) + - "renesas,r8a774a1-rst" (RZ/G2M) - "renesas,r8a7778-reset-wdt" (R-Car M1A) - "renesas,r8a7779-reset-wdt" (R-Car H1) - "renesas,r8a7790-rst" (R-Car H2)
drivers/soc/renesas/Kconfig +3 -3
@@ -3,9 +3,9 @@ config SOC_RENESAS default y if ARCH_RENESAS select SOC_BUS select RST_RCAR if ARCH_RCAR_GEN1 || ARCH_RCAR_GEN2 || \ - ARCH_R8A7795 || ARCH_R8A7796 || ARCH_R8A77965 || \ - ARCH_R8A77970 || ARCH_R8A77980 || ARCH_R8A77990 || \ - ARCH_R8A77995 + ARCH_R8A774A1 || ARCH_R8A7795 || ARCH_R8A7796 || \ + ARCH_R8A77965 || ARCH_R8A77970 || ARCH_R8A77980 || \ + ARCH_R8A77990 || ARCH_R8A77995 select SYSC_R8A7743 if ARCH_R8A7743 select SYSC_R8A7745 if ARCH_R8A7745 select SYSC_R8A77470 if ARCH_R8A77470
drivers/soc/renesas/rcar-rst.c +3 -1
@@ -41,10 +41,12 @@ static const struct rst_config rcar_rst_gen3 __initconst = { };static const struct of_device_id rcar_rst_matches[]__initconst = { -/* RZ/G is handled like R-Car Gen2 */ +/* RZ/G1 is handled like R-Car Gen2 */ { .compatible ="renesas,r8a7743-rst" , .data = &rcar_rst_gen2 }, { .compatible ="renesas,r8a7745-rst" , .data = &rcar_rst_gen2 }, { .compatible ="renesas,r8a77470-rst" , .data = &rcar_rst_gen2 }, +/* RZ/G2 is handled like R-Car Gen3 */ + { .compatible ="renesas,r8a774a1-rst" , .data = &rcar_rst_gen3 },/* R-Car Gen1 */ { .compatible ="renesas,r8a7778-reset-wdt" , .data = &rcar_rst_gen1 }, { .compatible ="renesas,r8a7779-reset-wdt" , .data = &rcar_rst_gen1 },
Signature · 1 line
2.7.4
PATCH 17/18 dt-bindings: reset: rcar-rst: Document r8a774c0 rst
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
Document bindings for the RZ/G2E (a.k.a. R8A774C0) reset module.
--- Documentation/devicetree/bindings/reset/renesas,rst.txt | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/reset/renesas,rst.txt +1 -0
@@ -19,6 +19,7 @@ Required properties: - "renesas,r8a7745-rst" (RZ/G1E) - "renesas,r8a77470-rst" (RZ/G1C) - "renesas,r8a774a1-rst" (RZ/G2M) + - "renesas,r8a774c0-rst" (RZ/G2E) - "renesas,r8a7778-reset-wdt" (R-Car M1A) - "renesas,r8a7779-reset-wdt" (R-Car H1) - "renesas,r8a7790-rst" (R-Car H2)
Signature · 1 line
2.7.4
PATCH 18/18 soc: renesas: rcar-rst: Add support for RZ/G2E
In reply to Biju DasFrom: Fabrizio Castro <[email protected]>
--- drivers/soc/renesas/Kconfig | 6 +++--- drivers/soc/renesas/rcar-rst.c | 1 + 2 files changed, 4 insertions(+), 3 deletions(-)
drivers/soc/renesas/Kconfig +3 -3
@@ -3,9 +3,9 @@ config SOC_RENESAS default y if ARCH_RENESAS select SOC_BUS select RST_RCAR if ARCH_RCAR_GEN1 || ARCH_RCAR_GEN2 || \ - ARCH_R8A774A1 || ARCH_R8A7795 || ARCH_R8A7796 || \ - ARCH_R8A77965 || ARCH_R8A77970 || ARCH_R8A77980 || \ - ARCH_R8A77990 || ARCH_R8A77995 + ARCH_R8A774A1 || ARCH_R8A774C0 || ARCH_R8A7795 || \ + ARCH_R8A7796 || ARCH_R8A77965 || ARCH_R8A77970 || \ + ARCH_R8A77980 || ARCH_R8A77990 || ARCH_R8A77995 select SYSC_R8A7743 if ARCH_R8A7743 select SYSC_R8A7745 if ARCH_R8A7745 select SYSC_R8A77470 if ARCH_R8A77470
drivers/soc/renesas/rcar-rst.c +1 -0
@@ -47,6 +47,7 @@ static const struct of_device_id rcar_rst_matches[] __initconst = { { .compatible = "renesas,r8a77470-rst", .data = &rcar_rst_gen2 }, /* RZ/G2 is handled like R-Car Gen3 */ { .compatible = "renesas,r8a774a1-rst", .data = &rcar_rst_gen3 }, + { .compatible = "renesas,r8a774c0-rst", .data = &rcar_rst_gen3 }, /* R-Car Gen1 */ { .compatible = "renesas,r8a7778-reset-wdt", .data = &rcar_rst_gen1 }, { .compatible = "renesas,r8a7779-reset-wdt", .data = &rcar_rst_gen1 },
Signature · 1 line
2.7.4