watchdog: stm32_iwdg: Add pretimeout support
The STM32MP15xx IWDG adds registers which permit this IP to generate
pretimeout interrupt. This interrupt can also be used to wake the CPU
from suspend. Implement support for generating this interrupt and let
userspace configure the pretimeout. In case the pretimeout is not
configured by user, set pretimeout to 3/4 of the WDT timeout cycle.
Signed-off-by: Marek Vasut <marex@denx.de>
Reviewed-by: Clément Le Goffic <clement.legoffic@foss.st.com>
Tested-by: Clément Le Goffic <clement.legoffic@foss.st.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20240415134903.8084-1-marex@denx.de
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>