From e695d3a0b3b302974c1fd7b36ea91fe58fb9ca14 Mon Sep 17 00:00:00 2001 From: Chen Zhong Date: Wed, 25 Oct 2017 21:15:59 +0800 Subject: mfd: mt6397: Create irq mappings in mfd core driver The core driver should create and manage irq mappings instead of leaf drivers. This patch change to pass irq domain to devm_mfd_add_devices() and it will create mapping for irq resources automatically. And remove irq mapping in rtc driver since this has been done in core driver. Signed-off-by: Chen Zhong Acked-by: Alexandre Belloni Signed-off-by: Lee Jones --- drivers/rtc/rtc-mt6397.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'drivers/rtc') diff --git a/drivers/rtc/rtc-mt6397.c b/drivers/rtc/rtc-mt6397.c index 1a61fa56f3ad..385f8303bb41 100644 --- a/drivers/rtc/rtc-mt6397.c +++ b/drivers/rtc/rtc-mt6397.c @@ -322,10 +322,9 @@ static int mtk_rtc_probe(struct platform_device *pdev) res = platform_get_resource(pdev, IORESOURCE_MEM, 0); rtc->addr_base = res->start; - res = platform_get_resource(pdev, IORESOURCE_IRQ, 0); - rtc->irq = irq_create_mapping(mt6397_chip->irq_domain, res->start); - if (rtc->irq <= 0) - return -EINVAL; + rtc->irq = platform_get_irq(pdev, 0); + if (rtc->irq < 0) + return rtc->irq; rtc->regmap = mt6397_chip->regmap; rtc->dev = &pdev->dev; -- cgit v1.2.3