diff options
author | Pi-Hsun Shih <pihsun@chromium.org> | 2019-03-11 15:55:40 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-01-27 14:50:37 +0100 |
commit | fe7005a0239f54cf76ea6cbe89701199105bf6d3 (patch) | |
tree | 79593b3f18c3419457288ac3aac64b80ab490493 /drivers/rtc | |
parent | af06cc1c974858ecf22a77e4447a4ee05a07b50a (diff) | |
download | linux-stable-fe7005a0239f54cf76ea6cbe89701199105bf6d3.tar.gz linux-stable-fe7005a0239f54cf76ea6cbe89701199105bf6d3.tar.bz2 linux-stable-fe7005a0239f54cf76ea6cbe89701199105bf6d3.zip |
rtc: mt6397: Don't call irq_dispose_mapping.
[ Upstream commit 24db953e942bd7a983e97892bdaddf69d00b1199 ]
The IRQ mapping was changed to not being created in the rtc-mt6397
driver, so the irq_dispose_mapping is no longer needed.
Also the dev_id passed to free_irq should be the same as the last
argument passed to request_threaded_irq.
This prevents a "Trying to free already-free IRQ 274" warning when
unbinding the driver.
Fixes: e695d3a0b3b3 ("mfd: mt6397: Create irq mappings in mfd core driver")
Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/rtc')
-rw-r--r-- | drivers/rtc/rtc-mt6397.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/rtc/rtc-mt6397.c b/drivers/rtc/rtc-mt6397.c index f85f1fc29e32..964ed91416e1 100644 --- a/drivers/rtc/rtc-mt6397.c +++ b/drivers/rtc/rtc-mt6397.c @@ -362,7 +362,7 @@ static int mtk_rtc_probe(struct platform_device *pdev) if (ret) { dev_err(&pdev->dev, "Failed to request alarm IRQ: %d: %d\n", rtc->irq, ret); - goto out_dispose_irq; + return ret; } device_init_wakeup(&pdev->dev, 1); @@ -378,9 +378,7 @@ static int mtk_rtc_probe(struct platform_device *pdev) return 0; out_free_irq: - free_irq(rtc->irq, rtc->rtc_dev); -out_dispose_irq: - irq_dispose_mapping(rtc->irq); + free_irq(rtc->irq, rtc); return ret; } @@ -388,8 +386,7 @@ static int mtk_rtc_remove(struct platform_device *pdev) { struct mt6397_rtc *rtc = platform_get_drvdata(pdev); - free_irq(rtc->irq, rtc->rtc_dev); - irq_dispose_mapping(rtc->irq); + free_irq(rtc->irq, rtc); return 0; } |