diff mbox

mmc: via-sdmmc: Use module_pci_driver

Message ID 1346049731-21085-1-git-send-email-sachin.kamat@linaro.org (mailing list archive)
State Accepted, archived
Headers show

Commit Message

Sachin Kamat Aug. 27, 2012, 6:42 a.m. UTC
module_pci_driver makes the code simpler by eliminating
module_init and module_exit calls.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/mmc/host/via-sdmmc.c |   16 +---------------
 1 files changed, 1 insertions(+), 15 deletions(-)

Comments

Harald Welte Aug. 27, 2012, 7:50 a.m. UTC | #1
Hi Sachin,

On Mon, Aug 27, 2012 at 12:12:11PM +0530, Sachin Kamat wrote:
> module_pci_driver makes the code simpler by eliminating
> module_init and module_exit calls.
> 
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>

Acked-by: Harald Welte <laforge@gnumonks.org>
Chris Ball Aug. 30, 2012, 3:11 p.m. UTC | #2
Hi,

On Mon, Aug 27 2012, Harald Welte wrote:
> Hi Sachin,
>
> On Mon, Aug 27, 2012 at 12:12:11PM +0530, Sachin Kamat wrote:
>> module_pci_driver makes the code simpler by eliminating
>> module_init and module_exit calls.
>> 
>> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
>
> Acked-by: Harald Welte <laforge@gnumonks.org>

Thanks, pushed to mmc-next for 3.7.

- Chris.
diff mbox

Patch

diff --git a/drivers/mmc/host/via-sdmmc.c b/drivers/mmc/host/via-sdmmc.c
index 4b83c43..f18bece 100644
--- a/drivers/mmc/host/via-sdmmc.c
+++ b/drivers/mmc/host/via-sdmmc.c
@@ -1337,21 +1337,7 @@  static struct pci_driver via_sd_driver = {
 	.resume = via_sd_resume,
 };
 
-static int __init via_sd_drv_init(void)
-{
-	pr_info(DRV_NAME ": VIA SD/MMC Card Reader driver "
-		"(C) 2008 VIA Technologies, Inc.\n");
-
-	return pci_register_driver(&via_sd_driver);
-}
-
-static void __exit via_sd_drv_exit(void)
-{
-	pci_unregister_driver(&via_sd_driver);
-}
-
-module_init(via_sd_drv_init);
-module_exit(via_sd_drv_exit);
+module_pci_driver(via_sd_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("VIA Technologies Inc.");