From: Fabio Estevam <festevam@gmail.com>
To: sbabic@denx.de
Cc: uboot-imx@nxp.com, u-boot@lists.denx.de, marex@denx.de,
Fabio Estevam <festevam@denx.de>
Subject: [PATCH 2/3] mx7dsabresd: Convert to watchdog driver model
Date: Tue, 8 Aug 2023 18:40:39 -0300 [thread overview]
Message-ID: <20230808214040.1382330-2-festevam@gmail.com> (raw)
In-Reply-To: <20230808214040.1382330-1-festevam@gmail.com>
From: Fabio Estevam <festevam@denx.de>
Commit 68dcbdd594d4 ("ARM: imx: Add weak default reset_cpu()") caused
the 'reset' command in U-Boot to not cause a board reset.
Fix it by switching to the watchdog driver model via sysreset, which
is the preferred method for implementing the watchdog reset.
Signed-off-by: Fabio Estevam <festevam@denx.de>
---
arch/arm/dts/imx7d-sdb-u-boot.dtsi | 12 ++++++++++++
configs/mx7dsabresd_defconfig | 3 +++
2 files changed, 15 insertions(+)
diff --git a/arch/arm/dts/imx7d-sdb-u-boot.dtsi b/arch/arm/dts/imx7d-sdb-u-boot.dtsi
index 818528c418f5..2e234b6b5828 100644
--- a/arch/arm/dts/imx7d-sdb-u-boot.dtsi
+++ b/arch/arm/dts/imx7d-sdb-u-boot.dtsi
@@ -1,5 +1,13 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
+/ {
+ wdt-reboot {
+ compatible = "wdt-reboot";
+ wdt = <&wdog1>;
+ bootph-pre-ram;
+ };
+};
+
&fec2 {
status = "disable";
};
@@ -58,3 +66,7 @@
>;
};
};
+
+&wdog1 {
+ bootph-pre-ram;
+};
diff --git a/configs/mx7dsabresd_defconfig b/configs/mx7dsabresd_defconfig
index 26e68d30d267..1c8105f44f28 100644
--- a/configs/mx7dsabresd_defconfig
+++ b/configs/mx7dsabresd_defconfig
@@ -73,6 +73,8 @@ CONFIG_MXC_UART=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_SOFT_SPI=y
+CONFIG_SYSRESET=y
+CONFIG_SYSRESET_WATCHDOG=y
CONFIG_IMX_THERMAL=y
CONFIG_USB=y
CONFIG_USB_EHCI_HCD=y
@@ -85,4 +87,5 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525
CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
CONFIG_CI_UDC=y
CONFIG_USB_GADGET_DOWNLOAD=y
+CONFIG_IMX_WATCHDOG=y
CONFIG_ERRNO_STR=y
--
2.34.1
next prev parent reply other threads:[~2023-08-08 21:41 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-08 21:40 [PATCH 1/3] imx7d-sdb-u-boot: Pass SPDX-License tag Fabio Estevam
2023-08-08 21:40 ` Fabio Estevam [this message]
2023-08-08 21:46 ` [PATCH 2/3] mx7dsabresd: Convert to watchdog driver model Marek Vasut
2023-10-16 16:46 ` sbabic
2023-08-08 21:40 ` [PATCH 3/3] smegw01: " Fabio Estevam
2023-08-08 21:46 ` Marek Vasut
2023-10-16 16:46 ` sbabic
2023-08-08 21:46 ` [PATCH 1/3] imx7d-sdb-u-boot: Pass SPDX-License tag Marek Vasut
2023-10-16 16:45 ` sbabic
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230808214040.1382330-2-festevam@gmail.com \
--to=festevam@gmail.com \
--cc=festevam@denx.de \
--cc=marex@denx.de \
--cc=sbabic@denx.de \
--cc=u-boot@lists.denx.de \
--cc=uboot-imx@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox