* [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock
2022-02-04 16:17 [PATCH 0/6] ARM: r9a06g032: add support for the watchdogs Jean-Jacques Hiblot
@ 2022-02-04 16:18 ` Jean-Jacques Hiblot
2022-02-07 16:07 ` Geert Uytterhoeven
2022-02-11 14:50 ` Rob Herring
2022-02-04 16:18 ` [PATCH 3/6] dt-bindings: watchdog: renesas,wdt: Add support for RZ/N1 Jean-Jacques Hiblot
` (2 subsequent siblings)
3 siblings, 2 replies; 10+ messages in thread
From: Jean-Jacques Hiblot @ 2022-02-04 16:18 UTC (permalink / raw)
To: geert+renesas, linux-kernel; +Cc: Jean-Jacques Hiblot, Rob Herring, devicetree
This clock is actually the REF_SYNC_D8 clock.
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
---
include/dt-bindings/clock/r9a06g032-sysctrl.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/dt-bindings/clock/r9a06g032-sysctrl.h b/include/dt-bindings/clock/r9a06g032-sysctrl.h
index 90c0f3dc1ba1..d9d7b8b4f426 100644
--- a/include/dt-bindings/clock/r9a06g032-sysctrl.h
+++ b/include/dt-bindings/clock/r9a06g032-sysctrl.h
@@ -74,6 +74,7 @@
#define R9A06G032_CLK_DDRPHY_PCLK 81 /* AKA CLK_REF_SYNC_D4 */
#define R9A06G032_CLK_FW 81 /* AKA CLK_REF_SYNC_D4 */
#define R9A06G032_CLK_CRYPTO 81 /* AKA CLK_REF_SYNC_D4 */
+#define R9A06G032_CLK_WATCHDOG 82 /* AKA CLK_REF_SYNC_D8 */
#define R9A06G032_CLK_A7MP 84 /* AKA DIV_CA7 */
#define R9A06G032_HCLK_CAN0 85
#define R9A06G032_HCLK_CAN1 86
--
2.25.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock
2022-02-04 16:18 ` [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock Jean-Jacques Hiblot
@ 2022-02-07 16:07 ` Geert Uytterhoeven
2022-02-11 14:50 ` Rob Herring
1 sibling, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2022-02-07 16:07 UTC (permalink / raw)
To: Jean-Jacques Hiblot
Cc: Geert Uytterhoeven, Linux Kernel Mailing List, Rob Herring,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS
Hi Jean-Jacques,
On Fri, Feb 4, 2022 at 5:18 PM Jean-Jacques Hiblot
<jjhiblot@traphandler.com> wrote:
> This clock is actually the REF_SYNC_D8 clock.
>
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
Thanks for your patch!
> --- a/include/dt-bindings/clock/r9a06g032-sysctrl.h
> +++ b/include/dt-bindings/clock/r9a06g032-sysctrl.h
> @@ -74,6 +74,7 @@
> #define R9A06G032_CLK_DDRPHY_PCLK 81 /* AKA CLK_REF_SYNC_D4 */
> #define R9A06G032_CLK_FW 81 /* AKA CLK_REF_SYNC_D4 */
> #define R9A06G032_CLK_CRYPTO 81 /* AKA CLK_REF_SYNC_D4 */
> +#define R9A06G032_CLK_WATCHDOG 82 /* AKA CLK_REF_SYNC_D8 */
> #define R9A06G032_CLK_A7MP 84 /* AKA DIV_CA7 */
> #define R9A06G032_HCLK_CAN0 85
> #define R9A06G032_HCLK_CAN1 86
I couldn't find this in the documentation, so I have to trust you on this.
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] 10+ messages in thread* Re: [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock
2022-02-04 16:18 ` [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock Jean-Jacques Hiblot
2022-02-07 16:07 ` Geert Uytterhoeven
@ 2022-02-11 14:50 ` Rob Herring
1 sibling, 0 replies; 10+ messages in thread
From: Rob Herring @ 2022-02-11 14:50 UTC (permalink / raw)
To: Jean-Jacques Hiblot; +Cc: devicetree, linux-kernel, Rob Herring, geert+renesas
On Fri, 04 Feb 2022 17:18:00 +0100, Jean-Jacques Hiblot wrote:
> This clock is actually the REF_SYNC_D8 clock.
>
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
> ---
> include/dt-bindings/clock/r9a06g032-sysctrl.h | 1 +
> 1 file changed, 1 insertion(+)
>
Acked-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 3/6] dt-bindings: watchdog: renesas,wdt: Add support for RZ/N1
2022-02-04 16:17 [PATCH 0/6] ARM: r9a06g032: add support for the watchdogs Jean-Jacques Hiblot
2022-02-04 16:18 ` [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock Jean-Jacques Hiblot
@ 2022-02-04 16:18 ` Jean-Jacques Hiblot
2022-02-07 16:09 ` Geert Uytterhoeven
2022-02-04 16:18 ` [PATCH 4/6] ARM: dts: r9a06g032: Add the watchdog nodes Jean-Jacques Hiblot
2022-02-04 16:18 ` [PATCH 5/6] ARM: dts: r9a06g032-rzn1d400-db: Enable watchdog0 with a 10s timeout Jean-Jacques Hiblot
3 siblings, 1 reply; 10+ messages in thread
From: Jean-Jacques Hiblot @ 2022-02-04 16:18 UTC (permalink / raw)
To: geert+renesas, Wim Van Sebroeck, Guenter Roeck, Wolfram Sang
Cc: Jean-Jacques Hiblot, Rob Herring, linux-watchdog, devicetree,
linux-kernel
Describe the WDT hardware in the RZ/N1 series.
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
---
Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml b/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml
index 91a98ccd4226..11e1c9f101a7 100644
--- a/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml
+++ b/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml
@@ -19,6 +19,9 @@ properties:
- renesas,r7s9210-wdt # RZ/A2
- const: renesas,rza-wdt # RZ/A
+ - items:
+ - const: renesas,rzn1-wdt # RZ/N1
+
- items:
- enum:
- renesas,r9a07g044-wdt # RZ/G2{L,LC}
@@ -89,6 +92,7 @@ allOf:
contains:
enum:
- renesas,rza-wdt
+ - renesas,rzn1-wdt
then:
required:
- power-domains
--
2.25.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 3/6] dt-bindings: watchdog: renesas,wdt: Add support for RZ/N1
2022-02-04 16:18 ` [PATCH 3/6] dt-bindings: watchdog: renesas,wdt: Add support for RZ/N1 Jean-Jacques Hiblot
@ 2022-02-07 16:09 ` Geert Uytterhoeven
0 siblings, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2022-02-07 16:09 UTC (permalink / raw)
To: Jean-Jacques Hiblot
Cc: Wim Van Sebroeck, Guenter Roeck, Wolfram Sang, Rob Herring,
Linux Watchdog Mailing List,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Linux Kernel Mailing List
Hi Jean-Jacques,
On Fri, Feb 4, 2022 at 5:18 PM Jean-Jacques Hiblot
<jjhiblot@traphandler.com> wrote:
> Describe the WDT hardware in the RZ/N1 series.
>
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
Thanks for your patch!
> --- a/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml
> +++ b/Documentation/devicetree/bindings/watchdog/renesas,wdt.yaml
> @@ -19,6 +19,9 @@ properties:
> - renesas,r7s9210-wdt # RZ/A2
> - const: renesas,rza-wdt # RZ/A
>
> + - items:
> + - const: renesas,rzn1-wdt # RZ/N1
I think it would be good to have an SoC-specific compatible value
("renesas,r9a06g032-wdt") in addition to the family-specific one.
> +
> - items:
> - enum:
> - renesas,r9a07g044-wdt # RZ/G2{L,LC}
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] 10+ messages in thread
* [PATCH 4/6] ARM: dts: r9a06g032: Add the watchdog nodes
2022-02-04 16:17 [PATCH 0/6] ARM: r9a06g032: add support for the watchdogs Jean-Jacques Hiblot
2022-02-04 16:18 ` [PATCH 2/6] dt-bindings: clock: r9a06g032: Add the definition of the watchdog clock Jean-Jacques Hiblot
2022-02-04 16:18 ` [PATCH 3/6] dt-bindings: watchdog: renesas,wdt: Add support for RZ/N1 Jean-Jacques Hiblot
@ 2022-02-04 16:18 ` Jean-Jacques Hiblot
2022-02-07 16:12 ` Geert Uytterhoeven
2022-02-04 16:18 ` [PATCH 5/6] ARM: dts: r9a06g032-rzn1d400-db: Enable watchdog0 with a 10s timeout Jean-Jacques Hiblot
3 siblings, 1 reply; 10+ messages in thread
From: Jean-Jacques Hiblot @ 2022-02-04 16:18 UTC (permalink / raw)
To: geert+renesas, Magnus Damm, Rob Herring
Cc: Jean-Jacques Hiblot, linux-renesas-soc, devicetree, linux-kernel
This SOC includes 2 watchdog controllers (one per A7 core).
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
---
arch/arm/boot/dts/r9a06g032.dtsi | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/arch/arm/boot/dts/r9a06g032.dtsi b/arch/arm/boot/dts/r9a06g032.dtsi
index c47896e4ab58..54c91b46a5d0 100644
--- a/arch/arm/boot/dts/r9a06g032.dtsi
+++ b/arch/arm/boot/dts/r9a06g032.dtsi
@@ -184,6 +184,22 @@ gic: interrupt-controller@44101000 {
interrupts =
<GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)>;
};
+
+ wdt0: watchdog@40008000 {
+ compatible = "renesas,rzn1-wdt";
+ reg = <0x40008000 0x1000>;
+ interrupts = <GIC_SPI 73 IRQ_TYPE_EDGE_RISING>;
+ clocks = <&sysctrl R9A06G032_CLK_WATCHDOG>;
+ status = "disabled";
+ };
+
+ wdt1: watchdog@40009000 {
+ compatible = "renesas,rzn1-wdt";
+ reg = <0x40009000 0x1000>;
+ interrupts = <GIC_SPI 74 IRQ_TYPE_EDGE_RISING>;
+ clocks = <&sysctrl R9A06G032_CLK_WATCHDOG>;
+ status = "disabled";
+ };
};
timer {
--
2.25.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 4/6] ARM: dts: r9a06g032: Add the watchdog nodes
2022-02-04 16:18 ` [PATCH 4/6] ARM: dts: r9a06g032: Add the watchdog nodes Jean-Jacques Hiblot
@ 2022-02-07 16:12 ` Geert Uytterhoeven
0 siblings, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2022-02-07 16:12 UTC (permalink / raw)
To: Jean-Jacques Hiblot
Cc: Magnus Damm, Rob Herring, Linux-Renesas,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Linux Kernel Mailing List
Hi Jean-Jacques,
On Fri, Feb 4, 2022 at 5:18 PM Jean-Jacques Hiblot
<jjhiblot@traphandler.com> wrote:
> This SOC includes 2 watchdog controllers (one per A7 core).
>
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
Thanks for your patch!
> --- a/arch/arm/boot/dts/r9a06g032.dtsi
> +++ b/arch/arm/boot/dts/r9a06g032.dtsi
> @@ -184,6 +184,22 @@ gic: interrupt-controller@44101000 {
> interrupts =
> <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)>;
> };
> +
> + wdt0: watchdog@40008000 {
Please insert these nodes before the system-controller@4000c000
node, to preserve sort order (by unit address).
> + compatible = "renesas,rzn1-wdt";
"renesas,r9a06g032-wdt", "renesas,rzn1-wdt"
as per my comments on the DT bindings patch.
> + reg = <0x40008000 0x1000>;
> + interrupts = <GIC_SPI 73 IRQ_TYPE_EDGE_RISING>;
> + clocks = <&sysctrl R9A06G032_CLK_WATCHDOG>;
> + status = "disabled";
> + };
> +
> + wdt1: watchdog@40009000 {
> + compatible = "renesas,rzn1-wdt";
> + reg = <0x40009000 0x1000>;
> + interrupts = <GIC_SPI 74 IRQ_TYPE_EDGE_RISING>;
> + clocks = <&sysctrl R9A06G032_CLK_WATCHDOG>;
> + status = "disabled";
> + };
> };
>
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] 10+ messages in thread
* [PATCH 5/6] ARM: dts: r9a06g032-rzn1d400-db: Enable watchdog0 with a 10s timeout
2022-02-04 16:17 [PATCH 0/6] ARM: r9a06g032: add support for the watchdogs Jean-Jacques Hiblot
` (2 preceding siblings ...)
2022-02-04 16:18 ` [PATCH 4/6] ARM: dts: r9a06g032: Add the watchdog nodes Jean-Jacques Hiblot
@ 2022-02-04 16:18 ` Jean-Jacques Hiblot
2022-02-07 16:15 ` Geert Uytterhoeven
3 siblings, 1 reply; 10+ messages in thread
From: Jean-Jacques Hiblot @ 2022-02-04 16:18 UTC (permalink / raw)
To: geert+renesas, Magnus Damm, Rob Herring
Cc: Jean-Jacques Hiblot, linux-renesas-soc, devicetree, linux-kernel
10s seems a reasonable value for a watchdog.
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
---
arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts b/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts
index 4e57ae2688fc..5c8f46b20acc 100644
--- a/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts
+++ b/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts
@@ -23,6 +23,11 @@ aliases {
};
};
+&wdt0 {
+ timeout-sec = <10>;
+ status = "okay";
+};
+
&uart0 {
status = "okay";
};
--
2.25.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 5/6] ARM: dts: r9a06g032-rzn1d400-db: Enable watchdog0 with a 10s timeout
2022-02-04 16:18 ` [PATCH 5/6] ARM: dts: r9a06g032-rzn1d400-db: Enable watchdog0 with a 10s timeout Jean-Jacques Hiblot
@ 2022-02-07 16:15 ` Geert Uytterhoeven
0 siblings, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2022-02-07 16:15 UTC (permalink / raw)
To: Jean-Jacques Hiblot
Cc: Magnus Damm, Rob Herring, Linux-Renesas,
open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
Linux Kernel Mailing List
Hi Jean-Jacques,
Thanks for your patch!
On Fri, Feb 4, 2022 at 5:18 PM Jean-Jacques Hiblot
<jjhiblot@traphandler.com> wrote:
> 10s seems a reasonable value for a watchdog.
All other Renesas DTS files use 60s. Would 60s be OK for you?
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
> --- a/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts
> +++ b/arch/arm/boot/dts/r9a06g032-rzn1d400-db.dts
> @@ -23,6 +23,11 @@ aliases {
> };
> };
>
> +&wdt0 {
Please insert below "uart0", to preserve sort order (alphabetically).
> + timeout-sec = <10>;
> + status = "okay";
> +};
> +
> &uart0 {
> status = "okay";
> };
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] 10+ messages in thread