summaryrefslogtreecommitdiff
path: root/drivers/misc/spear13xx_pcie_gadget.c
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@gmail.com>2012-01-22 11:33:49 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2012-01-25 04:31:48 +0400
commitb00e126ffea89b687a83093546058b07aa054b4c (patch)
treeb9dc95d02de0cb772d40554bbce670e4086e449d /drivers/misc/spear13xx_pcie_gadget.c
parentdcd6c92267155e70a94b3927bce681ce74b80d1f (diff)
downloadlinux-b00e126ffea89b687a83093546058b07aa054b4c.tar.xz
MISC: convert drivers/misc/* to use module_platform_driver()
This patch converts the drivers in drivers/misc/* to use the module_platform_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Ira W. Snyder <iws@ovro.caltech.edu> Cc: Pavan Savoy <pavan_savoy@ti.com> Cc: Donggeun Kim <dg77.kim@samsung.com> Acked-By: Pratyush Anand <pratyush.anand@st.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Pratyush Anand <pratyush.anand@st.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/misc/spear13xx_pcie_gadget.c')
-rw-r--r--drivers/misc/spear13xx_pcie_gadget.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/misc/spear13xx_pcie_gadget.c b/drivers/misc/spear13xx_pcie_gadget.c
index 43d073bc1d9c..123ed98eec3e 100644
--- a/drivers/misc/spear13xx_pcie_gadget.c
+++ b/drivers/misc/spear13xx_pcie_gadget.c
@@ -891,17 +891,7 @@ static struct platform_driver spear_pcie_gadget_driver = {
},
};
-static int __init spear_pcie_gadget_init(void)
-{
- return platform_driver_register(&spear_pcie_gadget_driver);
-}
-module_init(spear_pcie_gadget_init);
-
-static void __exit spear_pcie_gadget_exit(void)
-{
- platform_driver_unregister(&spear_pcie_gadget_driver);
-}
-module_exit(spear_pcie_gadget_exit);
+module_platform_driver(spear_pcie_gadget_driver);
MODULE_ALIAS("platform:pcie-gadget-spear");
MODULE_AUTHOR("Pratyush Anand");