Commit e7a6c214 authored by Jingoo Han's avatar Jingoo Han Committed by Linus Torvalds

rtc: rtc-nuc900: add __init/__exit annotation

When platform_driver_probe() is used, bind/unbind via sysfs is disabled.
Thus, __init/__exit annotations can be added to probe()/remove().
Signed-off-by: default avatarJingoo Han <jg1.han@samsung.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 5073cba6
...@@ -222,7 +222,7 @@ static struct rtc_class_ops nuc900_rtc_ops = { ...@@ -222,7 +222,7 @@ static struct rtc_class_ops nuc900_rtc_ops = {
.alarm_irq_enable = nuc900_alarm_irq_enable, .alarm_irq_enable = nuc900_alarm_irq_enable,
}; };
static int nuc900_rtc_probe(struct platform_device *pdev) static int __init nuc900_rtc_probe(struct platform_device *pdev)
{ {
struct resource *res; struct resource *res;
struct nuc900_rtc *nuc900_rtc; struct nuc900_rtc *nuc900_rtc;
...@@ -284,7 +284,7 @@ fail1: kfree(nuc900_rtc); ...@@ -284,7 +284,7 @@ fail1: kfree(nuc900_rtc);
return err; return err;
} }
static int nuc900_rtc_remove(struct platform_device *pdev) static int __exit nuc900_rtc_remove(struct platform_device *pdev)
{ {
struct nuc900_rtc *nuc900_rtc = platform_get_drvdata(pdev); struct nuc900_rtc *nuc900_rtc = platform_get_drvdata(pdev);
struct resource *res; struct resource *res;
...@@ -304,7 +304,7 @@ static int nuc900_rtc_remove(struct platform_device *pdev) ...@@ -304,7 +304,7 @@ static int nuc900_rtc_remove(struct platform_device *pdev)
} }
static struct platform_driver nuc900_rtc_driver = { static struct platform_driver nuc900_rtc_driver = {
.remove = nuc900_rtc_remove, .remove = __exit_p(nuc900_rtc_remove),
.driver = { .driver = {
.name = "nuc900-rtc", .name = "nuc900-rtc",
.owner = THIS_MODULE, .owner = THIS_MODULE,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment