linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Add support to identify RZ/Five SoC
@ 2022-07-22 14:15 Lad Prabhakar
  2022-07-22 14:15 ` [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document " Lad Prabhakar
  2022-07-22 14:15 ` [PATCH v2 2/2] soc: renesas: Identify " Lad Prabhakar
  0 siblings, 2 replies; 6+ messages in thread
From: Lad Prabhakar @ 2022-07-22 14:15 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Krzysztof Kozlowski, linux-renesas-soc, devicetree
  Cc: linux-kernel, Prabhakar, Biju Das, Lad Prabhakar

Hi All,

This patch series adds support to identify the Renesas RZ/Five SoC.

Below is the output tested on SMARC EVK based on RZ/Five SoC:

/ # dmesg  | grep Detect
[    0.065230] Detected Renesas RZ/Five r9a07g043 Rev 0
/ # cat /sys/devices/soc0/family
RZ/Five
/ # cat /sys/devices/soc0/machine
Renesas SMARC EVK based on r9a07g043
/ # cat /sys/devices/soc0/revision
0
/ # cat /sys/devices/soc0/soc_id
r9a07g043
/ # 

v1->v2:
* Fixed review comments pointed by Geert

v1:
https://patchwork.kernel.org/project/linux-renesas-soc/cover/
20220721221212.18491-1-prabhakar.mahadev-lad.rj@bp.renesas.com/

Cheers,
Prabhakar

Lad Prabhakar (2):
  dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document RZ/Five SoC
  soc: renesas: Identify RZ/Five SoC

 .../bindings/soc/renesas/renesas,rzg2l-sysc.yaml    |  4 +---
 drivers/soc/renesas/Kconfig                         | 10 ++++++++++
 drivers/soc/renesas/renesas-soc.c                   | 13 +++++++++++++
 3 files changed, 24 insertions(+), 3 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document RZ/Five SoC
  2022-07-22 14:15 [PATCH v2 0/2] Add support to identify RZ/Five SoC Lad Prabhakar
@ 2022-07-22 14:15 ` Lad Prabhakar
  2022-07-25 23:04   ` Rob Herring
  2022-08-11 15:03   ` Geert Uytterhoeven
  2022-07-22 14:15 ` [PATCH v2 2/2] soc: renesas: Identify " Lad Prabhakar
  1 sibling, 2 replies; 6+ messages in thread
From: Lad Prabhakar @ 2022-07-22 14:15 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Krzysztof Kozlowski, linux-renesas-soc, devicetree
  Cc: linux-kernel, Prabhakar, Biju Das, Lad Prabhakar

Document RZ/Five (R9A07G043) SYSC bindings. The SYSC block found on the
RZ/Five SoC is almost identical to one found on the RZ/G2UL (and alike)
SoC's. "renesas,r9a07g043-sysc" compatible string will be used on the
RZ/Five SoC so to make this clear, update the comment to include RZ/Five
SoC.

The SYSC block on RZ/Five has no interrupts to the core so to accommodate
this SoC make interrupts{,-names} properties optional.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
---
v1->v2:
* Dropped "renesas,r9a07g043-rzfive-sysc" compatible string
* Made interrupts{,-names} properties optional
---
 .../devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml   | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml b/Documentation/devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml
index ce2875c89329..398663d21ab1 100644
--- a/Documentation/devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml
+++ b/Documentation/devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml
@@ -20,7 +20,7 @@ description:
 properties:
   compatible:
     enum:
-      - renesas,r9a07g043-sysc # RZ/G2UL
+      - renesas,r9a07g043-sysc # RZ/G2UL and RZ/Five
       - renesas,r9a07g044-sysc # RZ/G2{L,LC}
       - renesas,r9a07g054-sysc # RZ/V2L
 
@@ -44,8 +44,6 @@ properties:
 required:
   - compatible
   - reg
