diff options
author | Srinivas Kandagatla <srinivas.kandagatla@st.com> | 2012-10-10 19:39:59 +0100 |
---|---|---|
committer | Artem Bityutskiy <artem.bityutskiy@linux.intel.com> | 2012-11-15 15:37:48 +0200 |
commit | a90019e25e0caed04d3704235b5ea984aaa28da8 (patch) | |
tree | 777f0020eb32e0aa47dd0e95b1e2d5e9bb5b3d4b /drivers/mtd/devices/spear_smi.c | |
parent | 2f25ae97fe4b424d88d765797c46456c7c0f1bae (diff) |
mtd: spear_smi: use module_platform_driver macro
This patch removes some code duplication by using
module_platform_driver.
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@st.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Diffstat (limited to 'drivers/mtd/devices/spear_smi.c')
-rw-r--r-- | drivers/mtd/devices/spear_smi.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/mtd/devices/spear_smi.c b/drivers/mtd/devices/spear_smi.c index dcc3c951153..39e95673cdd 100644 --- a/drivers/mtd/devices/spear_smi.c +++ b/drivers/mtd/devices/spear_smi.c @@ -1094,18 +1094,7 @@ static struct platform_driver spear_smi_driver = { .probe = spear_smi_probe, .remove = __devexit_p(spear_smi_remove), }; - -static int spear_smi_init(void) -{ - return platform_driver_register(&spear_smi_driver); -} -module_init(spear_smi_init); - -static void spear_smi_exit(void) -{ - platform_driver_unregister(&spear_smi_driver); -} -module_exit(spear_smi_exit); +module_platform_driver(spear_smi_driver); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Ashish Priyadarshi, Shiraz Hashim <shiraz.hashim@st.com>"); |