Skip to content

Commit cc0dc9e

Browse files
UpsylonbareWim Van Sebroeck
authored andcommitted
watchdog: stm32_iwdg: fix error message during driver probe
The commit 3ab1663 ("watchdog: stm32_iwdg: Add pretimeout support") introduces the support for the pre-timeout interrupt. The support for this interrupt is optional but the driver uses the platform_get_irq() which produces an error message during the driver probe if we don't have any `interrupts` property in the DT. Use the platform_get_irq_optional() API to get rid of the error message as this property is optional. Fixes: 3ab1663 ("watchdog: stm32_iwdg: Add pretimeout support") Signed-off-by: Clément Le Goffic <clement.legoffic@foss.st.com> Reviewed-by: Marek Vasut <marex@denx.de> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Link: https://lore.kernel.org/r/20241218092227.771133-1-clement.legoffic@foss.st.com Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
1 parent fc033cf commit cc0dc9e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/watchdog/stm32_iwdg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ static int stm32_iwdg_irq_init(struct platform_device *pdev,
286286
if (!wdt->data->has_early_wakeup)
287287
return 0;
288288

289-
irq = platform_get_irq(pdev, 0);
289+
irq = platform_get_irq_optional(pdev, 0);
290290
if (irq <= 0)
291291
return 0;
292292

0 commit comments

Comments
 (0)