projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
83a72c8
)
rtc: rtc-max8997: use devm_request_threaded_irq()
author
Jingoo Han
<jg1.han@samsung.com>
Fri, 22 Feb 2013 00:45:44 +0000
(16:45 -0800)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Fri, 22 Feb 2013 01:22:30 +0000
(17:22 -0800)
Use devm_request_threaded_irq() to make cleanup paths more simple.
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rtc/rtc-max8997.c
patch
|
blob
|
history
diff --git
a/drivers/rtc/rtc-max8997.c
b/drivers/rtc/rtc-max8997.c
index a4e7079fb863abc509768100277a34f187335d1a..00e505b6bee3877696bf7b315de6c703fa9b9ce1 100644
(file)
--- a/
drivers/rtc/rtc-max8997.c
+++ b/
drivers/rtc/rtc-max8997.c
@@
-495,7
+495,8
@@
static int max8997_rtc_probe(struct platform_device *pdev)
}
info->virq = virq;
- ret = request_threaded_irq(virq, NULL, max8997_rtc_alarm_irq, 0,
+ ret = devm_request_threaded_irq(&pdev->dev, virq, NULL,
+ max8997_rtc_alarm_irq, 0,
"rtc-alarm0", info);
if (ret < 0) {
dev_err(&pdev->dev, "Failed to request alarm IRQ: %d: %d\n",
@@
-514,10
+515,8
@@
static int max8997_rtc_remove(struct platform_device *pdev)
{
struct max8997_rtc_info *info = platform_get_drvdata(pdev);
- if (info) {
- free_irq(info->virq, info);
+ if (info)
rtc_device_unregister(info->rtc_dev);
- }
return 0;
}