From: Heinrich Schuchardt Date: Tue, 2 Nov 2021 18:44:30 +0000 (+0100) Subject: sandbox: fix sandbox_wdt_expire_now() X-Git-Tag: baikal/mips/sdk5.9~15^2^2~45^2~2 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=b5b260e3c0133fe9477c97bf285f6c7077ee74f9;p=uboot.git sandbox: fix sandbox_wdt_expire_now() With CONFIG_SYSRESET_WATCHDOG=y the sandbox can use a watchdog based system reset. To make this work calling sandbox_wdt_expire_now() must lead to a reset. With this change we can test the development suggested in [PATCH 0/4] Improved sysreset/watchdog uclass integration https://lists.denx.de/pipermail/u-boot/2021-August/458656.html Signed-off-by: Heinrich Schuchardt Reviewed-by: Simon Glass --- diff --git a/drivers/watchdog/sandbox_wdt.c b/drivers/watchdog/sandbox_wdt.c index e05d82789f..535614f04d 100644 --- a/drivers/watchdog/sandbox_wdt.c +++ b/drivers/watchdog/sandbox_wdt.c @@ -39,6 +39,7 @@ static int sandbox_wdt_reset(struct udevice *dev) static int sandbox_wdt_expire_now(struct udevice *dev, ulong flags) { sandbox_wdt_start(dev, 1, flags); + sandbox_reset(); return 0; }