diff mbox

[1/2] ide / au1xxx-ide: Use module_platform_driver() to simplify code

Message ID 1380436317-8629-1-git-send-email-hanjun.guo@linaro.org
State New
Headers show

Commit Message

Hanjun Guo Sept. 29, 2013, 6:31 a.m. UTC
Convert to module_platform_driver() to simplify code.

Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
---
 drivers/ide/au1xxx-ide.c |   14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)
diff mbox

Patch

diff --git a/drivers/ide/au1xxx-ide.c b/drivers/ide/au1xxx-ide.c
index 259786c..bdaf8a5 100644
--- a/drivers/ide/au1xxx-ide.c
+++ b/drivers/ide/au1xxx-ide.c
@@ -591,19 +591,7 @@  static struct platform_driver au1200_ide_driver = {
 	.probe 		= au_ide_probe,
 	.remove		= au_ide_remove,
 };
-
-static int __init au_ide_init(void)
-{
-	return platform_driver_register(&au1200_ide_driver);
-}
-
-static void __exit au_ide_exit(void)
-{
-	platform_driver_unregister(&au1200_ide_driver);
-}
+module_paltform_driver(au1200_ide_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("AU1200 IDE driver");
-
-module_init(au_ide_init);
-module_exit(au_ide_exit);