diff options
Diffstat (limited to 'drivers/rtc/rtc-mv.c')
-rw-r--r-- | drivers/rtc/rtc-mv.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-mv.c b/drivers/rtc/rtc-mv.c index 768e2edb967..b2185f4255a 100644 --- a/drivers/rtc/rtc-mv.c +++ b/drivers/rtc/rtc-mv.c @@ -12,6 +12,7 @@ #include <linux/bcd.h> #include <linux/io.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <linux/delay.h> #include <linux/gfp.h> #include <linux/module.h> @@ -273,7 +274,7 @@ static int __devinit mv_rtc_probe(struct platform_device *pdev) if (pdata->irq >= 0) { writel(0, pdata->ioaddr + RTC_ALARM_INTERRUPT_MASK_REG_OFFS); if (devm_request_irq(&pdev->dev, pdata->irq, mv_rtc_interrupt, - IRQF_DISABLED | IRQF_SHARED, + IRQF_SHARED, pdev->name, pdata) < 0) { dev_warn(&pdev->dev, "interrupt not available.\n"); pdata->irq = -1; @@ -294,11 +295,19 @@ static int __exit mv_rtc_remove(struct platform_device *pdev) return 0; } +#ifdef CONFIG_OF +static struct of_device_id rtc_mv_of_match_table[] = { + { .compatible = "mrvl,orion-rtc", }, + {} +}; +#endif + static struct platform_driver mv_rtc_driver = { .remove = __exit_p(mv_rtc_remove), .driver = { .name = "rtc-mv", .owner = THIS_MODULE, + .of_match_table = of_match_ptr(rtc_mv_of_match_table), }, }; |