]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/rtc/rtc-twl4030.c
Merge current mainline tree into linux-omap tree
[linux-2.6-omap-h63xx.git] / drivers / rtc / rtc-twl4030.c
index d933d097c38b3e1fe00eef7e4e74842ea0ecc6b4..c77ee1f9845c986cc3ca388e9ca8321a83fcd14c 100644 (file)
@@ -19,6 +19,7 @@
  */
 
 #include <linux/kernel.h>
+#include <linux/errno.h>
 #include <linux/init.h>
 #include <linux/module.h>
 #include <linux/types.h>
@@ -415,8 +416,8 @@ static int __devinit twl4030_rtc_probe(struct platform_device *pdev)
        int irq = platform_get_irq(pdev, 0);
        u8 rd_reg;
 
-       if (irq < 0)
-               return irq;
+       if (irq <= 0)
+               return -EINVAL;
 
        rtc = rtc_device_register(pdev->name,
                                  &pdev->dev, &twl4030_rtc_ops, THIS_MODULE);