imx: Switch watchdog addressing from macros to devicetree
v3 cover imx: Switch watchdog addressing from macros to devicetree
CI: https://github.com/u-boot/u-boot/pull/967/checks
The watchdog DT changes have already been posted to the upstream Linux kernel, addressing the concern about avoiding unnecessary growth of u-boot.dtsi. Linux DT changes are available at:
https://lore.kernel.org/all/[email protected]/T/#u
Changes for v2:
- Iterate all watchdog nodes in device tree instead of wdog alias
- Delete non-DM implementation of the ULP watchdog driver
Changes for v3:
- Convert imx7ulp, imx91, imx93-frdm and imx93_var_som to CONFIG_OF_UPSTREAM
---
Alice Guo (9):
imx7ulp: Switch to OF_UPSTREAM
imx91: Switch to OF_UPSTREAM
imx93-frdm: Switch to OF_UPSTREAM
imx93_var_som: Switch to OF_UPSTREAM
imx: soc: Get watchdog base addresses from device tree
arm: dts: imx: Update watchdog nodes for dynamic base address lookup
watchdog: ulp_wdog: Use driver model for reset_cpu()
arm: dts: imx: Enable watchdog driver model support
imx: Remove hardcoded watchdog base address macros
arch/arm/dts/Makefile | 4 - arch/arm/dts/imx7ulp-com-u-boot.dtsi | 2 + arch/arm/dts/imx7ulp-com.dts | 79 -- arch/arm/dts/imx7ulp-evk-u-boot.dtsi | 6 + arch/arm/dts/imx7ulp-evk.dts | 133 ---- arch/arm/dts/imx7ulp-u-boot.dtsi | 17 + arch/arm/dts/imx7ulp.dtsi | 461 ------------ arch/arm/dts/imx8ulp-evk-u-boot.dtsi | 4 - arch/arm/dts/imx8ulp-u-boot.dtsi | 4 + arch/arm/dts/imx91-11x11-evk.dts | 875 ---------------------- arch/arm/dts/imx91-11x11-frdm.dts | 773 ------------------- arch/arm/dts/imx91-pinfunc.h | 770 ------------------- arch/arm/dts/imx91-u-boot.dtsi | 12 + arch/arm/dts/imx91.dtsi | 53 -- arch/arm/dts/imx93-11x11-frdm.dts | 603 --------------- arch/arm/dts/imx93-u-boot.dtsi | 12 + arch/arm/dts/imx93-var-som-symphony.dts | 323 -------- arch/arm/dts/imx93-var-som.dtsi | 111 --- arch/arm/dts/imx93.dtsi | 906 ----------------------- arch/arm/dts/imx943-evk-u-boot.dtsi | 4 - arch/arm/dts/imx943-u-boot.dtsi | 19 + arch/arm/dts/imx95-15x15-evk-u-boot.dtsi | 4 - arch/arm/dts/imx95-19x19-evk-u-boot.dtsi | 4 - arch/arm/dts/imx95-toradex-smarc-dev-u-boot.dtsi | 4 - arch/arm/dts/imx95-u-boot.dtsi | 14 + arch/arm/dts/imx95-verdin-wifi-dev-u-boot.dtsi | 4 - arch/arm/dts/imx952-u-boot.dtsi | 14 + arch/arm/include/asm/arch-imx8ulp/imx-regs.h | 2 - arch/arm/include/asm/arch-imx9/imx-regs.h | 9 - arch/arm/mach-imx/imx8ulp/soc.c | 14 +- arch/arm/mach-imx/imx9/Kconfig | 4 + arch/arm/mach-imx/imx9/scmi/soc.c | 15 +- arch/arm/mach-imx/imx9/soc.c | 16 +- arch/arm/mach-imx/mx7ulp/Kconfig | 2 + arch/arm/mach-imx/mx7ulp/soc.c | 24 +- configs/imx8ulp_evk_defconfig | 1 + configs/imx91_11x11_evk_defconfig | 2 +- configs/imx91_11x11_evk_inline_ecc_defconfig | 2 +- configs/imx91_11x11_frdm_defconfig | 2 +- configs/imx93-phycore_defconfig | 1 + configs/imx93_frdm_defconfig | 2 +- configs/imx93_var_som_defconfig | 2 +- configs/imx943_evk_defconfig | 1 + configs/imx95_15x15_evk_defconfig | 1 + configs/imx95_evk.config | 1 + configs/mx7ulp_com_defconfig | 3 +- configs/mx7ulp_evk_defconfig | 2 +- configs/mx7ulp_evk_plugin_defconfig | 2 +- configs/toradex-smarc-imx95_defconfig | 1 + configs/verdin-imx95_defconfig | 1 + drivers/watchdog/ulp_wdog.c | 79 +- include/configs/imx8ulp_evk.h | 2 - include/configs/imx91_evk.h | 2 - include/configs/imx91_frdm.h | 2 - include/configs/imx93_evk.h | 3 - include/configs/imx93_frdm.h | 3 - include/configs/imx93_qsb.h | 2 - include/configs/imx93_var_som.h | 3 - include/configs/imx94_evk.h | 3 - include/configs/imx95_evk.h | 2 - include/configs/kontron-osm-s-mx93.h | 2 - include/configs/mx7ulp_com.h | 3 - include/configs/mx7ulp_evk.h | 3 - include/configs/phycore_imx91_93.h | 3 - include/configs/toradex-smarc-imx95.h | 2 - 65 files changed, 206 insertions(+), 5233 deletions(-)
---
base-commit: 5732bd0f457b4c671e46574d64d4acb099c0f0a5
change-id: 20260512-wdt-dbbb375e9dba
Best regards,
Signature · 1 line
Alice Guo <[email protected]>
PATCH v3 1/9 imx7ulp: Switch to OF_UPSTREAM
From: Alice Guo <[email protected]>
Migrate i.MX7ULP boards to use OF_UPSTREAM feature, which allows U-Boot to directly use device trees from the Linux kernel upstream.
--- arch/arm/dts/imx7ulp-com.dts | 79 ------ arch/arm/dts/imx7ulp-evk.dts | 133 ----------- arch/arm/dts/imx7ulp.dtsi | 461 ------------------------------------ arch/arm/mach-imx/mx7ulp/Kconfig | 2 + configs/mx7ulp_com_defconfig | 2 +- configs/mx7ulp_evk_defconfig | 2 +- configs/mx7ulp_evk_plugin_defconfig | 2 +- 7 files changed, 5 insertions(+), 676 deletions(-)
arch/arm/dts/imx7ulp-com.dts deleted +0 -79
@@ -1,79 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -// -// Copyright 2019 NXP - -/dts-v1/; - -#include "imx7ulp.dtsi" -#include <dt-bindings/input/input.h> - -/ { - model = "Embedded Artists i.MX7ULP COM"; - compatible = "ea,imx7ulp-com", "fsl,imx7ulp"; - - chosen { - stdout-path = &lpuart4; - }; - - memory@60000000 { - device_type = "memory"; - reg = <0x60000000 0x4000000>; - }; -}; - -&lpuart4 { - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_lpuart4>; - status = "okay"; -}; - -&usbotg1 { - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_usbotg1_id>; - srp-disable; - hnp-disable; - adp-disable; - status = "okay"; -}; - -&usdhc0 { - assigned-clocks = <&pcc2 IMX7ULP_CLK_USDHC0>; - assigned-clock-parents = <&scg1 IMX7ULP_CLK_APLL_PFD1>; - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_usdhc0>; - non-removable; - bus-width = <8>; - no-1-8-v; - status = "okay"; -}; - -&iomuxc1 { - pinctrl_lpuart4: lpuart4grp { - fsl,pins = < - IMX7ULP_PAD_PTC3__LPUART4_RX 0x3 - IMX7ULP_PAD_PTC2__LPUART4_TX 0x3 - >; - }; - - pinctrl_usbotg1_id: otg1idgrp { - fsl,pins = < - IMX7ULP_PAD_PTC13__USB0_ID 0x10003 - >; - }; - - pinctrl_usdhc0: usdhc0grp { - fsl,pins = < - IMX7ULP_PAD_PTD1__SDHC0_CMD 0x43 - IMX7ULP_PAD_PTD2__SDHC0_CLK 0x10042 - IMX7ULP_PAD_PTD3__SDHC0_D7 0x43 - IMX7ULP_PAD_PTD4__SDHC0_D6 0x43 - IMX7ULP_PAD_PTD5__SDHC0_D5 0x43 - IMX7ULP_PAD_PTD6__SDHC0_D4 0x43 - IMX7ULP_PAD_PTD7__SDHC0_D3 0x43 - IMX7ULP_PAD_PTD8__SDHC0_D2 0x43 - IMX7ULP_PAD_PTD9__SDHC0_D1 0x43 - IMX7ULP_PAD_PTD10__SDHC0_D0 0x43 - IMX7ULP_PAD_PTD11__SDHC0_DQS 0x42 - >; - }; -};
arch/arm/dts/imx7ulp-evk.dts deleted +0 -133
133 lines not on this page · raw message
arch/arm/dts/imx7ulp.dtsi deleted +0 -461
461 lines not on this page · raw message
arch/arm/mach-imx/mx7ulp/Kconfig +2 -0
@@ -35,6 +35,7 @@ config TARGET_MX7ULP_COM select SPL_SEPARATE_BSS if SPL select SPL_SERIAL if SPL select SUPPORT_SPL + imply OF_UPSTREAM config TARGET_MX7ULP_EVK bool "Support mx7ulp EVK board"
@@ -42,6 +43,7 @@ config TARGET_MX7ULP_EVK select SYS_ARCH_TIMER select FSL_CAAM select ARCH_MISC_INIT + imply OF_UPSTREAM endchoice
configs/mx7ulp_com_defconfig +1 -1
@@ -7,7 +7,7 @@ CONFIG_SF_DEFAULT_SPEED=40000000 CONFIG_ENV_SIZE=0x2000 CONFIG_ENV_OFFSET=0xC0000 CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx7ulp-com" +CONFIG_DEFAULT_DEVICE_TREE="nxp/imx/imx7ulp-com" CONFIG_LDO_ENABLED_MODE=y CONFIG_TARGET_MX7ULP_COM=y CONFIG_SYS_BOOTM_LEN=0x1000000
configs/mx7ulp_evk_defconfig +1 -1
@@ -6,7 +6,7 @@ CONFIG_NR_DRAM_BANKS=1 CONFIG_ENV_SIZE=0x2000 CONFIG_ENV_OFFSET=0xC0000 CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx7ulp-evk" +CONFIG_DEFAULT_DEVICE_TREE="nxp/imx/imx7ulp-evk" CONFIG_TARGET_MX7ULP_EVK=y CONFIG_SYS_BOOTM_LEN=0x1000000 CONFIG_SYS_LOAD_ADDR=0x60800000
configs/mx7ulp_evk_plugin_defconfig +1 -1
@@ -6,7 +6,7 @@ CONFIG_NR_DRAM_BANKS=1 CONFIG_ENV_SIZE=0x2000 CONFIG_ENV_OFFSET=0xC0000 CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx7ulp-evk" +CONFIG_DEFAULT_DEVICE_TREE="nxp/imx/imx7ulp-evk" CONFIG_TARGET_MX7ULP_EVK=y CONFIG_SYS_BOOTM_LEN=0x1000000 CONFIG_SYS_LOAD_ADDR=0x60800000
Signature · 1 line
2.34.1
Re: [PATCH v3 1/9] imx7ulp: Switch to OF_UPSTREAM
Quoted 7 lines · On Tue, May 12, 2026 at 11:10:08AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Migrate i.MX7ULP boards to use
OF_UPSTREAMfeature, which allows U-Boot to directly use device trees from the Linux kernel upstream.Signed-off-by Alice Guo <[email protected]>---
Quoted 9 lines
arch/arm/dts/imx7ulp-com.dts | 79 ------ arch/arm/dts/imx7ulp-evk.dts | 133 ----------- arch/arm/dts/imx7ulp.dtsi | 461 ------------------------------------ arch/arm/mach-imx/mx7ulp/Kconfig | 2 + configs/mx7ulp_com_defconfig | 2 +- configs/mx7ulp_evk_defconfig | 2 +- configs/mx7ulp_evk_plugin_defconfig | 2 +- 7 files changed, 5 insertions(+), 676 deletions(-)
PATCH v3 2/9 imx91: Switch to OF_UPSTREAM
In reply to [email protected]From: Alice Guo <[email protected]>
Migrate i.MX91 boards to use OF_UPSTREAM feature, which allows U-Boot to directly use device trees from the Linux kernel upstream.
--- arch/arm/dts/imx91-11x11-evk.dts | 875 --------------------------- arch/arm/dts/imx91-11x11-frdm.dts | 773 ----------------------- arch/arm/dts/imx91-pinfunc.h | 770 ----------------------- arch/arm/dts/imx91.dtsi | 53 -- arch/arm/mach-imx/imx9/Kconfig | 2 + configs/imx91_11x11_evk_defconfig | 2 +- configs/imx91_11x11_evk_inline_ecc_defconfig | 2 +- configs/imx91_11x11_frdm_defconfig | 2 +- 8 files changed, 5 insertions(+), 2474 deletions(-)
arch/arm/dts/imx91-11x11-evk.dts deleted +0 -875
@@ -1,875 +0,0 @@ -// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -/* - * Copyright 2024 NXP - */ - -/dts-v1/; - -#include <dt-bindings/usb/pd.h> -#include "imx91.dtsi" - -/ { - compatible = "fsl,imx91-11x11-evk", "fsl,imx91"; - model = "NXP i.MX91 11X11 EVK board"; - - aliases { - ethernet0 = &fec; - ethernet1 = &eqos; - rtc0 = &bbnsm_rtc; - }; - - chosen { - stdout-path = &lpuart1; - }; - - reg_vref_1v8: regulator-adc-vref { - compatible = "regulator-fixed"; - regulator-max-microvolt = <1800000>; - regulator-min-microvolt = <1800000>; - regulator-name = "vref_1v8"; - }; - - reg_audio_pwr: regulator-audio-pwr { - compatible = "regulator-fixed"; - regulator-always-on; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <3300000>; - regulator-name = "audio-pwr"; - gpio = <&adp5585 1 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; - - reg_usdhc2_vmmc: regulator-usdhc2 { - compatible = "regulator-fixed"; - off-on-delay-us = <12000>; - pinctrl-0 = <&pinctrl_reg_usdhc2_vmmc>; - pinctrl-names = "default"; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <3300000>; - regulator-name = "VSD_3V3"; - gpio = <&gpio3 7 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; - - reg_usdhc3_vmmc: regulator-usdhc3 { - compatible = "regulator-fixed"; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <3300000>; - regulator-name = "WLAN_EN"; - gpio = <&pcal6524 20 GPIO_ACTIVE_HIGH>; - enable-active-high; - /* - * IW612 wifi chip needs more delay than other wifi chips to complete - * the host interface initialization after power up, otherwise the - * internal state of IW612 may be unstable, resulting in the failure of - * the SDIO3.0 switch voltage. - */ - startup-delay-us = <20000>; - }; - - reg_vdd_12v: regulator-vdd-12v { - compatible = "regulator-fixed"; - regulator-max-microvolt = <12000000>; - regulator-min-microvolt = <12000000>; - regulator-name = "reg_vdd_12v"; - gpio = <&pcal6524 14 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; - - reg_vrpi_3v3: regulator-vrpi-3v3 { - compatible = "regulator-fixed"; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <3300000>; - regulator-name = "VRPI_3V3"; - vin-supply = <&buck4>; - gpio = <&pcal6524 2 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; - - reg_vrpi_5v: regulator-vrpi-5v { - compatible = "regulator-fixed"; - regulator-max-microvolt = <5000000>; - regulator-min-microvolt = <5000000>; - regulator-name = "VRPI_5V"; - gpio = <&pcal6524 8 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; - - reserved-memory { - ranges; - #address-cells = <2>; - #size-cells = <2>; - - linux,cma { - compatible = "shared-dma-pool"; - alloc-ranges = <0 0x80000000 0 0x40000000>; - reusable; - size = <0 0x10000000>; - linux,cma-default; - }; - }; -}; - -&adc1 { - vref-supply = <®_vref_1v8>; - status = "okay"; -}; - -&eqos { - phy-handle = <ðphy1>; - phy-mode = "rgmii-id"; - pinctrl-0 = <&pinctrl_eqos>; - pinctrl-1 = <&pinctrl_eqos_sleep>; - pinctrl-names = "default", "sleep"; - status = "okay"; - - mdio { - compatible = "snps,dwmac-mdio"; - #address-cells = <1>; - #size-cells = <0>; - clock-frequency = <5000000>; - - ethphy1: ethernet-phy@1 { - reg = <1>; - eee-broken-1000t; - }; - }; -}; - -&fec { - phy-handle = <ðphy2>; - phy-mode = "rgmii-id"; - pinctrl-0 = <&pinctrl_fec>; - pinctrl-1 = <&pinctrl_fec_sleep>; - pinctrl-names = "default", "sleep"; - fsl,magic-packet; - status = "okay"; - - mdio { - #address-cells = <1>; - #size-cells = <0>; - clock-frequency = <5000000>; - - ethphy2: ethernet-phy@2 { - reg = <2>; - eee-broken-1000t; - }; - }; -}; - -/* - * When add, delete or change any target device setting in &lpi2c1, - * please synchronize the changes to the &i3c1 bus in imx91-11x11-evk-i3c.dts. - */ -&lpi2c1 { - clock-frequency = <400000>; - pinctrl-0 = <&pinctrl_lpi2c1>; - pinctrl-names = "default"; - status = "okay"; - - codec: wm8962@1a { - compatible = "wlf,wm8962"; - reg = <0x1a>; - clocks = <&clk IMX93_CLK_SAI3_GATE>; - AVDD-supply = <®_audio_pwr>; - CPVDD-supply = <®_audio_pwr>; - DBVDD-supply = <®_audio_pwr>; - DCVDD-supply = <®_audio_pwr>; - MICVDD-supply = <®_audio_pwr>; - PLLVDD-supply = <®_audio_pwr>; - SPKVDD1-supply = <®_audio_pwr>; - SPKVDD2-supply = <®_audio_pwr>; - gpio-cfg = < - 0x0000 /* 0:Default */ - 0x0000 /* 1:Default */ - 0x0000 /* 2:FN_DMICCLK */ - 0x0000 /* 3:Default */ - 0x0000 /* 4:FN_DMICCDAT */ - 0x0000 /* 5:Default */ - >; - }; - - lsm6dsm@6a { - compatible = "st,lsm6dso"; - reg = <0x6a>; - }; -}; - -&lpi2c2 { - #address-cells = <1>; - #size-cells = <0>; - clock-frequency = <400000>; - pinctrl-0 = <&pinctrl_lpi2c2>; - pinctrl-names = "default"; - status = "okay"; - - pcal6524: gpio@22 { - compatible = "nxp,pcal6524"; - reg = <0x22>; - #interrupt-cells = <2>; - interrupt-controller; - interrupts = <27 IRQ_TYPE_LEVEL_LOW>; - #gpio-cells = <2>; - gpio-controller; - interrupt-parent = <&gpio3>; - pinctrl-0 = <&pinctrl_pcal6524>; - pinctrl-names = "default"; - }; - - pmic@25 { - compatible = "nxp,pca9451a"; - reg = <0x25>; - interrupts = <11 IRQ_TYPE_EDGE_FALLING>; - interrupt-parent = <&pcal6524>; - - regulators { - - buck1: BUCK1 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <2237500>; - regulator-min-microvolt = <650000>; - regulator-name = "BUCK1"; - regulator-ramp-delay = <3125>; - }; - - buck2: BUCK2 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <2187500>; - regulator-min-microvolt = <600000>; - regulator-name = "BUCK2"; - regulator-ramp-delay = <3125>; - }; - - buck4: BUCK4 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3400000>; - regulator-min-microvolt = <600000>; - regulator-name = "BUCK4"; - }; - - buck5: BUCK5 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3400000>; - regulator-min-microvolt = <600000>; - regulator-name = "BUCK5"; - }; - - buck6: BUCK6 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3400000>; - regulator-min-microvolt = <600000>; - regulator-name = "BUCK6"; - }; - - ldo1: LDO1 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <1600000>; - regulator-name = "LDO1"; - }; - - ldo4: LDO4 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <800000>; - regulator-name = "LDO4"; - }; - - ldo5: LDO5 { - regulator-always-on; - regulator-boot-on; - regulator-max-microvolt = <3300000>; - regulator-min-microvolt = <1800000>; - regulator-name = "LDO5"; - }; - }; - }; - - adp5585: io-expander@34 { - compatible = "adi,adp5585-00", "adi,adp5585"; - reg = <0x34>; - #gpio-cells = <2>; - gpio-controller; - #pwm-cells = <3>; - gpio-reserved-ranges = <5 1>; - - exp-sel-hog { - gpio-hog; - gpios = <4 GPIO_ACTIVE_HIGH>; - output-low; - }; - }; -}; - -&lpi2c3 { - #address-cells = <1>; - #size-cells = <0>; - clock-frequency = <400000>; - pinctrl-0 = <&pinctrl_lpi2c3>; - pinctrl-names = "default"; - status = "okay"; - - ptn5110: tcpc@50 { - compatible = "nxp,ptn5110", "tcpci"; - reg = <0x50>; - interrupts = <27 IRQ_TYPE_LEVEL_LOW>; - interrupt-parent = <&gpio3>; - status = "okay"; - - typec1_con: connector { - compatible = "usb-c-connector"; - data-role = "dual"; - label = "USB-C"; - op-sink-microwatt = <15000000>; - power-role = "dual"; - self-powered; - sink-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM) - PDO_VAR(5000, 20000, 3000)>; - source-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>; - try-power-role = "sink"; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - - typec1_dr_sw: endpoint { - remote-endpoint = <&usb1_drd_sw>; - }; - }; - }; - }; - }; - - ptn5110_2: tcpc@51 { - compatible = "nxp,ptn5110", "tcpci"; - reg = <0x51>; - interrupts = <27 IRQ_TYPE_LEVEL_LOW>; - interrupt-parent = <&gpio3>; - status = "okay"; - - typec2_con: connector { - compatible = "usb-c-connector"; - data-role = "dual"; - label = "USB-C"; - op-sink-microwatt = <15000000>; - power-role = "dual"; - self-powered; - sink-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM) - PDO_VAR(5000, 20000, 3000)>; - source-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>; - try-power-role = "sink"; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - - typec2_dr_sw: endpoint { - remote-endpoint = <&usb2_drd_sw>; - }; - }; - }; - }; - }; - - pcf2131: rtc@53 { - compatible = "nxp,pcf2131"; - reg = <0x53>; - interrupts = <1 IRQ_TYPE_EDGE_FALLING>; - interrupt-parent = <&pcal6524>; - status = "okay"; - }; -}; - -&lpuart1 { - pinctrl-0 = <&pinctrl_uart1>; - pinctrl-names = "default"; - status = "okay"; -}; - -&lpuart5 { - pinctrl-0 = <&pinctrl_uart5>; - pinctrl-names = "default"; - status = "okay"; -}; - -&usbotg1 { - adp-disable; - disable-over-current; - dr_mode = "otg"; - hnp-disable; - srp-disable; - usb-role-switch; - samsung,picophy-dc-vol-level-adjust = <7>; - samsung,picophy-pre-emp-curr-control = <3>; - status = "okay"; - - port { - usb1_drd_sw: endpoint { - remote-endpoint = <&typec1_dr_sw>; - }; - }; -}; - -&usbotg2 { - adp-disable; - disable-over-current; - dr_mode = "otg"; - hnp-disable; - srp-disable; - usb-role-switch; - samsung,picophy-dc-vol-level-adjust = <7>; - samsung,picophy-pre-emp-curr-control = <3>; - status = "okay"; - - port { - usb2_drd_sw: endpoint { - remote-endpoint = <&typec2_dr_sw>; - }; - }; -}; - -&usdhc1 { - bus-width = <8>; - non-removable; - pinctrl-0 = <&pinctrl_usdhc1>; - pinctrl-1 = <&pinctrl_usdhc1_100mhz>; - pinctrl-2 = <&pinctrl_usdhc1_200mhz>; - pinctrl-names = "default", "state_100mhz", "state_200mhz"; - status = "okay"; -}; - -&usdhc2 { - bus-width = <4>; - cd-gpios = <&gpio3 00 GPIO_ACTIVE_LOW>; - no-mmc; - no-sdio; - pinctrl-0 = <&pinctrl_usdhc2>, <&pinctrl_usdhc2_gpio>; - pinctrl-1 = <&pinctrl_usdhc2_100mhz>, <&pinctrl_usdhc2_gpio>; - pinctrl-2 = <&pinctrl_usdhc2_200mhz>, <&pinctrl_usdhc2_gpio>; - pinctrl-3 = <&pinctrl_usdhc2_sleep>, <&pinctrl_usdhc2_gpio_sleep>; - pinctrl-names = "default", "state_100mhz", "state_200mhz", "sleep"; - vmmc-supply = <®_usdhc2_vmmc>; - status = "okay"; -}; - -&wdog3 { - fsl,ext-reset-output; - status = "okay"; -}; - -&iomuxc { - pinctrl_eqos: eqosgrp { - fsl,pins = < - MX91_PAD_ENET1_MDC__ENET1_MDC 0x57e - MX91_PAD_ENET1_MDIO__ENET_QOS_MDIO 0x57e - MX91_PAD_ENET1_RD0__ENET_QOS_RGMII_RD0 0x57e - MX91_PAD_ENET1_RD1__ENET_QOS_RGMII_RD1 0x57e - MX91_PAD_ENET1_RD2__ENET_QOS_RGMII_RD2 0x57e - MX91_PAD_ENET1_RD3__ENET_QOS_RGMII_RD3 0x57e - MX91_PAD_ENET1_RXC__ENET_QOS_RGMII_RXC 0x5fe - MX91_PAD_ENET1_RX_CTL__ENET_QOS_RGMII_RX_CTL 0x57e - MX91_PAD_ENET1_TD0__ENET_QOS_RGMII_TD0 0x57e - MX91_PAD_ENET1_TD1__ENET1_RGMII_TD1 0x57e - MX91_PAD_ENET1_TD2__ENET_QOS_RGMII_TD2 0x57e - MX91_PAD_ENET1_TD3__ENET_QOS_RGMII_TD3 0x57e - MX91_PAD_ENET1_TXC__CCM_ENET_QOS_CLOCK_GENERATE_TX_CLK 0x5fe - MX91_PAD_ENET1_TX_CTL__ENET_QOS_RGMII_TX_CTL 0x57e - >; - }; - - pinctrl_eqos_sleep: eqossleepgrp { - fsl,pins = < - MX91_PAD_ENET1_MDC__GPIO4_IO0 0x31e - MX91_PAD_ENET1_MDIO__GPIO4_IO1 0x31e - MX91_PAD_ENET1_RD0__GPIO4_IO10 0x31e - MX91_PAD_ENET1_RD1__GPIO4_IO11 0x31e - MX91_PAD_ENET1_RD2__GPIO4_IO12 0x31e - MX91_PAD_ENET1_RD3__GPIO4_IO13 0x31e - MX91_PAD_ENET1_RXC__GPIO4_IO9 0x31e - MX91_PAD_ENET1_RX_CTL__GPIO4_IO8 0x31e - MX91_PAD_ENET1_TD0__GPIO4_IO5 0x31e - MX91_PAD_ENET1_TD1__GPIO4_IO4 0x31e - MX91_PAD_ENET1_TD2__GPIO4_IO3 0x31e - MX91_PAD_ENET1_TD3__GPIO4_IO2 0x31e - MX91_PAD_ENET1_TXC__GPIO4_IO7 0x31e - MX91_PAD_ENET1_TX_CTL__GPIO4_IO6 0x31e - >; - }; - - pinctrl_fec: fecgrp { - fsl,pins = < - MX91_PAD_ENET2_MDC__ENET2_MDC 0x57e - MX91_PAD_ENET2_MDIO__ENET2_MDIO 0x57e - MX91_PAD_ENET2_RD0__ENET2_RGMII_RD0 0x57e - MX91_PAD_ENET2_RD1__ENET2_RGMII_RD1 0x57e - MX91_PAD_ENET2_RD2__ENET2_RGMII_RD2 0x57e - MX91_PAD_ENET2_RD3__ENET2_RGMII_RD3 0x57e - MX91_PAD_ENET2_RXC__ENET2_RGMII_RXC 0x5fe - MX91_PAD_ENET2_RX_CTL__ENET2_RGMII_RX_CTL 0x57e - MX91_PAD_ENET2_TD0__ENET2_RGMII_TD0 0x57e - MX91_PAD_ENET2_TD1__ENET2_RGMII_TD1 0x57e - MX91_PAD_ENET2_TD2__ENET2_RGMII_TD2 0x57e - MX91_PAD_ENET2_TD3__ENET2_RGMII_TD3 0x57e - MX91_PAD_ENET2_TXC__ENET2_RGMII_TXC 0x5fe - MX91_PAD_ENET2_TX_CTL__ENET2_RGMII_TX_CTL 0x57e - >; - }; - - pinctrl_fec_sleep: fecsleepgrp { - fsl,pins = < - MX91_PAD_ENET2_MDC__GPIO4_IO14 0x51e - MX91_PAD_ENET2_MDIO__GPIO4_IO15 0x51e - MX91_PAD_ENET2_RD0__GPIO4_IO24 0x51e - MX91_PAD_ENET2_RD1__GPIO4_IO25 0x51e - MX91_PAD_ENET2_RD2__GPIO4_IO26 0x51e - MX91_PAD_ENET2_RD3__GPIO4_IO27 0x51e - MX91_PAD_ENET2_RXC__GPIO4_IO23 0x51e - MX91_PAD_ENET2_RX_CTL__GPIO4_IO22 0x51e - MX91_PAD_ENET2_TD0__GPIO4_IO19 0x51e - MX91_PAD_ENET2_TD1__GPIO4_IO18 0x51e - MX91_PAD_ENET2_TD2__GPIO4_IO17 0x51e - MX91_PAD_ENET2_TD3__GPIO4_IO16 0x51e - MX91_PAD_ENET2_TXC__GPIO4_IO21 0x51e - MX91_PAD_ENET2_TX_CTL__GPIO4_IO20 0x51e - >; - }; - - pinctrl_flexcan2: flexcan2grp { - fsl,pins = < - MX91_PAD_GPIO_IO25__CAN2_TX 0x139e - MX91_PAD_GPIO_IO27__CAN2_RX 0x139e - >; - }; - - pinctrl_flexcan2_sleep: flexcan2sleepgrp { - fsl,pins = < - MX91_PAD_GPIO_IO25__GPIO2_IO25 0x31e - MX91_PAD_GPIO_IO27__GPIO2_IO27 0x31e - >; - }; - - pinctrl_lcdif_gpio: lcdifgpiogrp { - fsl,pins = < - MX91_PAD_GPIO_IO00__GPIO2_IO0 0x51e - MX91_PAD_GPIO_IO01__GPIO2_IO1 0x51e - MX91_PAD_GPIO_IO02__GPIO2_IO2 0x51e - MX91_PAD_GPIO_IO03__GPIO2_IO3 0x51e - >; - }; - - pinctrl_lcdif: lcdifgrp { - fsl,pins = < - MX91_PAD_GPIO_IO00__MEDIAMIX_DISP_CLK 0x31e - MX91_PAD_GPIO_IO01__MEDIAMIX_DISP_DE 0x31e - MX91_PAD_GPIO_IO02__MEDIAMIX_DISP_VSYNC 0x31e - MX91_PAD_GPIO_IO03__MEDIAMIX_DISP_HSYNC 0x31e - MX91_PAD_GPIO_IO04__MEDIAMIX_DISP_DATA0 0x31e - MX91_PAD_GPIO_IO05__MEDIAMIX_DISP_DATA1 0x31e - MX91_PAD_GPIO_IO06__MEDIAMIX_DISP_DATA2 0x31e - MX91_PAD_GPIO_IO07__MEDIAMIX_DISP_DATA3 0x31e - MX91_PAD_GPIO_IO08__MEDIAMIX_DISP_DATA4 0x31e - MX91_PAD_GPIO_IO09__MEDIAMIX_DISP_DATA5 0x31e - MX91_PAD_GPIO_IO10__MEDIAMIX_DISP_DATA6 0x31e - MX91_PAD_GPIO_IO11__MEDIAMIX_DISP_DATA7 0x31e - MX91_PAD_GPIO_IO12__MEDIAMIX_DISP_DATA8 0x31e - MX91_PAD_GPIO_IO13__MEDIAMIX_DISP_DATA9 0x31e - MX91_PAD_GPIO_IO14__MEDIAMIX_DISP_DATA10 0x31e - MX91_PAD_GPIO_IO15__MEDIAMIX_DISP_DATA11 0x31e - MX91_PAD_GPIO_IO16__MEDIAMIX_DISP_DATA12 0x31e - MX91_PAD_GPIO_IO17__MEDIAMIX_DISP_DATA13 0x31e - MX91_PAD_GPIO_IO18__MEDIAMIX_DISP_DATA14 0x31e - MX91_PAD_GPIO_IO19__MEDIAMIX_DISP_DATA15 0x31e - MX91_PAD_GPIO_IO20__MEDIAMIX_DISP_DATA16 0x31e - MX91_PAD_GPIO_IO21__MEDIAMIX_DISP_DATA17 0x31e - MX91_PAD_GPIO_IO27__GPIO2_IO27 0x31e - >; - }; - - pinctrl_lpi2c1: lpi2c1grp { - fsl,pins = < - MX91_PAD_I2C1_SCL__LPI2C1_SCL 0x40000b9e - MX91_PAD_I2C1_SDA__LPI2C1_SDA 0x40000b9e - >; - }; - - pinctrl_lpi2c2: lpi2c2grp { - fsl,pins = < - MX91_PAD_I2C2_SCL__LPI2C2_SCL 0x40000b9e - MX91_PAD_I2C2_SDA__LPI2C2_SDA 0x40000b9e - >; - }; - - pinctrl_lpi2c3: lpi2c3grp { - fsl,pins = < - MX91_PAD_GPIO_IO28__LPI2C3_SDA 0x40000b9e - MX91_PAD_GPIO_IO29__LPI2C3_SCL 0x40000b9e - >; - }; - - pinctrl_pcal6524: pcal6524grp { - fsl,pins = < - MX91_PAD_CCM_CLKO2__GPIO3_IO27 0x31e - >; - }; - - pinctrl_pdm: pdmgrp { - fsl,pins = < - MX91_PAD_PDM_CLK__PDM_CLK 0x31e - MX91_PAD_PDM_BIT_STREAM0__PDM_BIT_STREAM0 0x31e - MX91_PAD_PDM_BIT_STREAM1__PDM_BIT_STREAM1 0x31e - >; - }; - - pinctrl_pdm_sleep: pdmsleepgrp { - fsl,pins = < - MX91_PAD_PDM_CLK__GPIO1_IO8 0x31e - MX91_PAD_PDM_BIT_STREAM0__GPIO1_IO9 0x31e - MX91_PAD_PDM_BIT_STREAM1__GPIO1_IO10 0x31e - >; - }; - - pinctrl_reg_usdhc2_vmmc: regusdhc2vmmcgrp { - fsl,pins = < - MX91_PAD_SD2_RESET_B__GPIO3_IO7 0x31e - >; - }; - - pinctrl_sai1: sai1grp { - fsl,pins = < - MX91_PAD_SAI1_TXC__SAI1_TX_BCLK 0x31e - MX91_PAD_SAI1_TXFS__SAI1_TX_SYNC 0x31e - MX91_PAD_SAI1_TXD0__SAI1_TX_DATA0 0x31e - MX91_PAD_SAI1_RXD0__SAI1_RX_DATA0 0x31e - >; - }; - - pinctrl_sai1_sleep: sai1sleepgrp { - fsl,pins = < - MX91_PAD_SAI1_TXC__GPIO1_IO12 0x51e - MX91_PAD_SAI1_TXFS__GPIO1_IO11 0x51e - MX91_PAD_SAI1_TXD0__GPIO1_IO13 0x51e - MX91_PAD_SAI1_RXD0__GPIO1_IO14 0x51e - >; - }; - - pinctrl_sai3: sai3grp { - fsl,pins = < - MX91_PAD_GPIO_IO26__SAI3_TX_SYNC 0x31e - MX91_PAD_GPIO_IO16__SAI3_TX_BCLK 0x31e - MX91_PAD_GPIO_IO17__SAI3_MCLK 0x31e - MX91_PAD_GPIO_IO19__SAI3_TX_DATA0 0x31e - MX91_PAD_GPIO_IO20__SAI3_RX_DATA0 0x31e - >; - }; - - pinctrl_sai3_sleep: sai3sleepgrp { - fsl,pins = < - MX91_PAD_GPIO_IO26__GPIO2_IO26 0x51e - MX91_PAD_GPIO_IO16__GPIO2_IO16 0x51e - MX91_PAD_GPIO_IO17__GPIO2_IO17 0x51e - MX91_PAD_GPIO_IO19__GPIO2_IO19 0x51e - MX91_PAD_GPIO_IO20__GPIO2_IO20 0x51e - >; - }; - - pinctrl_spdif: spdifgrp { - fsl,pins = < - MX91_PAD_GPIO_IO22__SPDIF_IN 0x31e - MX91_PAD_GPIO_IO23__SPDIF_OUT 0x31e - >; - }; - - pinctrl_spdif_sleep: spdifsleepgrp { - fsl,pins = < - MX91_PAD_GPIO_IO22__GPIO2_IO22 0x31e - MX91_PAD_GPIO_IO23__GPIO2_IO23 0x31e - >; - }; - - pinctrl_uart1: uart1grp { - fsl,pins = < - MX91_PAD_UART1_RXD__LPUART1_RX 0x31e - MX91_PAD_UART1_TXD__LPUART1_TX 0x31e - >; - }; - - pinctrl_uart5: uart5grp { - fsl,pins = < - MX91_PAD_DAP_TDO_TRACESWO__LPUART5_TX 0x31e - MX91_PAD_DAP_TDI__LPUART5_RX 0x31e - MX91_PAD_DAP_TMS_SWDIO__LPUART5_RTS_B 0x31e - MX91_PAD_DAP_TCLK_SWCLK__LPUART5_CTS_B 0x31e - >; - }; - - pinctrl_usdhc1_100mhz: usdhc1-100mhzgrp { - fsl,pins = < - MX91_PAD_SD1_CLK__USDHC1_CLK 0x158e - MX91_PAD_SD1_CMD__USDHC1_CMD 0x138e - MX91_PAD_SD1_DATA0__USDHC1_DATA0 0x138e - MX91_PAD_SD1_DATA1__USDHC1_DATA1 0x138e - MX91_PAD_SD1_DATA2__USDHC1_DATA2 0x138e - MX91_PAD_SD1_DATA3__USDHC1_DATA3 0x138e - MX91_PAD_SD1_DATA4__USDHC1_DATA4 0x138e - MX91_PAD_SD1_DATA5__USDHC1_DATA5 0x138e - MX91_PAD_SD1_DATA6__USDHC1_DATA6 0x138e - MX91_PAD_SD1_DATA7__USDHC1_DATA7 0x138e - MX91_PAD_SD1_STROBE__USDHC1_STROBE 0x158e - >; - }; - - pinctrl_usdhc1_200mhz: usdhc1-200mhzgrp { - fsl,pins = < - MX91_PAD_SD1_CLK__USDHC1_CLK 0x15fe - MX91_PAD_SD1_CMD__USDHC1_CMD 0x13fe - MX91_PAD_SD1_DATA0__USDHC1_DATA0 0x13fe - MX91_PAD_SD1_DATA1__USDHC1_DATA1 0x13fe - MX91_PAD_SD1_DATA2__USDHC1_DATA2 0x13fe - MX91_PAD_SD1_DATA3__USDHC1_DATA3 0x13fe - MX91_PAD_SD1_DATA4__USDHC1_DATA4 0x13fe - MX91_PAD_SD1_DATA5__USDHC1_DATA5 0x13fe - MX91_PAD_SD1_DATA6__USDHC1_DATA6 0x13fe - MX91_PAD_SD1_DATA7__USDHC1_DATA7 0x13fe - MX91_PAD_SD1_STROBE__USDHC1_STROBE 0x15fe - >; - }; - - pinctrl_usdhc1: usdhc1grp { - fsl,pins = < - MX91_PAD_SD1_CLK__USDHC1_CLK 0x1582 - MX91_PAD_SD1_CMD__USDHC1_CMD 0x1382 - MX91_PAD_SD1_DATA0__USDHC1_DATA0 0x1382 - MX91_PAD_SD1_DATA1__USDHC1_DATA1 0x1382 - MX91_PAD_SD1_DATA2__USDHC1_DATA2 0x1382 - MX91_PAD_SD1_DATA3__USDHC1_DATA3 0x1382 - MX91_PAD_SD1_DATA4__USDHC1_DATA4 0x1382 - MX91_PAD_SD1_DATA5__USDHC1_DATA5 0x1382 - MX91_PAD_SD1_DATA6__USDHC1_DATA6 0x1382 - MX91_PAD_SD1_DATA7__USDHC1_DATA7 0x1382 - MX91_PAD_SD1_STROBE__USDHC1_STROBE 0x1582 - >; - }; - - pinctrl_usdhc2_100mhz: usdhc2-100mhzgrp { - fsl,pins = < - MX91_PAD_SD2_CLK__USDHC2_CLK 0x158e - MX91_PAD_SD2_CMD__USDHC2_CMD 0x138e - MX91_PAD_SD2_DATA0__USDHC2_DATA0 0x138e - MX91_PAD_SD2_DATA1__USDHC2_DATA1 0x138e - MX91_PAD_SD2_DATA2__USDHC2_DATA2 0x138e - MX91_PAD_SD2_DATA3__USDHC2_DATA3 0x138e - MX91_PAD_SD2_VSELECT__USDHC2_VSELECT 0x51e - >; - }; - - pinctrl_usdhc2_200mhz: usdhc2-200mhzgrp { - fsl,pins = < - MX91_PAD_SD2_CLK__USDHC2_CLK 0x15fe - MX91_PAD_SD2_CMD__USDHC2_CMD 0x13fe - MX91_PAD_SD2_DATA0__USDHC2_DATA0 0x13fe - MX91_PAD_SD2_DATA1__USDHC2_DATA1 0x13fe - MX91_PAD_SD2_DATA2__USDHC2_DATA2 0x13fe - MX91_PAD_SD2_DATA3__USDHC2_DATA3 0x13fe - MX91_PAD_SD2_VSELECT__USDHC2_VSELECT 0x51e - >; - }; - - pinctrl_usdhc2_gpio: usdhc2gpiogrp { - fsl,pins = < - MX91_PAD_SD2_CD_B__GPIO3_IO0 0x31e - >; - }; - - pinctrl_usdhc2_gpio_sleep: usdhc2gpiosleepgrp { - fsl,pins = < - MX91_PAD_SD2_CD_B__GPIO3_IO0 0x51e - >; - }; - - pinctrl_usdhc2: usdhc2grp { - fsl,pins = < - MX91_PAD_SD2_CLK__USDHC2_CLK 0x1582 - MX91_PAD_SD2_CMD__USDHC2_CMD 0x1382 - MX91_PAD_SD2_DATA0__USDHC2_DATA0 0x1382 - MX91_PAD_SD2_DATA1__USDHC2_DATA1 0x1382 - MX91_PAD_SD2_DATA2__USDHC2_DATA2 0x1382 - MX91_PAD_SD2_DATA3__USDHC2_DATA3 0x1382 - MX91_PAD_SD2_VSELECT__USDHC2_VSELECT 0x51e - >; - }; - - pinctrl_usdhc2_sleep: usdhc2sleepgrp { - fsl,pins = < - MX91_PAD_SD2_CLK__GPIO3_IO1 0x51e - MX91_PAD_SD2_CMD__GPIO3_IO2 0x51e - MX91_PAD_SD2_DATA0__GPIO3_IO3 0x51e - MX91_PAD_SD2_DATA1__GPIO3_IO4 0x51e - MX91_PAD_SD2_DATA2__GPIO3_IO5 0x51e - MX91_PAD_SD2_DATA3__GPIO3_IO6 0x51e - MX91_PAD_SD2_VSELECT__GPIO3_IO19 0x51e - >; - }; - - pinctrl_usdhc3_100mhz: usdhc3-100mhzgrp { - fsl,pins = < - MX91_PAD_SD3_CLK__USDHC3_CLK 0x158e - MX91_PAD_SD3_CMD__USDHC3_CMD 0x138e - MX91_PAD_SD3_DATA0__USDHC3_DATA0 0x138e - MX91_PAD_SD3_DATA1__USDHC3_DATA1 0x138e - MX91_PAD_SD3_DATA2__USDHC3_DATA2 0x138e - MX91_PAD_SD3_DATA3__USDHC3_DATA3 0x138e - >; - }; - - pinctrl_usdhc3_200mhz: usdhc3-200mhzgrp { - fsl,pins = < - MX91_PAD_SD3_CLK__USDHC3_CLK 0x15fe - MX91_PAD_SD3_CMD__USDHC3_CMD 0x13fe - MX91_PAD_SD3_DATA0__USDHC3_DATA0 0x13fe - MX91_PAD_SD3_DATA1__USDHC3_DATA1 0x13fe - MX91_PAD_SD3_DATA2__USDHC3_DATA2 0x13fe - MX91_PAD_SD3_DATA3__USDHC3_DATA3 0x13fe - >; - }; - - pinctrl_usdhc3: usdhc3grp { - fsl,pins = < - MX91_PAD_SD3_CLK__USDHC3_CLK 0x1582 - MX91_PAD_SD3_CMD__USDHC3_CMD 0x1382 - MX91_PAD_SD3_DATA0__USDHC3_DATA0 0x1382 - MX91_PAD_SD3_DATA1__USDHC3_DATA1 0x1382 - MX91_PAD_SD3_DATA2__USDHC3_DATA2 0x1382 - MX91_PAD_SD3_DATA3__USDHC3_DATA3 0x1382 - >; - }; - - pinctrl_usdhc3_sleep: usdhc3sleepgrp { - fsl,pins = < - MX91_PAD_SD3_CLK__GPIO3_IO20 0x31e - MX91_PAD_SD3_CMD__GPIO3_IO21 0x31e - MX91_PAD_SD3_DATA0__GPIO3_IO22 0x31e - MX91_PAD_SD3_DATA1__GPIO3_IO23 0x31e - MX91_PAD_SD3_DATA2__GPIO3_IO24 0x31e - MX91_PAD_SD3_DATA3__GPIO3_IO25 0x31e - >; - }; - - pinctrl_usdhc3_wlan: usdhc3wlangrp { - fsl,pins = < - MX91_PAD_CCM_CLKO1__GPIO3_IO26 0x31e - >; - }; -};
arch/arm/dts/imx91-11x11-frdm.dts deleted +0 -773
773 lines not on this page · raw message
arch/arm/dts/imx91-pinfunc.h deleted +0 -770
770 lines not on this page · raw message
arch/arm/dts/imx91.dtsi deleted +0 -53
53 lines not on this page · raw message
arch/arm/mach-imx/imx9/Kconfig +2 -0
@@ -68,6 +68,7 @@ config TARGET_IMX91_11X11_EVK select IMX91 imply BOOTSTD_FULL imply BOOTSTD_BOOTCOMMAND + imply OF_UPSTREAM config TARGET_IMX91_11X11_FRDM bool "imx91_11x11_frdm"
@@ -76,6 +77,7 @@ config TARGET_IMX91_11X11_FRDM select IMX9_LPDDR4X imply BOOTSTD_FULL imply BOOTSTD_BOOTCOMMAND + imply OF_UPSTREAM config TARGET_IMX93_9X9_QSB bool "imx93_qsb"
configs/imx91_11x11_evk_defconfig +1 -1
@@ -11,7 +11,7 @@ CONFIG_ENV_SIZE=0x4000 CONFIG_ENV_OFFSET=0x700000 CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg" CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx91-11x11-evk" +CONFIG_DEFAULT_DEVICE_TREE="freescale/imx91-11x11-evk" CONFIG_TARGET_IMX91_11X11_EVK=y CONFIG_OF_LIBFDT_OVERLAY=y CONFIG_SYS_MONITOR_LEN=524288
configs/imx91_11x11_evk_inline_ecc_defconfig +1 -1
@@ -11,7 +11,7 @@ CONFIG_ENV_SIZE=0x4000 CONFIG_ENV_OFFSET=0x700000 CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg" CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx91-11x11-evk" +CONFIG_DEFAULT_DEVICE_TREE="freescale/imx91-11x11-evk" CONFIG_TARGET_IMX91_11X11_EVK=y CONFIG_OF_LIBFDT_OVERLAY=y CONFIG_SYS_MONITOR_LEN=524288
configs/imx91_11x11_frdm_defconfig +1 -1
@@ -10,7 +10,7 @@ CONFIG_ENV_SIZE=0x4000 CONFIG_ENV_OFFSET=0x700000 CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg" CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx91-11x11-frdm" +CONFIG_DEFAULT_DEVICE_TREE="freescale/imx91-11x11-frdm" CONFIG_TARGET_IMX91_11X11_FRDM=y CONFIG_OF_LIBFDT_OVERLAY=y CONFIG_SYS_MONITOR_LEN=524288
Signature · 1 line
2.34.1
Re: [PATCH v3 2/9] imx91: Switch to OF_UPSTREAM
Quoted 7 lines · On Tue, May 12, 2026 at 11:10:09AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Migrate i.MX91 boards to use
OF_UPSTREAMfeature, which allows U-Boot to directly use device trees from the Linux kernel upstream.Signed-off-by Alice Guo <[email protected]>---
Quoted 10 lines
arch/arm/dts/imx91-11x11-evk.dts | 875 --------------------------- arch/arm/dts/imx91-11x11-frdm.dts | 773 ----------------------- arch/arm/dts/imx91-pinfunc.h | 770 ----------------------- arch/arm/dts/imx91.dtsi | 53 -- arch/arm/mach-imx/imx9/Kconfig | 2 + configs/imx91_11x11_evk_defconfig | 2 +- configs/imx91_11x11_evk_inline_ecc_defconfig | 2 +- configs/imx91_11x11_frdm_defconfig | 2 +- 8 files changed, 5 insertions(+), 2474 deletions(-)
PATCH v3 3/9 imx93-frdm: Switch to OF_UPSTREAM
In reply to [email protected]From: Alice Guo <[email protected]>
Switch the i.MX93 FRDM board to use the upstream device tree instead of maintaining a local copy.
--- arch/arm/dts/Makefile | 1 - arch/arm/dts/imx93-11x11-frdm.dts | 603 -------------------------------------- arch/arm/mach-imx/imx9/Kconfig | 1 + configs/imx93_frdm_defconfig | 2 +- 4 files changed, 2 insertions(+), 605 deletions(-)
arch/arm/dts/Makefile +0 -1
@@ -896,7 +896,6 @@ dtb-$(CONFIG_ARCH_IMX8M) += \ imx8mq-librem5-r4.dtb dtb-$(CONFIG_ARCH_IMX9) += \ - imx93-11x11-frdm.dtb \ imx93-var-som-symphony.dtb dtb-$(CONFIG_ARCH_IMXRT) += imxrt1020-evk.dtb \
arch/arm/dts/imx93-11x11-frdm.dts deleted +0 -603
603 lines not on this page · raw message
arch/arm/mach-imx/imx9/Kconfig +1 -0
@@ -115,6 +115,7 @@ config TARGET_IMX93_FRDM select REMOTEPROC_IMX select REGMAP select SYSCON + imply OF_UPSTREAM config TARGET_IMX93_VAR_SOM bool "imx93_var_som"
configs/imx93_frdm_defconfig +1 -1
@@ -10,7 +10,7 @@ CONFIG_ENV_SIZE=0x4000 CONFIG_ENV_OFFSET=0x700000 CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg" CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx93-11x11-frdm" +CONFIG_DEFAULT_DEVICE_TREE="freescale/imx93-11x11-frdm" CONFIG_TARGET_IMX93_FRDM=y CONFIG_SYS_MONITOR_LEN=524288 CONFIG_SPL_SERIAL=y
Signature · 1 line
2.34.1
Re: [PATCH v3 3/9] imx93-frdm: Switch to OF_UPSTREAM
Quoted 11 lines · On Tue, May 12, 2026 at 11:10:10AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Switch the i.MX93 FRDM board to use the upstream device tree instead of maintaining a local copy.
Signed-off-by Alice Guo <[email protected]>---
arch/arm/dts/Makefile | 1 - arch/arm/dts/imx93-11x11-frdm.dts | 603 -------------------------------------- arch/arm/mach-imx/imx9/Kconfig | 1 + configs/imx93_frdm_defconfig | 2 +-
PATCH v3 4/9 imx93_var_som: Switch to OF_UPSTREAM
In reply to [email protected]From: Alice Guo <[email protected]>
Enable OF_UPSTREAM and remove local device tree files in favor of upstream device trees from Linux kernel.
--- arch/arm/dts/Makefile | 3 - arch/arm/dts/imx93-var-som-symphony.dts | 323 ------------ arch/arm/dts/imx93-var-som.dtsi | 111 ---- arch/arm/dts/imx93.dtsi | 906 -------------------------------- arch/arm/mach-imx/imx9/Kconfig | 1 + configs/imx93_var_som_defconfig | 2 +- 6 files changed, 2 insertions(+), 1344 deletions(-)
arch/arm/dts/Makefile +0 -3
@@ -895,9 +895,6 @@ dtb-$(CONFIG_ARCH_IMX8M) += \ imx8mq-kontron-pitx-imx8m.dtb \ imx8mq-librem5-r4.dtb -dtb-$(CONFIG_ARCH_IMX9) += \ - imx93-var-som-symphony.dtb - dtb-$(CONFIG_ARCH_IMXRT) += imxrt1020-evk.dtb \ imxrt1170-evk.dtb \
arch/arm/dts/imx93-var-som-symphony.dts deleted +0 -323
323 lines not on this page · raw message
arch/arm/dts/imx93-var-som.dtsi deleted +0 -111
111 lines not on this page · raw message
arch/arm/dts/imx93.dtsi deleted +0 -906
906 lines not on this page · raw message
arch/arm/mach-imx/imx9/Kconfig +1 -0
@@ -121,6 +121,7 @@ config TARGET_IMX93_VAR_SOM bool "imx93_var_som" select IMX93 select IMX9_LPDDR4X + imply OF_UPSTREAM config TARGET_KONTRON_MX93 bool "Kontron OSM-S/BL i.MX93"
configs/imx93_var_som_defconfig +1 -1
@@ -10,7 +10,7 @@ CONFIG_ENV_SIZE=0x4000 CONFIG_ENV_OFFSET=0x700000 CONFIG_IMX_CONFIG="arch/arm/mach-imx/imx9/imximage.cfg" CONFIG_DM_GPIO=y -CONFIG_DEFAULT_DEVICE_TREE="imx93-var-som-symphony" +CONFIG_DEFAULT_DEVICE_TREE="freescale/imx93-var-som-symphony" CONFIG_AHAB_BOOT=y CONFIG_TARGET_IMX93_VAR_SOM=y CONFIG_OF_LIBFDT_OVERLAY=y
Signature · 1 line
2.34.1
PATCH v3 5/9 imx: soc: Get watchdog base addresses from device tree
In reply to [email protected]From: Alice Guo <[email protected]>
Replace hardcoded watchdog base addresses with dynamic address lookup from device tree for i.MX7ULP, i.MX8ULP, i.MX91, i.MX93, i.MX943, i.MX95 and i.MX952.
Move i.MX7ULP watchdog initialization from s_init() to arch_cpu_init() because ofnode_* APIs depend on FDT, which is not available during s_init().
--- arch/arm/mach-imx/imx8ulp/soc.c | 14 +++++++++++++- arch/arm/mach-imx/imx9/scmi/soc.c | 15 ++++++++++++--- arch/arm/mach-imx/imx9/soc.c | 16 +++++++++++++--- arch/arm/mach-imx/mx7ulp/soc.c | 24 ++++++++++++++++++------ 4 files changed, 56 insertions(+), 13 deletions(-)
arch/arm/mach-imx/imx8ulp/soc.c +13 -1
@@ -343,7 +343,19 @@ static void disable_wdog(void __iomem *wdog_base)void init_wdog (void ) { -disable_wdog ((void __iomem *)WDG3_RBASE ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx8ulp-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx8ulp-wdt" )) { +phys_addr_t base; + + base =ofnode_get_addr (node); +if (base ==FDT_ADDR_T_NONE ) +continue ; + +disable_wdog ((void __iomem *)base); + } }static struct mm_region imx8ulp_arm64_mem_map[] = {
arch/arm/mach-imx/imx9/scmi/soc.c +12 -3
@@ -786,9 +786,18 @@ static void gpio_reset(ulong gpio_base)int arch_cpu_init (void ) {if (IS_ENABLED (CONFIG_SPL_BUILD )) { -if (!IS_ENABLED (CONFIG_IMX952 )) { -disable_wdog ((void __iomem *)WDG3_BASE_ADDR ); -disable_wdog ((void __iomem *)WDG4_BASE_ADDR ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx93-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx93-wdt" )) { +phys_addr_t base; + + base =ofnode_get_addr (node); +if (base ==FDT_ADDR_T_NONE ) +continue ; + +disable_wdog ((void __iomem *)base); }gpio_reset (GPIO2_BASE_ADDR );
arch/arm/mach-imx/imx9/soc.c +13 -3
@@ -281,9 +281,19 @@ static void disable_wdog(void __iomem *wdog_base)void init_wdog (void ) { -disable_wdog ((void __iomem *)WDG3_BASE_ADDR ); -disable_wdog ((void __iomem *)WDG4_BASE_ADDR ); -disable_wdog ((void __iomem *)WDG5_BASE_ADDR ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx93-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx93-wdt" )) { +phys_addr_t base; + + base =ofnode_get_addr (node); +if (base ==FDT_ADDR_T_NONE ) +continue ; + +disable_wdog ((void __iomem *)base); + } }static struct mm_region imx93_mem_map[] = {
arch/arm/mach-imx/mx7ulp/soc.c +18 -6
@@ -83,8 +83,12 @@ enum bt_mode get_boot_mode(void)return LOW_POWER_BOOT ; } +static void init_wdog (void );int arch_cpu_init (void ) { +/* Disable wdog */ +init_wdog (); +enable_ca7_smp ();return 0 ; }
@@ -146,7 +150,7 @@ static void disable_wdog(u32 wdog_base)while (!(readl (wdog_base +0x00 ) &0x400 )); } -void init_wdog (void ) +static void init_wdog (void ) {/* * ROM will configure WDOG1, disable it or enable it
@@ -161,8 +165,19 @@ void init_wdog(void)* In this function, we will disable both WDOG1 and WDOG2, * and set update bit for both. So that kernel can reconfigure them. */ -disable_wdog (WDG1_RBASE ); -disable_wdog (WDG2_RBASE ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx7ulp-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx7ulp-wdt" )) { +phys_addr_t base; + + base =ofnode_get_addr (node); +if (base ==FDT_ADDR_T_NONE ) +continue ; + +disable_wdog ((u32 )base); + } }static bool ldo_mode_is_enabled (void )
@@ -221,9 +236,6 @@ static void init_ldo_mode(void)void s_init (void ) { -/* Disable wdog */ -init_wdog (); -/* clock configuration. */ clock_init ();
Signature · 1 line
2.34.1
Re: [PATCH v3 5/9] imx: soc: Get watchdog base addresses from device tree
Quoted 23 lines · On Tue, May 12, 2026 at 11:10:12AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Replace hardcoded watchdog base addresses with dynamic address lookup from device tree for i.MX7ULP, i.MX8ULP, i.MX91, i.MX93, i.MX943, i.MX95 and i.MX952.
Move i.MX7ULP watchdog initialization from
s_init()toarch_cpu_init()because ofnode_* APIs depend on FDT, which is not available durings_init().Signed-off-by Alice Guo <[email protected]>---
arch/arm/mach-imx/imx8ulp/soc.c | 14 +++++++++++++- arch/arm/mach-imx/imx9/scmi/soc.c | 15 ++++++++++++--- arch/arm/mach-imx/imx9/soc.c | 16 +++++++++++++--- arch/arm/mach-imx/mx7ulp/soc.c | 24 ++++++++++++++++++------ 4 files changed, 56 insertions(+), 13 deletions(-)arch/arm/mach-imx/imx8ulp/soc.c +0
-0
arch/arm/mach-imx/imx8ulp/soc.c static void disable_wdog(void __iomem *wdog_base) · line 350
Quoted 9 lines
arch/arm/mach-imx/imx8ulp/soc.c +5
-1@@ -343,7 +343,19 @@ static void disable_wdog(void __iomem *wdog_base)void init_wdog (void ) { -disable_wdog ((void __iomem *)WDG3_RBASE ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx8ulp-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx8ulp-wdt" )) {
Use ofnode_for_each_compatible_node.
Quoted 17 lines
arch/arm/mach-imx/imx8ulp/soc.c +8
-0+phys_addr_t base; + + base =ofnode_get_addr (node); +if (base ==FDT_ADDR_T_NONE ) +continue ; + +disable_wdog ((void __iomem *)base); + } }static struct mm_region imx8ulp_arm64_mem_map[] = {arch/arm/mach-imx/imx9/scmi/soc.c +0
-0@@ -786,9 +786,18 @@ static void gpio_reset(ulong gpio_base)int arch_cpu_init (void )
arch/arm/mach-imx/imx9/scmi/soc.c static void gpio_reset(ulong gpio_base) · line 793
Quoted 10 lines
arch/arm/mach-imx/imx9/scmi/soc.c +5
-3{if (IS_ENABLED (CONFIG_SPL_BUILD )) { -if (!IS_ENABLED (CONFIG_IMX952 )) { -disable_wdog ((void __iomem *)WDG3_BASE_ADDR ); -disable_wdog ((void __iomem *)WDG4_BASE_ADDR ); +ofnode node; + +for (node =ofnode_by_compatible (ofnode_null (),"fsl,imx93-wdt" ); +ofnode_valid (node); + node =ofnode_by_compatible (node,"fsl,imx93-wdt" )) {
Ditto.
And same to other changes in this patch.
Regards
Peng
PATCH v3 6/9 arm: dts: imx: Update watchdog nodes for dynamic base address lookup
In reply to [email protected]From: Alice Guo <[email protected]>
Update watchdog device tree nodes to enable dynamic base address retrieval for i.MX7ULP, i.MX8ULP, i.MX91, i.MX93, i.MX943, i.MX95 and i.MX952. This allows the bootloader to obtain watchdog base addresses from the device tree instead of using hardcoded values.
- imx7ulp: Add wdog2 node
- imx8ulp: Mark wdog3 available
- imx91/imx93: Add wdog4 and wdog5 nodes
Mark wdog3/wdog4/wdog5 available
- imx943: Add wdog4 node and mark wdog3/wdog4 available
- imx95/imx952: Add wdog4 node and mark wdog3/wdog4 available
Watchdog nodes are marked with "bootph-all" to ensure availability during early boot stages when init_wdog() occurs.
--- arch/arm/dts/imx7ulp-com-u-boot.dtsi | 2 ++ arch/arm/dts/imx7ulp-evk-u-boot.dtsi | 6 ++++++ arch/arm/dts/imx7ulp-u-boot.dtsi | 17 +++++++++++++++++ arch/arm/dts/imx8ulp-u-boot.dtsi | 4 ++++ arch/arm/dts/imx91-u-boot.dtsi | 12 ++++++++++++ arch/arm/dts/imx93-u-boot.dtsi | 12 ++++++++++++ arch/arm/dts/imx943-u-boot.dtsi | 19 +++++++++++++++++++ arch/arm/dts/imx95-u-boot.dtsi | 14 ++++++++++++++ arch/arm/dts/imx952-u-boot.dtsi | 14 ++++++++++++++ 9 files changed, 100 insertions(+)
arch/arm/dts/imx7ulp-com-u-boot.dtsi +2 -0
@@ -3,6 +3,8 @@ * Copyright 2019 Foundries.io */ +#include "imx7ulp-u-boot.dtsi" + &iomuxc1 { bootph-pre-ram; };
arch/arm/dts/imx7ulp-evk-u-boot.dtsi new file +6 -0
@@ -0,0 +1,6 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright 2026 NXP + */ + +#include "imx7ulp-u-boot.dtsi"
arch/arm/dts/imx7ulp-u-boot.dtsi new file +17 -0
@@ -0,0 +1,17 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright 2026 NXP + */ + +&ahbbridge0 { + wdog2: watchdog@40430000 { + compatible = "fsl,imx7ulp-wdt"; + reg = <0x40430000 0x10000>; + interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&pcc2 IMX7ULP_CLK_WDG2>; + assigned-clocks = <&pcc2 IMX7ULP_CLK_WDG2>; + assigned-clock-parents = <&scg1 IMX7ULP_CLK_FIRC_BUS_CLK>; + timeout-sec = <40>; + status = "disabled"; + }; +};
arch/arm/dts/imx8ulp-u-boot.dtsi +4 -0
@@ -61,3 +61,7 @@ }; }; #endif + +&wdog3 { + bootph-all; +};
arch/arm/dts/imx91-u-boot.dtsi +12 -0
@@ -90,3 +90,15 @@ }; }; }; + +&wdog3 { + bootph-all; +}; + +&wdog4 { + bootph-all; +}; + +&wdog5 { + bootph-all; +};
arch/arm/dts/imx93-u-boot.dtsi +12 -0
@@ -96,3 +96,15 @@ 0x000001b2 0x800001b6>; #thermal-sensor-cells = <1>; }; + +&wdog3 { + bootph-all; +}; + +&wdog4 { + bootph-all; +}; + +&wdog5 { + bootph-all; +};
arch/arm/dts/imx943-u-boot.dtsi +19 -0
@@ -159,6 +159,21 @@ }; }; +&aips4 { + bootph-all; + + wdog4: watchdog@49230000 { + compatible = "fsl,imx94-wdt", "fsl,imx93-wdt"; + reg = <0x49230000 0x10000>; + interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&scmi_clk IMX94_CLK_BUSWAKEUP>; + timeout-sec = <40>; + fsl,ext-reset-output; + status = "disabled"; + bootph-all; + }; +}; + &clk_ext1 { bootph-all; };
@@ -442,3 +457,7 @@ &sram0 { bootph-all; }; + +&wdog3 { + bootph-all; +};
arch/arm/dts/imx95-u-boot.dtsi +14 -0
@@ -138,6 +138,16 @@ &aips2 { bootph-all; + + wdog4: watchdog@424a0000 { + compatible = "fsl,imx93-wdt"; + reg = <0x424a0000 0x10000>; + interrupts = <GIC_SPI 78 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&scmi_clk IMX95_CLK_BUSWAKEUP>; + timeout-sec = <40>; + status = "disabled"; + bootph-all; + }; }; &aips3 {
@@ -238,3 +248,7 @@ &scmi_buf1 { bootph-all; }; + +&wdog3 { + bootph-all; +};
arch/arm/dts/imx952-u-boot.dtsi +14 -0
@@ -115,6 +115,16 @@ &aips2 { bootph-all; + + wdog4: watchdog@420c0000 { + compatible = "fsl,imx93-wdt"; + reg = <0x420c0000 0x10000>; + interrupts = <GIC_SPI 78 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&scmi_clk IMX952_CLK_BUSWAKEUP>; + timeout-sec = <40>; + status = "disabled"; + bootph-all; + }; }; &aips3 {
@@ -237,6 +247,10 @@ bootph-pre-ram; }; +&wdog3 { + bootph-all; +}; + &scmi_iomuxc { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_hog>;
Signature · 1 line
2.34.1
Re: [PATCH v3 6/9] arm: dts: imx: Update watchdog nodes for dynamic base address lookup
Quoted 19 lines · On Tue, May 12, 2026 at 11:10:13AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Update watchdog device tree nodes to enable dynamic base address retrieval for i.MX7ULP, i.MX8ULP, i.MX91, i.MX93, i.MX943, i.MX95 and i.MX952. This allows the bootloader to obtain watchdog base addresses from the device tree instead of using hardcoded values.
- imx7ulp: Add wdog2 node
- imx8ulp: Mark wdog3 available
- imx91/imx93: Add wdog4 and wdog5 nodes
Mark wdog3/wdog4/wdog5 available
- imx943: Add wdog4 node and mark wdog3/wdog4 available
- imx95/imx952: Add wdog4 node and mark wdog3/wdog4 availableWatchdog nodes are marked with "bootph-all" to ensure availability during early boot stages when
init_wdog()occurs.Signed-off-by Alice Guo <[email protected]>---
Quoted 11 lines
arch/arm/dts/imx7ulp-com-u-boot.dtsi | 2 ++ arch/arm/dts/imx7ulp-evk-u-boot.dtsi | 6 ++++++ arch/arm/dts/imx7ulp-u-boot.dtsi | 17 +++++++++++++++++ arch/arm/dts/imx8ulp-u-boot.dtsi | 4 ++++ arch/arm/dts/imx91-u-boot.dtsi | 12 ++++++++++++ arch/arm/dts/imx93-u-boot.dtsi | 12 ++++++++++++ arch/arm/dts/imx943-u-boot.dtsi | 19 +++++++++++++++++++ arch/arm/dts/imx95-u-boot.dtsi | 14 ++++++++++++++ arch/arm/dts/imx952-u-boot.dtsi | 14 ++++++++++++++ 9 files changed, 100 insertions(+)
Patch itself LGTM:
switched order.
Regards
Peng
PATCH v3 7/9 watchdog: ulp_wdog: Use driver model for reset_cpu()
In reply to [email protected]From: Alice Guo <[email protected]>
Replace hardcoded WDOG_BASE_ADDR with driver model based dynamic address lookup from device tree.
- Remove hardcoded WDOG_BASE_ADDR from hw_watchdog_* functions
- Reimplement reset_cpu() using UCLASS_WDT device iteration
- Add ulp_wdt_expire_now() callback for standard WDT interface
- Pass wdog register pointer to hw_watchdog_set_timeout()
--- drivers/watchdog/ulp_wdog.c | 79 ++++++++++++++++----------------------------- 1 file changed, 28 insertions(+), 51 deletions(-)
drivers/watchdog/ulp_wdog.c +28 -51
@@ -7,6 +7,7 @@#include <asm/io.h> #include <asm/arch/imx-regs.h> #include <dm.h> +#include <linux/delay.h> #include <wdt.h> /*
@@ -51,11 +52,9 @@ struct ulp_wdt_priv {#define CLK_RATE_1KHZ 1000#define CLK_RATE_32KHZ 125 -void hw_watchdog_set_timeout (u16 val) +void hw_watchdog_set_timeout (struct wdog_regs *wdog,u16 val) {/* setting timeout value */ -struct wdog_regs *wdog = (struct wdog_regs *)WDOG_BASE_ADDR ; -writel (val, &wdog->toval); }
@@ -89,7 +88,7 @@ void ulp_watchdog_init(struct wdog_regs *wdog, u16 timeout)while (!(readl (&wdog->cs) &WDGCS_ULK )) ; -hw_watchdog_set_timeout (timeout); +hw_watchdog_set_timeout (wdog, timeout);writel (0 , &wdog->win);/* setting 1-kHz clock source, enable counter running, and clear interrupt */
@@ -107,57 +106,20 @@ void ulp_watchdog_init(struct wdog_regs *wdog, u16 timeout)ulp_watchdog_reset (wdog); } -void hw_watchdog_reset (void ) -{ -struct wdog_regs *wdog = (struct wdog_regs *)WDOG_BASE_ADDR ; - -ulp_watchdog_reset (wdog); -} - -void hw_watchdog_init (void ) -{ -struct wdog_regs *wdog = (struct wdog_regs *)WDOG_BASE_ADDR ; - -ulp_watchdog_init (wdog,CONFIG_WATCHDOG_TIMEOUT_MSECS ); -} - -#if !CONFIG_IS_ENABLED (SYSRESET ) +#if !CONFIG_IS_ENABLED (SYSRESET ) &&CONFIG_IS_ENABLED (WDT )void reset_cpu (void ) { -struct wdog_regs *wdog = (struct wdog_regs *)WDOG_BASE_ADDR ; -u32 cmd32 =0 ; - -if (readl (&wdog->cs) &WDGCS_CMD32EN ) { -writel (UNLOCK_WORD , &wdog->cnt); - cmd32 =WDGCS_CMD32EN ; - }else { -dmb (); -__raw_writel (UNLOCK_WORD0 , &wdog->cnt); -__raw_writel (UNLOCK_WORD1 , &wdog->cnt); -dmb (); - } +struct udevice *wdt; -/* Wait WDOG Unlock */ -while (!(readl (&wdog->cs) &WDGCS_ULK )) - ; +for (uclass_first_device (UCLASS_WDT , &wdt); + wdt; +uclass_next_device (&wdt)) { +if (!dev_read_enabled (wdt)) +continue ; -hw_watchdog_set_timeout (5 );/* 5ms timeout for general; 40ms timeout for imx93 */ -writel (0 , &wdog->win); - -/* enable counter running */ -if (IS_ENABLED (CONFIG_ARCH_IMX9 )) -writel ((cmd32 |WDGCS_WDGE | (WDG_LPO_CLK <<8 ) |WDOG_CS_PRES | -WDGCS_INT ), &wdog->cs); -else -writel ((cmd32 |WDGCS_WDGE | (WDG_LPO_CLK <<8 )), &wdog->cs); - -/* Wait WDOG reconfiguration */ -while (!(readl (&wdog->cs) &WDGCS_RCS )) - ; - -hw_watchdog_reset (); - -while (1 ); +wdt_expire_now (wdt,0 ); +break ; + } }#endif
@@ -184,6 +146,20 @@ static int ulp_wdt_reset(struct udevice *dev)return 0 ; } +static int ulp_wdt_expire_now (struct udevice *dev,ulong flags) +{ +int ret; + +/* 5ms timeout for all others; 40ms timeout for "fsl,imx93-wdt" */ + ret =ulp_wdt_start (dev,5 , flags); +if (ret) +return ret; + +mdelay (50 ); + +return 0 ; +} +static int ulp_wdt_probe (struct udevice *dev) {struct ulp_wdt_priv *priv =dev_get_priv (dev);
@@ -202,6 +178,7 @@ static int ulp_wdt_probe(struct udevice *dev)static const struct wdt_ops ulp_wdt_ops = { .start = ulp_wdt_start, .reset = ulp_wdt_reset, + .expire_now = ulp_wdt_expire_now, };static const struct udevice_id ulp_wdt_ids[] = {
Signature · 1 line
2.34.1
Re: [PATCH v3 7/9] watchdog: ulp_wdog: Use driver model for reset_cpu()
Quoted 9 lines · On Tue, May 12, 2026 at 11:10:14AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Replace hardcoded
WDOG_BASE_ADDRwith driver model based dynamic address lookup from device tree.- Remove hardcoded
WDOG_BASE_ADDRfrom hw_watchdog_* functions
- Reimplementreset_cpu()usingUCLASS_WDTdevice iteration
- Addulp_wdt_expire_now()callback for standard WDT interface
- Pass wdog register pointer tohw_watchdog_set_timeout()
In theory, patch 9 shoud be merge with this patch to avoid git bisect issues. or switch to uclass_wdt step by step.
Because without patch 9, reset_cpu will not work if people are doing git bisect.
Or I may miss something.
Regards
Peng
RE: [PATCH v3 7/9] watchdog: ulp_wdog: Use driver model for reset_cpu()
Quoted 11 lines
Subject: Re: [PATCH v3 7/9] watchdog:
ulp_wdog: Use driver model forreset_cpu()Quoted 3 lines · On Tue, May 12, 2026 at 11:10:14AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Replace hardcoded
WDOG_BASE_ADDRwith driver model baseddynamic
Quoted 2 lines
address lookup from device tree.
Quoted 7 lines
Quoted 1 line
- Remove hardcoded
WDOG_BASE_ADDRfrom hw_watchdog_*functions
Quoted 3 lines
- Reimplement
reset_cpu()usingUCLASS_WDTdevice iteration
- Addulp_wdt_expire_now()callback for standard WDT interface
- Pass wdog register pointer tohw_watchdog_set_timeout()In theory, patch 9 shoud be merge with this patch to avoid git bisect
Typo: patch 8.
Regards
Peng
Quoted 10 lines
issues.
or switch touclass_wdtstep by step.Because without patch 9,
reset_cpuwill not work if people are doing git bisect.Or I may miss something.
Regards
Peng
PATCH v3 8/9 arm: dts: imx: Enable watchdog driver model support
In reply to [email protected]From: Alice Guo <[email protected]>
Enable CONFIG_WDT for boards using ULP watchdog to allow reset_cpu() to use watchdog driver model instead of hardcoded base addresses.
Remove wdog3 status = "disabled" overrides from U-Boot device tree overlays, as the watchdog device needs to be accessible for driver model based reset functionality.
--- arch/arm/dts/imx8ulp-evk-u-boot.dtsi | 4 ---- arch/arm/dts/imx943-evk-u-boot.dtsi | 4 ---- arch/arm/dts/imx95-15x15-evk-u-boot.dtsi | 4 ---- arch/arm/dts/imx95-19x19-evk-u-boot.dtsi | 4 ---- arch/arm/dts/imx95-toradex-smarc-dev-u-boot.dtsi | 4 ---- arch/arm/dts/imx95-verdin-wifi-dev-u-boot.dtsi | 4 ---- configs/imx8ulp_evk_defconfig | 1 + configs/imx93-phycore_defconfig | 1 + configs/imx943_evk_defconfig | 1 + configs/imx95_15x15_evk_defconfig | 1 + configs/imx95_evk.config | 1 + configs/mx7ulp_com_defconfig | 1 + configs/toradex-smarc-imx95_defconfig | 1 + configs/verdin-imx95_defconfig | 1 + 14 files changed, 8 insertions(+), 24 deletions(-)
arch/arm/dts/imx8ulp-evk-u-boot.dtsi +0 -4
@@ -26,10 +26,6 @@ status = "disabled"; }; -&wdog3 { - status = "disabled"; -}; - &per_bridge4 { bootph-pre-ram; };
arch/arm/dts/imx943-evk-u-boot.dtsi +0 -4
@@ -153,10 +153,6 @@ bootph-pre-ram; }; -&wdog3 { - status = "disabled"; -}; - &xspi1 { bootph-pre-ram; pinctrl-names = "default";
arch/arm/dts/imx95-15x15-evk-u-boot.dtsi +0 -4
@@ -44,10 +44,6 @@ bootph-pre-ram; }; -&wdog3 { - status = "disabled"; -}; - &pinctrl_uart1 { bootph-pre-ram; };
arch/arm/dts/imx95-19x19-evk-u-boot.dtsi +0 -4
@@ -28,10 +28,6 @@ bootph-pre-ram; }; -&wdog3 { - status = "disabled"; -}; - &pinctrl_uart1 { bootph-pre-ram; };
arch/arm/dts/imx95-toradex-smarc-dev-u-boot.dtsi +0 -4
@@ -104,7 +104,3 @@ &usdhc2 { bootph-pre-ram; }; - -&wdog3 { - status = "disabled"; -};
arch/arm/dts/imx95-verdin-wifi-dev-u-boot.dtsi +0 -4
@@ -106,7 +106,3 @@ &usdhc1 { bootph-pre-ram; }; - -&wdog3 { - status = "disabled"; -};
configs/imx8ulp_evk_defconfig +1 -0
@@ -92,3 +92,4 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_NXP_FSPI=y CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y
configs/imx93-phycore_defconfig +1 -0
@@ -156,6 +156,7 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x1fc9 CONFIG_USB_GADGET_PRODUCT_NUM=0x0152 CONFIG_CI_UDC=y CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y # CONFIG_RSA is not set # CONFIG_SPL_SHA256 is not set CONFIG_LZO=y
configs/imx943_evk_defconfig +1 -0
@@ -151,3 +151,4 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5 CONFIG_SDP_LOADADDR=0x90400000 CONFIG_SPL_USB_SDP_SUPPORT=y CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y
configs/imx95_15x15_evk_defconfig +1 -0
@@ -147,5 +147,6 @@ CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_NXP_FSPI=y CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y CONFIG_LZO=y CONFIG_BZIP2=y
configs/imx95_evk.config +1 -0
@@ -151,3 +151,4 @@ CONFIG_NXP_FSPI=y CONFIG_ULP_WATCHDOG=y CONFIG_LZO=y CONFIG_BZIP2=y +CONFIG_WDT=y
configs/mx7ulp_com_defconfig +1 -0
@@ -63,3 +63,4 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5 CONFIG_CI_UDC=y CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y
configs/toradex-smarc-imx95_defconfig +1 -0
@@ -175,5 +175,6 @@ CONFIG_USB_GADGET_OS_DESCRIPTORS=y CONFIG_CI_UDC=y CONFIG_SDP_LOADADDR=0x90400000 CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y # CONFIG_SPL_SHA1 is not set CONFIG_LZO=y
configs/verdin-imx95_defconfig +1 -0
@@ -180,5 +180,6 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0x4000 CONFIG_USB_GADGET_OS_DESCRIPTORS=y CONFIG_SDP_LOADADDR=0x90400000 CONFIG_ULP_WATCHDOG=y +CONFIG_WDT=y # CONFIG_SPL_SHA1 is not set CONFIG_LZO=y
Signature · 1 line
2.34.1
Re: [PATCH v3 8/9] arm: dts: imx: Enable watchdog driver model support
Quoted 10 lines · On Tue, May 12, 2026 at 11:10:15AM +0800, [email protected] wrote:
From: Alice Guo <[email protected]>
Enable
CONFIG_WDTfor boards using ULP watchdog to allowreset_cpu()to use watchdog driver model instead of hardcoded base addresses.Remove wdog3 status = "disabled" overrides from U-Boot device tree overlays, as the watchdog device needs to be accessible for driver model based reset functionality.
Signed-off-by Alice Guo <[email protected]>
PATCH v3 9/9 imx: Remove hardcoded watchdog base address macros
In reply to [email protected]From: Alice Guo <[email protected]>
The watchdog base addresses are now obtained from the devicetree via ofnode_* functions. Remove the hardcoded macro definitions as they are no longer needed.
--- arch/arm/include/asm/arch-imx8ulp/imx-regs.h | 2 -- arch/arm/include/asm/arch-imx9/imx-regs.h | 9 --------- include/configs/imx8ulp_evk.h | 2 -- include/configs/imx91_evk.h | 2 -- include/configs/imx91_frdm.h | 2 -- include/configs/imx93_evk.h | 3 --- include/configs/imx93_frdm.h | 3 --- include/configs/imx93_qsb.h | 2 -- include/configs/imx93_var_som.h | 3 --- include/configs/imx94_evk.h | 3 --- include/configs/imx95_evk.h | 2 -- include/configs/kontron-osm-s-mx93.h | 2 -- include/configs/mx7ulp_com.h | 3 --- include/configs/mx7ulp_evk.h | 3 --- include/configs/phycore_imx91_93.h | 3 --- include/configs/toradex-smarc-imx95.h | 2 -- 16 files changed, 46 deletions(-)
arch/arm/include/asm/arch-imx8ulp/imx-regs.h +0 -2
@@ -20,8 +20,6 @@#define SIM1_BASE_ADDR 0x29290000 -#define WDG3_RBASE 0x292a0000UL -#define SIM_SEC_BASE_ADDR 0x2802B000#define CGC1_SOSCDIV_ADDR 0x292C0108
arch/arm/include/asm/arch-imx9/imx-regs.h +0 -9
@@ -17,15 +17,6 @@#define ANATOP_BASE_ADDR 0x44480000UL -#ifdef CONFIG_IMX94 -#define WDG3_BASE_ADDR 0x49220000UL -#define WDG4_BASE_ADDR 0x49230000UL -#else -#define WDG3_BASE_ADDR 0x42490000UL -#define WDG4_BASE_ADDR 0x424a0000UL -#endif -#define WDG5_BASE_ADDR 0x424b0000UL -#define GPIO2_BASE_ADDR 0x43810000UL#define GPIO3_BASE_ADDR 0x43820000UL#define GPIO4_BASE_ADDR 0x43840000UL
include/configs/imx8ulp_evk.h +0 -2
@@ -30,6 +30,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000/* 2GB DDR */ -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_RBASE#endif
include/configs/imx91_evk.h +0 -2
@@ -16,6 +16,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000/* 2GB DDR */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx91_frdm.h +0 -2
@@ -20,6 +20,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE SZ_2G/* 2GB DDR */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx93_evk.h +0 -3
@@ -26,7 +26,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000/* 2GB DDR */ -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx93_frdm.h +0 -3
@@ -20,7 +20,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000/* 2GB DDR */ -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx93_qsb.h +0 -2
@@ -16,6 +16,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000/* 2GB DDR */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx93_var_som.h +0 -3
@@ -38,7 +38,4 @@#define CFG_SYS_FSL_USDHC_NUM 2 -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx94_evk.h +0 -3
@@ -18,7 +18,4 @@#define PHYS_SDRAM_SIZE 0x70000000UL/* 2GB - 256MB DDR */ #define PHYS_SDRAM_2_SIZE 0x180000000/* 8GB */ -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/imx95_evk.h +0 -2
@@ -23,6 +23,4 @@#define PHYS_SDRAM_2_SIZE 0x380000000/* 14GB (Totally 16GB) */ #endif -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
include/configs/kontron-osm-s-mx93.h +0 -2
@@ -25,6 +25,4 @@#define CFG_MXC_USB_FLAGS 0#endif -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif /* __KONTRON_MX93_CONFIG_H */
include/configs/mx7ulp_com.h +0 -3
@@ -15,9 +15,6 @@#include "imx7ulp_spl.h" #endif -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG1_RBASE -#define CFG_SYS_HZ_CLOCK 1000000/* Fixed at 1MHz from TSTMR */ /* UART */
include/configs/mx7ulp_evk.h +0 -3
@@ -11,9 +11,6 @@#include <linux/sizes.h> #include <asm/arch/imx-regs.h> -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG1_RBASE -#define CFG_SYS_HZ_CLOCK 1000000/* Fixed at 1Mhz from TSTMR */ /* UART */
include/configs/phycore_imx91_93.h +0 -3
@@ -22,7 +22,4 @@#define PHYS_SDRAM 0x80000000#define PHYS_SDRAM_SIZE 0x80000000 -/* Using ULP WDOG for reset */ -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif /* __PHYCORE_IMX91_93_H */
include/configs/toradex-smarc-imx95.h +0 -2
@@ -19,6 +19,4 @@#define PHYS_SDRAM_SIZE (SZ_2G - SZ_256M)#define PHYS_SDRAM_2_SIZE SZ_6G -#define WDOG_BASE_ADDR WDG3_BASE_ADDR -#endif
Signature · 1 line
2.34.1