diff mbox series

[1/1] watchdog: don't autostart watchdog on Sunxi boards

Message ID 20211105183431.117221-1-heinrich.schuchardt@canonical.com
State Accepted
Commit 86798ee0c148db248d8e3e9b6395bbe9e24d9149
Delegated to: Andre Przywara
Headers show
Series [1/1] watchdog: don't autostart watchdog on Sunxi boards | expand

Commit Message

Heinrich Schuchardt Nov. 5, 2021, 6:34 p.m. UTC
The Sunxi boards only support a 16 second watchdog timeout. This is too
short to boot Linux. The UEFI specification requires 300 seconds as
default timeout.

Change the default for CONFIG_WATCHDOG_AUTOSTART for ARCH_SUNXI.

Fixes: b147bd3607f8 ("sunxi: Enable watchdog timer support by default")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
---
 drivers/watchdog/Kconfig | 1 +
 1 file changed, 1 insertion(+)

Comments

Andre Przywara Nov. 9, 2021, 10:09 p.m. UTC | #1
On Fri,  5 Nov 2021 19:34:31 +0100
Heinrich Schuchardt <heinrich.schuchardt@canonical.com> wrote:

> The Sunxi boards only support a 16 second watchdog timeout. This is too
> short to boot Linux. The UEFI specification requires 300 seconds as
> default timeout.

As detailed in this thread here [1], I would argue that
always keeping the watchdog running at all *after* U-Boot handed
off (either via booti/bootz/bootm or via ExitBootServices) sounds
questionable to me, especially when this wasn't the case so far.
The Linux kernel boot protocols (for arm and arm64) do not speak about
a watchdog, it would be interesting to see what's the expectation is
here.

Anyway we run into real issues with current HEAD, and be it for the
short period, so disabling it by default is the right way, at least for
now.

> Change the default for CONFIG_WATCHDOG_AUTOSTART for ARCH_SUNXI.
> 
> Fixes: b147bd3607f8 ("sunxi: Enable watchdog timer support by default")
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>

Tested-by: Andre Przywara <andre.przywara@arm.com>

Cheers,
Andre

> ---
>  drivers/watchdog/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig
> index d306054a8c..1177f17fd8 100644
> --- a/drivers/watchdog/Kconfig
> +++ b/drivers/watchdog/Kconfig
> @@ -12,6 +12,7 @@ config WATCHDOG
>  config WATCHDOG_AUTOSTART
>  	bool "Automatically start watchdog timer"
>  	depends on WDT
> +	default n if ARCH_SUNXI
>  	default y
>  	help
>  	  Automatically start watchdog timer and start servicing it during
diff mbox series

Patch

diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig
index d306054a8c..1177f17fd8 100644
--- a/drivers/watchdog/Kconfig
+++ b/drivers/watchdog/Kconfig
@@ -12,6 +12,7 @@  config WATCHDOG
 config WATCHDOG_AUTOSTART
 	bool "Automatically start watchdog timer"
 	depends on WDT
+	default n if ARCH_SUNXI
 	default y
 	help
 	  Automatically start watchdog timer and start servicing it during