net: rfkill: convert net/rfkill/* to use module_platform_driver()
This patch converts the drivers in net/rfkill/* to use the module_platform_driver() macro which makes the code smaller and a bit simpler. Cc: "David S. Miller" <davem@davemloft.net> Cc: "John W. Linville" <linville@tuxdriver.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: Antonio Ospite <ospite@studenti.unina.it> Cc: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Rhyland Klein <rklein@nvidia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:

committed by
John W. Linville

parent
264827555b
commit
98ef55f66f
@@ -220,18 +220,7 @@ static struct platform_driver rfkill_gpio_driver = {
|
||||
},
|
||||
};
|
||||
|
||||
static int __init rfkill_gpio_init(void)
|
||||
{
|
||||
return platform_driver_register(&rfkill_gpio_driver);
|
||||
}
|
||||
|
||||
static void __exit rfkill_gpio_exit(void)
|
||||
{
|
||||
platform_driver_unregister(&rfkill_gpio_driver);
|
||||
}
|
||||
|
||||
module_init(rfkill_gpio_init);
|
||||
module_exit(rfkill_gpio_exit);
|
||||
module_platform_driver(rfkill_gpio_driver);
|
||||
|
||||
MODULE_DESCRIPTION("gpio rfkill");
|
||||
MODULE_AUTHOR("NVIDIA");
|
||||
|
Reference in New Issue
Block a user