From: Axel Lin Date: Wed, 12 Nov 2014 08:36:47 +0000 (+0800) Subject: hwmon: (ibmpowernv) Convert to module_platform_driver X-Git-Tag: v3.19-rc1~180^2~14 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=3bdec670df30d515b51ab41452a9cf86a956f7e8;p=linux-block.git hwmon: (ibmpowernv) Convert to module_platform_driver Use module_platform_driver to simplify the code a bit. Signed-off-by: Axel Lin Signed-off-by: Guenter Roeck --- diff --git a/drivers/hwmon/ibmpowernv.c b/drivers/hwmon/ibmpowernv.c index c7577b8f17a8..7c2c7be182f2 100644 --- a/drivers/hwmon/ibmpowernv.c +++ b/drivers/hwmon/ibmpowernv.c @@ -318,19 +318,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 "); MODULE_DESCRIPTION("IBM POWERNV platform sensors"); MODULE_LICENSE("GPL"); - -module_init(ibmpowernv_init); -module_exit(ibmpowernv_exit);