diff options
author | Wei Yongjun <weiyongjun1@huawei.com> | 2017-04-24 23:14:09 -0400 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2017-04-25 02:12:05 -0400 |
commit | dfc28b110d4f42953147204bc627b3c64205ed19 (patch) | |
tree | 75c76962fa6fd4db6fbf4029d492889e6c980fa0 | |
parent | 01d95843335c6d7bb7d100c0083165f489c6e50b (diff) |
mmc: cavium: Use module_pci_driver to simplify the code
Use the module_pci_driver() macro to make the code simpler
by eliminating module_init and module_exit calls.
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Acked-by: Jan Glauber <jglauber@cavium.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
-rw-r--r-- | drivers/mmc/host/cavium-thunderx.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/mmc/host/cavium-thunderx.c b/drivers/mmc/host/cavium-thunderx.c index 65244e8df5dd..fe3d77267cd6 100644 --- a/drivers/mmc/host/cavium-thunderx.c +++ b/drivers/mmc/host/cavium-thunderx.c | |||
@@ -179,18 +179,7 @@ static struct pci_driver thunder_mmc_driver = { | |||
179 | .remove = thunder_mmc_remove, | 179 | .remove = thunder_mmc_remove, |
180 | }; | 180 | }; |
181 | 181 | ||
182 | static int __init thunder_mmc_init_module(void) | 182 | module_pci_driver(thunder_mmc_driver); |
183 | { | ||
184 | return pci_register_driver(&thunder_mmc_driver); | ||
185 | } | ||
186 | |||
187 | static void __exit thunder_mmc_exit_module(void) | ||
188 | { | ||
189 | pci_unregister_driver(&thunder_mmc_driver); | ||
190 | } | ||
191 | |||
192 | module_init(thunder_mmc_init_module); | ||
193 | module_exit(thunder_mmc_exit_module); | ||
194 | 183 | ||
195 | MODULE_AUTHOR("Cavium Inc."); | 184 | MODULE_AUTHOR("Cavium Inc."); |
196 | MODULE_DESCRIPTION("Cavium ThunderX eMMC Driver"); | 185 | MODULE_DESCRIPTION("Cavium ThunderX eMMC Driver"); |