summaryrefslogtreecommitdiff
path: root/drivers/staging/sm7xxfb/sm7xxfb.c
diff options
context:
space:
mode:
authorDevendra Naga <devendra.aaru@gmail.com>2012-07-10 05:49:14 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-12 00:26:01 (GMT)
commite6345c81b4eb20850ae4078ed3a8ff6eae584283 (patch)
tree1d4204cb30b3f4830429a5433d0ff3feea4c4ad8 /drivers/staging/sm7xxfb/sm7xxfb.c
parentaaf3ee4f80960eecccdd94a6b44b41c6af6c14d3 (diff)
downloadlinux-fsl-qoriq-e6345c81b4eb20850ae4078ed3a8ff6eae584283.tar.xz
staging/sm7xxfb: use module_pci_driver macro
as the manual of module_pci_driver says that it can be used when the init and exit functions of the module does nothing but the pci_register_driver and pci_unregister_driver. use it for the sm7xxfb driver, as the driver does nothing in its _init and _exit functions but the register and unregister. Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/sm7xxfb/sm7xxfb.c')
-rw-r--r--drivers/staging/sm7xxfb/sm7xxfb.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/staging/sm7xxfb/sm7xxfb.c b/drivers/staging/sm7xxfb/sm7xxfb.c
index e3511ec..0c0b603 100644
--- a/drivers/staging/sm7xxfb/sm7xxfb.c
+++ b/drivers/staging/sm7xxfb/sm7xxfb.c
@@ -1058,18 +1058,7 @@ static struct pci_driver smtcfb_driver = {
.driver.pm = SM7XX_PM_OPS,
};
-static int __init smtcfb_init(void)
-{
- return pci_register_driver(&smtcfb_driver);
-}
-
-static void __exit smtcfb_exit(void)
-{
- pci_unregister_driver(&smtcfb_driver);
-}
-
-module_init(smtcfb_init);
-module_exit(smtcfb_exit);
+module_pci_driver(smtcfb_driver);
MODULE_AUTHOR("Siliconmotion ");
MODULE_DESCRIPTION("Framebuffer driver for SMI Graphic Cards");