-  - interrupts
-  - interrupt-names
 
 additionalProperties: false
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v2 2/2] soc: renesas: Identify RZ/Five SoC
  2022-07-22 14:15 [PATCH v2 0/2] Add support to identify RZ/Five SoC Lad Prabhakar
  2022-07-22 14:15 ` [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document " Lad Prabhakar
@ 2022-07-22 14:15 ` Lad Prabhakar
  2022-08-11 15:04   ` Geert Uytterhoeven
  1 sibling, 1 reply; 6+ messages in thread
From: Lad Prabhakar @ 2022-07-22 14:15 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Krzysztof Kozlowski, linux-renesas-soc, devicetree
  Cc: linux-kernel, Prabhakar, Biju Das, Lad Prabhakar

Add support for identifying the (R9A07G043) RZ/Five SoC.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
---
v1->v2
* Replaced RISCV -> RISCV
* Reused "renesas,r9a07g043-sysc" string for RZ/Five detection
---
 drivers/soc/renesas/Kconfig       | 10 ++++++++++
 drivers/soc/renesas/renesas-soc.c | 13 +++++++++++++
 2 files changed, 23 insertions(+)

diff --git a/drivers/soc/renesas/Kconfig b/drivers/soc/renesas/Kconfig
index 390f52109cb7..f95a1337450d 100644
--- a/drivers/soc/renesas/Kconfig
+++ b/drivers/soc/renesas/Kconfig
@@ -333,6 +333,16 @@ config ARCH_R9A09G011
 
 endif # ARM64
 
+if RISCV
+
+config ARCH_R9A07G043
+	bool "RISC-V Platform support for RZ/Five"
+	select ARCH_RZG2L
+	help
+	  This enables support for the Renesas RZ/Five SoC.
+
+endif # RISCV
+
 config RST_RCAR
 	bool "Reset Controller support for R-Car" if COMPILE_TEST
 
diff --git a/drivers/soc/renesas/renesas-soc.c b/drivers/soc/renesas/renesas-soc.c
index d171f1b635c7..c0e2c62c76c9 100644
--- a/drivers/soc/renesas/renesas-soc.c
+++ b/drivers/soc/renesas/renesas-soc.c
@@ -50,6 +50,10 @@ static const struct renesas_family fam_rza2 __initconst __maybe_unused = {
 	.name	= "RZ/A2",
 };
 
+static const struct renesas_family fam_rzfive __initconst __maybe_unused = {
+	.name	= "RZ/Five",
+};
+
 static const struct renesas_family fam_rzg1 __initconst __maybe_unused = {
 	.name	= "RZ/G1",
 	.reg	= 0xff000044,		/* PRR (Product Register) */
@@ -102,6 +106,11 @@ static const struct renesas_soc soc_rmobile_a1 __initconst __maybe_unused = {
 	.id	= 0x40,
 };
 
+static const struct renesas_soc soc_rz_five __initconst __maybe_unused = {
+	.family = &fam_rzfive,
+	.id     = 0x847c447,
+};
+
 static const struct renesas_soc soc_rz_g1h __initconst __maybe_unused = {
 	.family	= &fam_rzg1,
 	.id	= 0x45,
@@ -358,8 +367,12 @@ static const struct of_device_id renesas_socs[] __initconst = {
 	{ .compatible = "renesas,r8a779g0",	.data = &soc_rcar_v4h },
 #endif
 #if defined(CONFIG_ARCH_R9A07G043)
+#ifdef CONFIG_RISCV
+	{ .compatible = "renesas,r9a07g043",	.data = &soc_rz_five },
+#else
 	{ .compatible = "renesas,r9a07g043",	.data = &soc_rz_g2ul },
 #endif
+#endif
 #if defined(CONFIG_ARCH_R9A07G044)
 	{ .compatible = "renesas,r9a07g044",	.data = &soc_rz_g2l },
 #endif
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document RZ/Five SoC
  2022-07-22 14:15 ` [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document " Lad Prabhakar
@ 2022-07-25 23:04   ` Rob Herring
  2022-08-11 15:03   ` Geert Uytterhoeven
  1 sibling, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-07-25 23:04 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, devicetree, linux-kernel, Prabhakar,
	Geert Uytterhoeven, Krzysztof Kozlowski, Biju Das, Rob Herring,
	linux-renesas-soc

On Fri, 22 Jul 2022 15:15:05 +0100, Lad Prabhakar wrote:
> Document RZ/Five (R9A07G043) SYSC bindings. The SYSC block found on the
> RZ/Five SoC is almost identical to one found on the RZ/G2UL (and alike)
> SoC's. "renesas,r9a07g043-sysc" compatible string will be used on the
> RZ/Five SoC so to make this clear, update the comment to include RZ/Five
> SoC.
> 
> The SYSC block on RZ/Five has no interrupts to the core so to accommodate
> this SoC make interrupts{,-names} properties optional.
> 
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> ---
> v1->v2:
> * Dropped "renesas,r9a07g043-rzfive-sysc" compatible string
> * Made interrupts{,-names} properties optional
> ---
>  .../devicetree/bindings/soc/renesas/renesas,rzg2l-sysc.yaml   | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document RZ/Five SoC
  2022-07-22 14:15 ` [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document " Lad Prabhakar
  2022-07-25 23:04   ` Rob Herring
@ 2022-08-11 15:03   ` Geert Uytterhoeven
  1 sibling, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2022-08-11 15:03 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, Rob Herring, Krzysztof Kozlowski, Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Linux Kernel Mailing List, Prabhakar, Biju Das

On Fri, Jul 22, 2022 at 4:15 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> Document RZ/Five (R9A07G043) SYSC bindings. The SYSC block found on the
> RZ/Five SoC is almost identical to one found on the RZ/G2UL (and alike)
> SoC's. "renesas,r9a07g043-sysc" compatible string will be used on the
> RZ/Five SoC so to make this clear, update the comment to include RZ/Five
> SoC.
>
> The SYSC block on RZ/Five has no interrupts to the core so to accommodate
> this SoC make interrupts{,-names} properties optional.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> ---
> v1->v2:
> * Dropped "renesas,r9a07g043-rzfive-sysc" compatible string
> * Made interrupts{,-names} properties optional

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v6.1.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v2 2/2] soc: renesas: Identify RZ/Five SoC
  2022-07-22 14:15 ` [PATCH v2 2/2] soc: renesas: Identify " Lad Prabhakar
@ 2022-08-11 15:04   ` Geert Uytterhoeven
  0 siblings, 0 replies; 6+ messages in thread
From: Geert Uytterhoeven @ 2022-08-11 15:04 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, Rob Herring, Krzysztof Kozlowski, Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Linux Kernel Mailing List, Prabhakar, Biju Das

On Fri, Jul 22, 2022 at 4:15 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> Add support for identifying the (R9A07G043) RZ/Five SoC.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> ---
> v1->v2
> * Replaced RISCV -> RISCV
> * Reused "renesas,r9a07g043-sysc" string for RZ/Five detection

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v6.1.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-08-11 15:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-22 14:15 [PATCH v2 0/2] Add support to identify RZ/Five SoC Lad Prabhakar
2022-07-22 14:15 ` [PATCH v2 1/2] dt-bindings: soc: renesas: renesas,rzg2l-sysc: Document " Lad Prabhakar
2022-07-25 23:04   ` Rob Herring
2022-08-11 15:03   ` Geert Uytterhoeven
2022-07-22 14:15 ` [PATCH v2 2/2] soc: renesas: Identify " Lad Prabhakar
2022-08-11 15:04   ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).