]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/rtc/rtc-coh901331.c
Merge branch 'bugzilla-15749' into release
[karo-tx-linux.git] / drivers / rtc / rtc-coh901331.c
index 03ea530981d1e66328625fb26567cc40e35f9f23..316f484999b55fb861667b5c6950654959ab7b75 100644 (file)
@@ -14,6 +14,7 @@
 #include <linux/pm.h>
 #include <linux/platform_device.h>
 #include <linux/io.h>
+#include <linux/slab.h>
 
 /*
  * Registers in the COH 901 331
@@ -271,12 +272,13 @@ static int coh901331_resume(struct platform_device *pdev)
 {
        struct coh901331_port *rtap = dev_get_drvdata(&pdev->dev);
 
-       if (device_may_wakeup(&pdev->dev))
+       if (device_may_wakeup(&pdev->dev)) {
                disable_irq_wake(rtap->irq);
-       else
+       } else {
                clk_enable(rtap->clk);
                writel(rtap->irqmaskstore, rtap->virtbase + COH901331_IRQ_MASK);
                clk_disable(rtap->clk);
+       }
        return 0;
 }
 #else