watchdog: at91sam9: request the irq with IRQF_NO_SUSPEND
authorBoris BREZILLON <[email protected]>
Mon, 2 Mar 2015 09:18:17 +0000 (10:18 +0100)
committerRafael J. Wysocki <[email protected]>
Thu, 5 Mar 2015 23:46:31 +0000 (00:46 +0100)
The watchdog interrupt (only used when activating software watchdog)
shouldn't be suspended when entering suspend mode, because it is shared
with a timer device (which request the line with IRQF_NO_SUSPEND) and once
the watchdog "Mode Register" has been written, it cannot be changed (which
means we cannot disable the watchdog interrupt when entering suspend).

Signed-off-by: Boris Brezillon <[email protected]>
Reviewed-by: Alexandre Belloni <[email protected]>
Acked-by: Guenter Roeck <[email protected]>
Acked-by: Nicolas Ferre <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
drivers/watchdog/at91sam9_wdt.c

index 6df940528fd21b0cef8524004645fe472b7f7061..1443b3c391de497c05fe332f1c4cdd067bc5f5c9 100644 (file)
@@ -208,7 +208,8 @@ static int at91_wdt_init(struct platform_device *pdev, struct at91wdt *wdt)
 
        if ((tmp & AT91_WDT_WDFIEN) && wdt->irq) {
                err = request_irq(wdt->irq, wdt_interrupt,
-                                 IRQF_SHARED | IRQF_IRQPOLL,
+                                 IRQF_SHARED | IRQF_IRQPOLL |
+                                 IRQF_NO_SUSPEND,
                                  pdev->name, wdt);
                if (err)
                        return err;