Skip to contentSkip to conversation

hwmon: (ibmpowernv) Convert to module_platform_driver

PATCH Applied Axel Lin 2 participants 2 messages Nov 12, 2014

Subsystems (2)
lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 1/1 hwmon: (ibmpowernv) Convert to module_platform_driver

Use module_platform_driver to simplify the code a bit.

---
 drivers/hwmon/ibmpowernv.c | 13 +------------
 1 file changed, 1 insertion(+), 12 deletions(-)
drivers/hwmon/ibmpowernv.c +1 -12
index 6149356..febe817 100644
@@ -317,19 +317,8 @@ static struct platform_driver ibmpowernv_driver = {
 	},
 };
 
-static int __init ibmpowernv_init(void)
-{
-	return platform_driver_register(&ibmpowernv_driver);
-}
-
-static void __exit ibmpowernv_exit(void)
-{
-	platform_driver_unregister(&ibmpowernv_driver);
-}
+module_platform_driver(ibmpowernv_driver);
 
 MODULE_AUTHOR("Neelesh Gupta <[email protected]>");
 MODULE_DESCRIPTION("IBM POWERNV platform sensors");
 MODULE_LICENSE("GPL");
-
-module_init(ibmpowernv_init);
-module_exit(ibmpowernv_exit);
Signature · 9 lines
1.9.1




_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors