aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/p54
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2013-05-29 06:01:40 -0400
committerJohn W. Linville <linville@tuxdriver.com>2013-05-29 15:22:44 -0400
commitb6c32f88740013b78eee68a604678b548750510f (patch)
tree2824f97a357c0110fc22da107d6b99433f80f3a6 /drivers/net/wireless/p54
parent9c8426fc79eef00464d33e774085395cac41d091 (diff)
net: wireless: p54spi: Use module_spi_driver macro
module_spi_driver() eliminates some boiler plate and makes code simpler. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/p54')
-rw-r--r--drivers/net/wireless/p54/p54spi.c22
1 files changed, 1 insertions, 21 deletions
diff --git a/drivers/net/wireless/p54/p54spi.c b/drivers/net/wireless/p54/p54spi.c
index 978e7eb26567..146e6530ae29 100644
--- a/drivers/net/wireless/p54/p54spi.c
+++ b/drivers/net/wireless/p54/p54spi.c
@@ -713,27 +713,7 @@ static struct spi_driver p54spi_driver = {
713 .remove = p54spi_remove, 713 .remove = p54spi_remove,
714}; 714};
715 715
716static int __init p54spi_init(void) 716module_spi_driver(p54spi_driver);
717{
718 int ret;
719
720 ret = spi_register_driver(&p54spi_driver);
721 if (ret < 0) {
722 printk(KERN_ERR "failed to register SPI driver: %d", ret);
723 goto out;
724 }
725
726out:
727 return ret;
728}
729
730static void __exit p54spi_exit(void)
731{
732 spi_unregister_driver(&p54spi_driver);
733}
734
735module_init(p54spi_init);
736module_exit(p54spi_exit);
737 717
738MODULE_LICENSE("GPL"); 718MODULE_LICENSE("GPL");
739MODULE_AUTHOR("Christian Lamparter <chunkeey@web.de>"); 719MODULE_AUTHOR("Christian Lamparter <chunkeey@web.de>");