From: Alice Guo <[email protected]>

Introduce wdog3, wdog4, and wdog5 aliases and mark the corresponding
nodes with bootph-all to enable imx_wdog_alias_to_addr() to resolve the
watchdog register base addresses via the device tree.

When CONFIG_OF_UPSTREAM is disabled, upstream device tree files are not
used. Therefore, wdog4 and wdog5 nodes need to be added directly to
arch/arm/dts/imx93.dtsi.

Signed-off-by: Alice Guo <[email protected]>
---
 arch/arm/dts/imx93-u-boot.dtsi | 18 ++++++++++++++++++
 arch/arm/dts/imx93.dtsi        | 21 +++++++++++++++++++++
 2 files changed, 39 insertions(+)

diff --git a/arch/arm/dts/imx93-u-boot.dtsi b/arch/arm/dts/imx93-u-boot.dtsi
index dc86746ac90..c946f45c7f0 100644
--- a/arch/arm/dts/imx93-u-boot.dtsi
+++ b/arch/arm/dts/imx93-u-boot.dtsi
@@ -4,6 +4,12 @@
  */
 
 / {
+       aliases {
+               wdog3 = &wdog3;
+               wdog4 = &wdog4;
+               wdog5 = &wdog5;
+       };
+
        binman: binman {
                multiple-images;
 
@@ -96,3 +102,15 @@
                               0x000001b2 0x800001b6>;
        #thermal-sensor-cells = <1>;
 };
+
+&wdog3 {
+       bootph-all;
+};
+
+&wdog4 {
+       bootph-all;
+};
+
+&wdog5 {
+       bootph-all;
+};
diff --git a/arch/arm/dts/imx93.dtsi b/arch/arm/dts/imx93.dtsi
index d6964714ea0..549a30fc9f0 100644
--- a/arch/arm/dts/imx93.dtsi
+++ b/arch/arm/dts/imx93.dtsi
@@ -41,6 +41,9 @@
                serial5 = &lpuart6;
                serial6 = &lpuart7;
                serial7 = &lpuart8;
+               wdog3 = &wdog3;
+               wdog4 = &wdog4;
+               wdog5 = &wdog5;
        };
 
        cpus {
@@ -414,6 +417,24 @@
                                timeout-sec = <40>;
                        };
 
+                       wdog4: watchdog@424a0000 {
+                               compatible = "fsl,imx93-wdt";
+                               reg = <0x424a0000 0x10000>;
+                               interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_HIGH>;
+                               clocks = <&clk IMX93_CLK_WDOG4_GATE>;
+                               timeout-sec = <40>;
+                               status = "disabled";
+                       };
+
+                       wdog5: watchdog@424b0000 {
+                               compatible = "fsl,imx93-wdt";
+                               reg = <0x424b0000 0x10000>;
+                               interrupts = <GIC_SPI 81 IRQ_TYPE_LEVEL_HIGH>;
+                               clocks = <&clk IMX93_CLK_WDOG5_GATE>;
+                               timeout-sec = <40>;
+                               status = "disabled";
+                       };
+
                        tpm3: pwm@424e0000 {
                                compatible = "fsl,imx7ulp-pwm";
                                reg = <0x424e0000 0x1000>;

-- 
2.43.0

Reply via email to