i.MX: Fix inverted register bits in wdt code.
PATCH 1/1 i.MX: Fix inverted register bits in wdt code.
Documentation says for WDA '0: Assert WDOG output.' and for SRS '0: Assert system reset signal.'.
--- hw/misc/imx2_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/misc/imx2_wdt.c +1 -1
@@ -28,7 +28,7 @@ static void imx2_wdt_write(void *opaque, hwaddr addr, uint64_t value, unsigned int size) {if (addr ==IMX2_WDT_WCR && - (value & (IMX2_WDT_WCR_WDA |IMX2_WDT_WCR_SRS ))) { + (~value & (IMX2_WDT_WCR_WDA |IMX2_WDT_WCR_SRS ))) {watchdog_perform_action (); } }
Signature · 1 line
2.22.0
Peter Maydell
AppliedQuoted 8 lines · Roman Kapl
Documentation says for WDA '0: Assert WDOG output.' and for SRS '0: Assert system reset signal.'.
Signed-off-by Roman Kapl <[email protected]>--- hw/misc/imx2_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to target-arm.next, thanks.
(It looks like we're missing a lot of the watchdog functionality in our model, ie the actual watchdog timer parts, enable bits, etc etc...)
-- PMM
Quoted 10 lines · Peter Maydell
Quoted 8 lines · Roman Kapl
Documentation says for WDA '0: Assert WDOG output.' and for SRS '0: Assert system reset signal.'.
Signed-off-by Roman Kapl <[email protected]>--- hw/misc/imx2_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 5 lines
Applied to target-arm.next, thanks.
(It looks like we're missing a lot of the watchdog functionality in our model, ie the actual watchdog timer parts, enable bits, etc etc...)
Yes, but the target restart functionality is the most important one. If I've read the i.MX forums correctly it is the easiest way to restart the board correctly.
Best regards, Roman Kapl
Quoted 3 lines
-- PMM